Polygons are now filled with antialiasing, if context_antialias is set.
So are ellipses.
I fixed some clipping bugs.
There is a bug with the AA span though, it's just a little one, but I'm too
tired to find it now. You will see it if you look closely at the top of the
filled ellipse in test/imlib2, using xmag or something.
I'll fix that tomorrow, speed things up a bit, and hopefully implement AA
drawing for ellipse outlines. Oh, I'll unroll some more loops too.
raster: your last commit broke the two test apps. a segv in _RGBA_init()
somewhere, I know it's not my new code, as I tried a fresh checkout and it
did the same thing. I don't have time to check it out tonight though.
SVN revision: 3498
clipping rect, but highly suboptimally (I'm not doing proper polygon
clipping here yet, just clipping slowly on each point drawn - really nasty).
There are probably some rounding errors in here. I need to work more on
this, but I have *so* little time for the next few weeks.
Please don't kill me for this code. It's not finished, but I'm about to move
house, and I have to get something working before I pack my PC away.
SVN revision: 3303
Hard to come up with a nice API for this, but here's what I have:
ImlibPolygon imlib_polygon_new(int type);
void imlib_polygon_free(ImlibPolygon poly);
void imlib_polygon_add_point(ImlibPolygon poly, int x, int y);
void imlib_image_draw_polygon(ImlibPolygon poly);
Clipping works with these, as demonstrated by test/imlib2
The type paramter may be: POLY_OPEN, POLY_CLOSED or POLY_FILLED (last one
not implemented yet).
I was wondering if draw_polygon should genererate updates, like draw_line.
Thoughts?
SVN revision: 3279
Removed all the _clipped functions.
Added imlib_context_set_cliprect(int x, int y, int w, int h) and a
corresponding _get_cliprect.
Set width to 0 to disable clipping (default).
Just use the normal _draw_ functions and it'll do the Right thing.
SVN revision: 3278
void
imlib_image_draw_rectangle_clipped(int x, int y, int width, int height,
int clip_xmin, int clip_xmax, int clip_ymin,
int clip_ymax);
Works well. If you make install then cd test, make, ./imlib2, you'll see the
demo/test of the clipping code.
Next up: draw_polygon and draw_polygon_clipped.
Then (eeek) fill_polygon, fill_polygon_clipped, and some clipping for image
blending (fun).
SVN revision: 3276
Same as _draw_line but with extra parameters for the clipping region.
Tested and seems to work well. Will check further tomorrow when I convert
geist to use this instead of doing it internally.
Imlib_Updates
imlib_image_draw_line_clipped(int x1, int y1, int x2, int y2,
int clip_xmin, int clip_xmax, int clip_ymin,
int clip_ymax, char make_updates);
SVN revision: 3273
-bmp2pt add this too it's command line and it'll bump map to where the
cursor is.
otherwise you will just get bump mapping from an infinite dist lightsource
SVN revision: 2687
variable to another filter as willem requested the other day.
eg.
filter( var=anotherfilter( var=13,var=30 ), var=blum );
youcan have as manylevels of filters as you want.
* parser should be quicker, no need to add "NULL" to the end of a
imlib_apply_filter() command.
* some more funky filters should be added soon, at 4.45am i decided to leave
that job till t/m.
SVN revision: 2686