summaryrefslogtreecommitdiff
path: root/agg/inc/agg_rasterizer_scanline_aa.h
diff options
context:
space:
mode:
authorBjoern Michaelsen <bjoern.michaelsen@canonical.com>2011-08-23 15:15:40 +0200
committerBjoern Michaelsen <bjoern.michaelsen@canonical.com>2011-08-23 15:15:40 +0200
commit63a1d1f544cc305fd85f3eff88d239707eb0887b (patch)
tree31e94776ad9267cb5261384a82cfc24dd6ebc58a /agg/inc/agg_rasterizer_scanline_aa.h
parent5c5915bb0ffbfa975ffac67e6ebf8c8ca75876a2 (diff)
recreated tag OOO_BUILD_3_2_98_1 which had these commits:
commit 72351eac8e48c77a85526da9211579a668989db0 (tag: refs/tags/OOO_BUILD_3_2_98_1) Author: Petr Mladek <pmladek@walk.suse.cz> Date: Wed Sep 15 19:03:27 2010 +0200 Release ooo-build-3.2.98.1, tag OOO_BUILD_3_2_98_1 (3.3-alpha1) commit ff7279bcea6a84b78d0f2857afc65bdfdf74d292 Author: Fridrich Štrba <fridrich.strba@bluewin.ch> Date: Tue Sep 14 17:27:58 2010 +0200 Moving languagetool out of the wront repository languagetool/JLanguageTool-1.0.0.patch | 137 -------------------------------- languagetool/makefile.mk | 67 ---------------- languagetool/prj/build.lst | 3 - languagetool/prj/d.lst | 1 - 4 files changed, 0 insertions(+), 208 deletions(-) commit ebd25dfc045728e12fa638b298471381ad15719a Author: Fridrich Štrba <fridrich.strba@bluewin.ch> Date: Tue Sep 14 17:16:24 2010 +0200 languagetool-makefile-mk.diff: makefile for languagetool languagetool/makefile.mk | 67 ++++++++++++++++++++++++++++++++++++++++++++++ 1 files changed, 67 insertions(+), 0 deletions(-) commit fe841a0e61050b7f20d3d38de14bec34aa42190c Author: Fridrich Štrba <fridrich.strba@bluewin.ch> Date: Tue Sep 14 17:13:53 2010 +0200 languagetool-jlanguagetool-1-0-0-patch.diff: build patch for languagetool languagetool/JLanguageTool-1.0.0.patch | 137 ++++++++++++++++++++++++++++++++ 1 files changed, 137 insertions(+), 0 deletions(-) commit d1c6a5a8d097d3ac87c39b7aa7274a3fe82de9c2 Author: Fridrich Štrba <fridrich.strba@bluewin.ch> Date: Tue Sep 14 17:11:46 2010 +0200 languagetool-prj-d-lst.diff: languagetool deliver list languagetool/prj/d.lst | 1 + 1 files changed, 1 insertions(+), 0 deletions(-) commit da8f435f9d194571819d53ed85e89ef1adbcb044 Author: Fridrich Štrba <fridrich.strba@bluewin.ch> Date: Tue Sep 14 17:09:23 2010 +0200 languagetool-prj-build-lst.diff: build list for languagetool module languagetool/prj/build.lst | 3 +++ 1 files changed, 3 insertions(+), 0 deletions(-) commit ab036ed3fa31d5cbbf4d1a17180e8a7b053a642d Author: Tor Lillqvist <tlillqvist@novell.com> Date: Tue Sep 14 12:20:45 2010 +0200 build-fix-win32.diff: Fix Windows build on partitions without short names external/msvcp80/README_msvcX80.dll | 5 +++-- external/prj/d.lst | 4 ++-- 2 files changed, 5 insertions(+), 4 deletions(-) commit 51593e8e836ce5db60fc00682cefb1b87bd0f027 Author: Fridrich Štrba <fridrich.strba@bluewin.ch> Date: Tue Sep 14 11:41:58 2010 +0200 internal-mesa-headers-mesa.diff: Create mesa module for use with transogl. Mesa/inc/gl.h | 2252 +++++++++++++++ Mesa/inc/gl_mangle.h | 1568 +++++++++++ Mesa/inc/glext.h | 7271 +++++++++++++++++++++++++++++++++++++++++++++++++ Mesa/inc/glu.h | 348 +++ Mesa/inc/glu_mangle.h | 86 + Mesa/inc/glx.h | 500 ++++ Mesa/inc/glx_mangle.h | 81 + Mesa/inc/glxext.h | 785 ++++++ Mesa/inc/vms_x_fix.h | 1224 +++++++++ Mesa/prj/build.lst | 3 + Mesa/prj/d.lst | 3 + 11 files changed, 14121 insertions(+), 0 deletions(-) commit 84b44afa238afc45065db0c87d94fdcda0b99489 Author: Fridrich Štrba <fridrich.strba@bluewin.ch> Date: Tue Sep 14 11:26:04 2010 +0200 libwpg.diff: WPG Import filter - create a libwpg module. libwpg/makefile.mk | 60 ++++++++++++++++++++++++++++++++++++++++++++++++++ libwpg/prj/build.lst | 3 ++ libwpg/prj/d.lst | 16 +++++++++++++ 3 files changed, 79 insertions(+), 0 deletions(-) commit c9802c9c9481ef47c8bb5225fb5be640ed4f4c87 Author: Fridrich Štrba <fridrich.strba@bluewin.ch> Date: Tue Sep 14 11:15:24 2010 +0200 libwps.diff: WPS Import filter - create a libwps module libwpd/makefile.mk | 2 +- libwps/libwps-0.1.1.diff | 93 ++++++++++++++++++++++++++++++++++++++++++++++ libwps/makefile.mk | 60 +++++++++++++++++++++++++++++ libwps/prj/build.lst | 3 + libwps/prj/d.lst | 6 +++ 5 files changed, 163 insertions(+), 1 deletions(-) commit 37676cddbfa10f29efea49aafd07acb40aa6b7d4 Author: Fridrich Štrba <fridrich.strba@bluewin.ch> Date: Tue Sep 14 10:34:20 2010 +0200 libwpd.diff: upload new libwpd libwpd/makefile.mk | 5 ++--- 1 files changed, 2 insertions(+), 3 deletions(-)
Notes
Notes: split repo tag: libs-extern_OOO_BUILD_3_2_98_1
Diffstat (limited to 'agg/inc/agg_rasterizer_scanline_aa.h')
-rwxr-xr-xagg/inc/agg_rasterizer_scanline_aa.h156
1 files changed, 78 insertions, 78 deletions
diff --git a/agg/inc/agg_rasterizer_scanline_aa.h b/agg/inc/agg_rasterizer_scanline_aa.h
index 03be55dcc62a..4ffd43b9992b 100755
--- a/agg/inc/agg_rasterizer_scanline_aa.h
+++ b/agg/inc/agg_rasterizer_scanline_aa.h
@@ -2,13 +2,13 @@
// Anti-Grain Geometry - Version 2.3
// Copyright (C) 2002-2005 Maxim Shemanarev (http://www.antigrain.com)
//
-// Permission to copy, use, modify, sell and distribute this software
-// is granted provided this copyright notice appears in all copies.
+// Permission to copy, use, modify, sell and distribute this software
+// is granted provided this copyright notice appears in all copies.
// This software is provided "as is" without express or implied
// warranty, and with no claim as to its suitability for any purpose.
//
-// The author gratefully acknowleges the support of David Turner,
-// Robert Wilhelm, and Werner Lemberg - the authors of the FreeType
+// The author gratefully acknowleges the support of David Turner,
+// Robert Wilhelm, and Werner Lemberg - the authors of the FreeType
// libray - in producing this work. See http://www.freetype.org for details.
//
//----------------------------------------------------------------------------
@@ -18,7 +18,7 @@
//----------------------------------------------------------------------------
//
// Class rasterizer_scanline_aa
-//
+//
//
//----------------------------------------------------------------------------
#ifndef AGG_RASTERIZER_SCANLINE_AA_INCLUDED
@@ -37,18 +37,18 @@ namespace agg
{
//------------------------------------------------------------------------
- // These constants determine the subpixel accuracy, to be more precise,
- // the number of bits of the fractional part of the coordinates.
+ // These constants determine the subpixel accuracy, to be more precise,
+ // the number of bits of the fractional part of the coordinates.
// The possible coordinate capacity in bits can be calculated by formula:
// sizeof(int) * 8 - poly_base_shift * 2, i.e, for 32-bit integers and
// 8-bits fractional part the capacity is 16 bits or [-32768...32767].
enum
{
poly_base_shift = 8, //----poly_base_shift
- poly_base_size = 1 << poly_base_shift, //----poly_base_size
- poly_base_mask = poly_base_size - 1 //----poly_base_mask
+ poly_base_size = 1 << poly_base_shift, //----poly_base_size
+ poly_base_mask = poly_base_size - 1 //----poly_base_mask
};
-
+
//--------------------------------------------------------------poly_coord
inline int poly_coord(double c)
{
@@ -56,8 +56,8 @@ namespace agg
}
//-----------------------------------------------------------------cell_aa
- // A pixel cell. There're no constructors defined and it was done
- // intentionally in order to avoid extra overhead when allocating an
+ // A pixel cell. There're no constructors defined and it was done
+ // intentionally in order to avoid extra overhead when allocating an
// array of cells.
struct cell_aa
{
@@ -117,7 +117,7 @@ namespace agg
void render_hline(int ey, int x1, int y1, int x2, int y2);
void render_line(int x1, int y1, int x2, int y2);
void allocate_block();
-
+
static void qsort_cells(cell_aa** start, unsigned num);
private:
@@ -149,10 +149,10 @@ namespace agg
//==================================================rasterizer_scanline_aa
- // Polygon rasterizer that is used to render filled polygons with
- // high-quality Anti-Aliasing. Internally, by default, the class uses
- // integer coordinates in format 24.8, i.e. 24 bits for integer part
- // and 8 bits for fractional - see poly_base_shift. This class can be
+ // Polygon rasterizer that is used to render filled polygons with
+ // high-quality Anti-Aliasing. Internally, by default, the class uses
+ // integer coordinates in format 24.8, i.e. 24 bits for integer part
+ // and 8 bits for fractional - see poly_base_shift. This class can be
// used in the following way:
//
// 1. filling_rule(filling_rule_e ft) - optional.
@@ -161,20 +161,20 @@ namespace agg
//
// 3. reset()
//
- // 4. move_to(x, y) / line_to(x, y) - make the polygon. One can create
+ // 4. move_to(x, y) / line_to(x, y) - make the polygon. One can create
// more than one contour, but each contour must consist of at least 3
// vertices, i.e. move_to(x1, y1); line_to(x2, y2); line_to(x3, y3);
// is the absolute minimum of vertices that define a triangle.
// The algorithm does not check either the number of vertices nor
- // coincidence of their coordinates, but in the worst case it just
+ // coincidence of their coordinates, but in the worst case it just
// won't draw anything.
- // The orger of the vertices (clockwise or counterclockwise)
+ // The orger of the vertices (clockwise or counterclockwise)
// is important when using the non-zero filling rule (fill_non_zero).
// In this case the vertex order of all the contours must be the same
// if you want your intersecting polygons to be without "holes".
- // You actually can use different vertices order. If the contours do not
- // intersect each other the order is not important anyway. If they do,
- // contours with the same vertex order will be rendered without "holes"
+ // You actually can use different vertices order. If the contours do not
+ // intersect each other the order is not important anyway. If they do,
+ // contours with the same vertex order will be rendered without "holes"
// while the intersecting contours with different orders will have "holes".
//
// filling_rule() and gamma() can be called anytime before "sweeping".
@@ -206,7 +206,7 @@ namespace agg
};
//--------------------------------------------------------------------
- rasterizer_scanline_aa() :
+ rasterizer_scanline_aa() :
m_filling_rule(fill_non_zero),
m_clipped_start_x(0),
m_clipped_start_y(0),
@@ -223,8 +223,8 @@ namespace agg
}
//--------------------------------------------------------------------
- template<class GammaF>
- rasterizer_scanline_aa(const GammaF& gamma_function) :
+ template<class GammaF>
+ rasterizer_scanline_aa(const GammaF& gamma_function) :
m_filling_rule(fill_non_zero),
m_clipped_start_x(0),
m_clipped_start_y(0),
@@ -240,14 +240,14 @@ namespace agg
}
//--------------------------------------------------------------------
- void reset();
+ void reset();
void filling_rule(filling_rule_e filling_rule);
void clip_box(double x1, double y1, double x2, double y2);
void reset_clipping();
//--------------------------------------------------------------------
template<class GammaF> void gamma(const GammaF& gamma_function)
- {
+ {
int i;
for(i = 0; i < aa_num; i++)
{
@@ -256,9 +256,9 @@ namespace agg
}
//--------------------------------------------------------------------
- unsigned apply_gamma(unsigned cover) const
- {
- return m_gamma[cover];
+ unsigned apply_gamma(unsigned cover) const
+ {
+ return m_gamma[cover];
}
//--------------------------------------------------------------------
@@ -268,7 +268,7 @@ namespace agg
void close_polygon();
void move_to_d(double x, double y);
void line_to_d(double x, double y);
-
+
//--------------------------------------------------------------------
int min_x() const { return m_outline.min_x(); }
int min_y() const { return m_outline.min_y(); }
@@ -305,7 +305,7 @@ namespace agg
{
close_polygon();
m_iterator.cells = m_outline.cells();
- if(m_outline.num_cells() == 0)
+ if(m_outline.num_cells() == 0)
{
return false;
}
@@ -329,7 +329,7 @@ namespace agg
for(;;)
{
int coord = cur_cell->packed_coord;
- int area = cur_cell->area;
+ int area = cur_cell->area;
int last_x = cur_cell->x;
m_iterator.cover += cur_cell->cover;
@@ -379,7 +379,7 @@ namespace agg
}
}
}
- if(sl.num_spans())
+ if(sl.num_spans())
{
sl.finalize(m_iterator.last_y);
break;
@@ -428,7 +428,7 @@ namespace agg
//--------------------------------------------------------------------
// Disable copying
rasterizer_scanline_aa(const rasterizer_scanline_aa<XScale, AA_Shift>&);
- const rasterizer_scanline_aa<XScale, AA_Shift>&
+ const rasterizer_scanline_aa<XScale, AA_Shift>&
operator = (const rasterizer_scanline_aa<XScale, AA_Shift>&);
//--------------------------------------------------------------------
@@ -464,22 +464,22 @@ namespace agg
//------------------------------------------------------------------------
- template<unsigned XScale, unsigned AA_Shift>
- void rasterizer_scanline_aa<XScale, AA_Shift>::reset()
- {
- m_outline.reset();
+ template<unsigned XScale, unsigned AA_Shift>
+ void rasterizer_scanline_aa<XScale, AA_Shift>::reset()
+ {
+ m_outline.reset();
m_status = status_initial;
}
//------------------------------------------------------------------------
- template<unsigned XScale, unsigned AA_Shift>
- void rasterizer_scanline_aa<XScale, AA_Shift>::filling_rule(filling_rule_e _filling_rule)
- {
- m_filling_rule = _filling_rule;
+ template<unsigned XScale, unsigned AA_Shift>
+ void rasterizer_scanline_aa<XScale, AA_Shift>::filling_rule(filling_rule_e _filling_rule)
+ {
+ m_filling_rule = _filling_rule;
}
//------------------------------------------------------------------------
- template<unsigned XScale, unsigned AA_Shift>
+ template<unsigned XScale, unsigned AA_Shift>
void rasterizer_scanline_aa<XScale, AA_Shift>::clip_box(double x1, double y1, double x2, double y2)
{
reset();
@@ -490,7 +490,7 @@ namespace agg
}
//------------------------------------------------------------------------
- template<unsigned XScale, unsigned AA_Shift>
+ template<unsigned XScale, unsigned AA_Shift>
void rasterizer_scanline_aa<XScale, AA_Shift>::reset_clipping()
{
reset();
@@ -500,14 +500,14 @@ namespace agg
//------------------------------------------------------------------------
- template<unsigned XScale, unsigned AA_Shift>
+ template<unsigned XScale, unsigned AA_Shift>
void rasterizer_scanline_aa<XScale, AA_Shift>::move_to_no_clip(int x, int y)
{
if(m_status == status_line_to)
{
close_polygon_no_clip();
}
- m_outline.move_to(x * XScale, y);
+ m_outline.move_to(x * XScale, y);
m_clipped_start_x = x;
m_clipped_start_y = y;
m_status = status_line_to;
@@ -515,19 +515,19 @@ namespace agg
//------------------------------------------------------------------------
- template<unsigned XScale, unsigned AA_Shift>
+ template<unsigned XScale, unsigned AA_Shift>
void rasterizer_scanline_aa<XScale, AA_Shift>::line_to_no_clip(int x, int y)
{
if(m_status != status_initial)
{
- m_outline.line_to(x * XScale, y);
+ m_outline.line_to(x * XScale, y);
m_status = status_line_to;
}
}
//------------------------------------------------------------------------
- template<unsigned XScale, unsigned AA_Shift>
+ template<unsigned XScale, unsigned AA_Shift>
void rasterizer_scanline_aa<XScale, AA_Shift>::close_polygon_no_clip()
{
if(m_status == status_line_to)
@@ -539,8 +539,8 @@ namespace agg
//------------------------------------------------------------------------
- template<unsigned XScale, unsigned AA_Shift>
- void rasterizer_scanline_aa<XScale, AA_Shift>::clip_segment(int x, int y)
+ template<unsigned XScale, unsigned AA_Shift>
+ void rasterizer_scanline_aa<XScale, AA_Shift>::clip_segment(int x, int y)
{
unsigned flags = clipping_flags(x, y, m_clip_box);
if(m_prev_flags == flags)
@@ -561,9 +561,9 @@ namespace agg
{
int cx[4];
int cy[4];
- unsigned n = clip_liang_barsky(m_prev_x, m_prev_y,
- x, y,
- m_clip_box,
+ unsigned n = clip_liang_barsky(m_prev_x, m_prev_y,
+ x, y,
+ m_clip_box,
cx, cy);
const int* px = cx;
const int* py = cy;
@@ -587,7 +587,7 @@ namespace agg
//------------------------------------------------------------------------
- template<unsigned XScale, unsigned AA_Shift>
+ template<unsigned XScale, unsigned AA_Shift>
void rasterizer_scanline_aa<XScale, AA_Shift>::add_vertex(double x, double y, unsigned cmd)
{
if(is_close(cmd))
@@ -596,11 +596,11 @@ namespace agg
}
else
{
- if(is_move_to(cmd))
+ if(is_move_to(cmd))
{
move_to(poly_coord(x), poly_coord(y));
}
- else
+ else
{
if(is_vertex(cmd))
{
@@ -613,12 +613,12 @@ namespace agg
//------------------------------------------------------------------------
- template<unsigned XScale, unsigned AA_Shift>
- void rasterizer_scanline_aa<XScale, AA_Shift>::move_to(int x, int y)
- {
+ template<unsigned XScale, unsigned AA_Shift>
+ void rasterizer_scanline_aa<XScale, AA_Shift>::move_to(int x, int y)
+ {
if(m_clipping)
{
- if(m_outline.sorted())
+ if(m_outline.sorted())
{
reset();
}
@@ -642,9 +642,9 @@ namespace agg
}
//------------------------------------------------------------------------
- template<unsigned XScale, unsigned AA_Shift>
- void rasterizer_scanline_aa<XScale, AA_Shift>::line_to(int x, int y)
- {
+ template<unsigned XScale, unsigned AA_Shift>
+ void rasterizer_scanline_aa<XScale, AA_Shift>::line_to(int x, int y)
+ {
if(m_clipping)
{
clip_segment(x, y);
@@ -656,9 +656,9 @@ namespace agg
}
//------------------------------------------------------------------------
- template<unsigned XScale, unsigned AA_Shift>
- void rasterizer_scanline_aa<XScale, AA_Shift>::close_polygon()
- {
+ template<unsigned XScale, unsigned AA_Shift>
+ void rasterizer_scanline_aa<XScale, AA_Shift>::close_polygon()
+ {
if(m_clipping)
{
clip_segment(m_start_x, m_start_y);
@@ -667,22 +667,22 @@ namespace agg
}
//------------------------------------------------------------------------
- template<unsigned XScale, unsigned AA_Shift>
- void rasterizer_scanline_aa<XScale, AA_Shift>::move_to_d(double x, double y)
- {
- move_to(poly_coord(x), poly_coord(y));
+ template<unsigned XScale, unsigned AA_Shift>
+ void rasterizer_scanline_aa<XScale, AA_Shift>::move_to_d(double x, double y)
+ {
+ move_to(poly_coord(x), poly_coord(y));
}
//------------------------------------------------------------------------
- template<unsigned XScale, unsigned AA_Shift>
- void rasterizer_scanline_aa<XScale, AA_Shift>::line_to_d(double x, double y)
- {
- line_to(poly_coord(x), poly_coord(y));
+ template<unsigned XScale, unsigned AA_Shift>
+ void rasterizer_scanline_aa<XScale, AA_Shift>::line_to_d(double x, double y)
+ {
+ line_to(poly_coord(x), poly_coord(y));
}
//------------------------------------------------------------------------
- template<unsigned XScale, unsigned AA_Shift>
+ template<unsigned XScale, unsigned AA_Shift>
bool rasterizer_scanline_aa<XScale, AA_Shift>::hit_test(int tx, int ty)
{
close_polygon();