Blender Git Commit Log

Git Commits -> Revision 41bf595

Revision 41bf595 by Antonis Ryakiotakis (master)
March 7, 2013, 12:11 (GMT)
Texture paint refactoring commit

This is as close as I can get to keeping the old code intact. After this
commit, I will have to change existing code paths, making testing of
functionality harder.

Changes:

* Keep only projective texturing code in paint_image_proj.c
* Move 2D code to paint_image_2d.c. This needed the introduction of
allocation/cleanup functions for the relevant structures.
* Common code interface for both modes stays in paint_image.c (which
still includes all old code, system should work as it did with the
exception of non-projective 3D paint mode) and is made public. This is
not a lot of code, only rectangle invalidation and undo system.
* Changed the naming in the new code slightly: imapaint_ prefixed functions refer to
common functions used by both systems, paint_2d_ prefixed to 2d
painting. There will be an interface for the projection painting as
well. Probably there is some leftover naming conversions to do.

TODO:

* Move operator init/exec/modal to common interface file
* Get rid of old BKE_brush_painter_paint, now brush_painter_2d_paint.
All code uses stroke system for the stroke management
* Write space pressure management for the paint stroke system (for other
systems to access as well :) )
* Move texture paint tablet presssure exception code for old bugs to
stroke system (makes me wonder...aren't other systems also influenced by
these pressure issues?) or up in the function hierarchy inside texture
paint. This code is still not there so users with tablets may notice
some issues.
* possibly change other systems to pre-multiply pressure with the
relevant influenced attributes in the stroke function. This could get
tricky though and it's possible that it could backfire.

Commit Details:

Full Hash: 41bf595c5f57247beee262005aab8a0d723660c5
SVN Revision: 55090
Parent Commit: 28b9abe
Lines Changed: +642, -721

8 Modified Paths:

/source/blender/blenkernel/BKE_brush.h (+5, -5) (Diff)
/source/blender/blenkernel/BKE_paint.h (+1, -1) (Diff)
/source/blender/blenkernel/intern/brush.c (+44, -0) (Diff)
/source/blender/editors/sculpt_paint/paint_image.c (+25, -22) (Diff)
/source/blender/editors/sculpt_paint/paint_image_2d.c (+505, -56) (Diff)
/source/blender/editors/sculpt_paint/paint_image_proj.c (+31, -636) (Diff)
/source/blender/editors/sculpt_paint/paint_intern.h (+26, -0) (Diff)
/source/blender/editors/sculpt_paint/paint_stroke.c (+5, -1) (Diff)
By: Miika HämäläinenLast update: Nov-07-2014 14:18MiikaHweb | 2003-2021