Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAntony Riakiotakis <kalast@gmail.com>2014-03-17 05:28:30 +0400
committerAntony Riakiotakis <kalast@gmail.com>2014-03-19 23:10:43 +0400
commitedfeb712eb93ba2479145b34c0e4cdb730b5f3bf (patch)
tree8202560870a2bc410e0f51a25b2c43efeec75576 /source/blender/blenkernel/BKE_paint.h
parent41b33d8fe64994f4b5e67bc63322f76e89b99ad7 (diff)
Reusable curves for the paint systems:
This commit includes the following: * Per brush curve setting that allows setting a different curve per brush. Those curves stay in memory and can be edited and reused accordingly. To make sure that a curve is saved in a file users need to add a fake user, similar to other datablocks. * Interface while using curves is now non blocking. Users can pan, rotate, and zoom the view while able to select and edit curve points as previously in the GSOC branch. Code internally uses the transform system. This needs some tweaking still but it should be similar to the previous GSOC system. This may change in the future to be more compatible with other curve systems (ie enable choosing handle type etc.)
Diffstat (limited to 'source/blender/blenkernel/BKE_paint.h')
-rw-r--r--source/blender/blenkernel/BKE_paint.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/source/blender/blenkernel/BKE_paint.h b/source/blender/blenkernel/BKE_paint.h
index a5ba8881df6..d1894a307a0 100644
--- a/source/blender/blenkernel/BKE_paint.h
+++ b/source/blender/blenkernel/BKE_paint.h
@@ -45,6 +45,7 @@ struct MultireModifierData;
struct MVert;
struct Object;
struct Paint;
+struct PaintCurve;
struct PBVH;
struct Scene;
struct StrokeCache;
@@ -102,6 +103,10 @@ struct PaletteColor *BKE_palette_color_get_last(struct Palette *palette);
bool BKE_palette_is_empty(const struct Palette *palette);
void BKE_palette_remove_color (struct Palette *palette, struct PaletteColor *colour);
+/* paint curves */
+struct PaintCurve *BKE_paint_curve_add(struct Main *bmain, const char *name);
+void BKE_free_paint_curve(struct PaintCurve *pc);
+
void BKE_paint_init(struct Paint *p, const char col[3]);
void BKE_paint_free(struct Paint *p);
void BKE_paint_copy(struct Paint *src, struct Paint *tar);
@@ -113,6 +118,7 @@ struct Brush *BKE_paint_brush(struct Paint *paint);
void BKE_paint_brush_set(struct Paint *paint, struct Brush *br);
struct Palette *BKE_paint_palette(struct Paint *paint);
void BKE_paint_palette_set(struct Paint *p, struct Palette *palette);
+void BKE_paint_curve_set(struct Brush *br, struct PaintCurve *pc);
/* testing face select mode
* Texture paint could be removed since selected faces are not used