Blender Git Commit Log

Git Commits -> Revision 5c6fd58

Revision 5c6fd58 by Campbell Barton (master)
November 18, 2008, 13:51 (GMT)
Some improvements brecht suggested, only noticable change is faster multithreading

General optimizations
* Precompute 1/x when dividing by x multiple times.
* Use float constants like 0.0f instead of 0.0, avoids conversions from float to doubles and back.

ProjectPixel
* make pixel (and similar pointers elsewhere) a union with a float and unsigned int pointer to reduce the number of casts a little. generally there are a lot of casts going on in the code, makes it hard to read.

project_paint_begin()
* the perspective case checks with (*projScreenCo)[3] > 0.001) for faces behind the view. - Changed to use the clip start from get_view3d_viewplane
* removed arbitrary check for brush size to disable threads.

imapaint_paint_sub_stroke_project()
* Make clone tool use IMB_blend_color to reduce the code and support blend modes.

imapaint_paint_sub_stroke_project_mt()
* Make threaded and non threaded mode use same function (just dont start threads when its set to 1)
* removed PIL_sleep_ms, was not needed and slowed down threading (my bad!, was copied from bake code).


Commit Details:

Full Hash: 5c6fd58a79967fbc316b8834593b14dbf43abf83
SVN Revision: 17496
Parent Commit: 52ab2f5
Lines Changed: +270, -264

1 Modified Path:

/source/blender/src/imagepaint.c (+270, -264) (Diff)
By: Miika HämäläinenLast update: Nov-07-2014 14:18MiikaHweb | 2003-2021