Gnash
0.8.10
|
#include <Renderer_agg_style.h>
Public Member Functions | |
StyleHandler () | |
~StyleHandler () | |
bool | is_solid (unsigned style) const |
Called by AGG to ask if a certain style is a solid color. | |
void | add_color (const agg::rgba8 &color) |
Adds a new solid fill color style. | |
void | add_bitmap (const agg_bitmap_info *bi, const SWFMatrix &mat, const SWFCxForm &cx, bool repeat, bool smooth) |
Adds a new bitmap fill style. | |
template<typename T > | |
void | addLinearGradient (const GradientFill &fs, const SWFMatrix &mat, const SWFCxForm &cx) |
template<typename T > | |
void | addFocalGradient (const GradientFill &fs, const SWFMatrix &mat, const SWFCxForm &cx) |
template<typename T > | |
void | addRadialGradient (const GradientFill &fs, const SWFMatrix &mat, const SWFCxForm &cx) |
agg::rgba8 | color (unsigned style) const |
Returns the color of a certain fill style (solid) | |
void | generate_span (agg::rgba8 *span, int x, int y, unsigned len, unsigned style) |
Called by AGG to generate a scanline span for non-solid fills. | |
template<typename Filter > | |
void | addBitmap (const agg_bitmap_info *bi, const SWFMatrix &mat, const SWFCxForm &cx) |
Add a bitmap with the specified filter. | |
Public Attributes | |
boost::ptr_vector< AggStyle > | _styles |
agg::rgba8 | m_transparent |
Style handler for AGG's compound rasterizer. This is the class which is called by AGG itself. It provides an interface to the various fill style classes defined above.
gnash::StyleHandler::StyleHandler | ( | ) | [inline] |
gnash::StyleHandler::~StyleHandler | ( | ) | [inline] |
void gnash::StyleHandler::add_bitmap | ( | const agg_bitmap_info * | bi, |
const SWFMatrix & | mat, | ||
const SWFCxForm & | cx, | ||
bool | repeat, | ||
bool | smooth | ||
) | [inline] |
void gnash::StyleHandler::add_color | ( | const agg::rgba8 & | color | ) | [inline] |
Adds a new solid fill color style.
References _styles.
Referenced by gnash::AddStyles::operator()().
void gnash::StyleHandler::addBitmap | ( | const agg_bitmap_info * | bi, |
const SWFMatrix & | mat, | ||
const SWFCxForm & | cx | ||
) | [inline] |
Add a bitmap with the specified filter.
Filter | The FilterType to use. This affects scaling quality, pixel type etc. |
References gnash::agg_bitmap_info::get_width(), gnash::agg_bitmap_info::get_height(), gnash::agg_bitmap_info::get_rowlen(), gnash::agg_bitmap_info::get_data(), and _styles.
void gnash::StyleHandler::addFocalGradient | ( | const GradientFill & | fs, |
const SWFMatrix & | mat, | ||
const SWFCxForm & | cx | ||
) | [inline] |
References gnash::key::T, gnash::GradientFill::focalPoint(), and _styles.
void gnash::StyleHandler::addLinearGradient | ( | const GradientFill & | fs, |
const SWFMatrix & | mat, | ||
const SWFCxForm & | cx | ||
) | [inline] |
References gnash::key::T, and _styles.
void gnash::StyleHandler::addRadialGradient | ( | const GradientFill & | fs, |
const SWFMatrix & | mat, | ||
const SWFCxForm & | cx | ||
) | [inline] |
References gnash::key::T, and _styles.
agg::rgba8 gnash::StyleHandler::color | ( | unsigned | style | ) | const [inline] |
Returns the color of a certain fill style (solid)
References _styles, and m_transparent.
void gnash::StyleHandler::generate_span | ( | agg::rgba8 * | span, |
int | x, | ||
int | y, | ||
unsigned | len, | ||
unsigned | style | ||
) | [inline] |
Called by AGG to generate a scanline span for non-solid fills.
References _styles.
bool gnash::StyleHandler::is_solid | ( | unsigned | style | ) | const [inline] |
boost::ptr_vector<AggStyle> gnash::StyleHandler::_styles |
Referenced by is_solid(), add_color(), addLinearGradient(), addFocalGradient(), addRadialGradient(), color(), generate_span(), and addBitmap().
agg::rgba8 gnash::StyleHandler::m_transparent |
Referenced by color().