This source file includes following definitions.
- _transparentColor
- updateMontageInfo
- _matteColor
- updateMontageInfo
#define MAGICKCORE_IMPLEMENTATION 1
#define MAGICK_PLUSPLUS_IMPLEMENTATION 1
#include "Magick++/Include.h"
#include <string>
#include <string.h>
#include "Magick++/Montage.h"
#include "Magick++/Functions.h"
Magick::Montage::Montage(void)
: _backgroundColor("#ffffff"),
_compose(OverCompositeOp),
_fileName(),
_fill("#000000ff"),
_font(),
_geometry("120x120+4+3>"),
_gravity(CenterGravity),
_label(),
_pointSize(12),
_shadow(false),
_stroke(),
_texture(),
_tile("6x4"),
_title(),
_transparentColor()
{
}
Magick::Montage::~Montage(void)
{
}
void Magick::Montage::updateMontageInfo(MontageInfo &montageInfo_) const
{
(void) MagickCore::ResetMagickMemory(&montageInfo_,0,sizeof(montageInfo_));
montageInfo_.background_color=_backgroundColor;
montageInfo_.border_color=Color();
montageInfo_.border_width=0;
if (_fileName.length() != 0)
{
_fileName.copy(montageInfo_.filename,MaxTextExtent-1);
montageInfo_.filename[_fileName.length()]=0;
}
montageInfo_.fill=_fill;
if (_font.length() != 0)
Magick::CloneString(&montageInfo_.font,_font);
if (_geometry.isValid())
Magick::CloneString(&montageInfo_.geometry,_geometry);
montageInfo_.gravity=_gravity;
montageInfo_.matte_color=Color();
montageInfo_.pointsize=_pointSize;
montageInfo_.shadow=static_cast<MagickBooleanType>(_shadow ? MagickTrue :
MagickFalse);
montageInfo_.signature=MagickSignature;
montageInfo_.stroke=_stroke;
if (_texture.length() != 0)
Magick::CloneString(&montageInfo_.texture,_texture);
if (_tile.isValid())
Magick::CloneString( &montageInfo_.tile, _tile );
if (_title.length() != 0)
Magick::CloneString(&montageInfo_.title,_title);
}
Magick::MontageFramed::MontageFramed(void)
: _borderColor("#dfdfdf"),
_borderWidth(0),
_frame(),
_matteColor("#bdbdbd")
{
}
Magick::MontageFramed::~MontageFramed(void)
{
}
void Magick::MontageFramed::updateMontageInfo(MontageInfo &montageInfo_) const
{
Montage::updateMontageInfo(montageInfo_);
montageInfo_.border_color=_borderColor;
montageInfo_.border_width=_borderWidth;
if (_frame.isValid())
Magick::CloneString(&montageInfo_.frame,_frame);
montageInfo_.matte_color=_matteColor;
}