summaryrefslogtreecommitdiff
path: root/src/include/main.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/include/main.h')
-rw-r--r--src/include/main.h31
1 files changed, 25 insertions, 6 deletions
diff --git a/src/include/main.h b/src/include/main.h
index fd295cf..8590904 100644
--- a/src/include/main.h
+++ b/src/include/main.h
@@ -183,6 +183,23 @@ struct sorted_file
uint64 Source_SortSize;
};
+struct shape_options {
+ int Visibility;
+ v4 FillCol = {1, 1, 1, 1};
+ v4 StrokeCol = {1, 1, 1, 1};
+ float StrokeWidth;
+};
+
+struct shape_layer {
+ uint16 Block_Bezier_Index[MAX_KEYFRAME_BLOCKS];
+ uint16 Block_Bezier_Count;
+ uint16 Point_Count;
+ bool32 IsClosed;
+ int Width;
+ int Height;
+ shape_options Opt;
+};
+
enum timeline_mode
{
timeline_mode_default,
@@ -190,7 +207,7 @@ enum timeline_mode
};
struct pen_state {
- bool32 IsActive;
+ shape_options Opt;
};
struct brush_state
@@ -251,8 +268,9 @@ struct interact_transform
enum hotkey_input
{
hotkey_none,
- hotkey_newpaintlayer,
- hotkey_newlayerfromsource,
+ hotkey_newlayer_source,
+ hotkey_newlayer_paint,
+ hotkey_newlayer_shape,
hotkey_deletelayer,
hotkey_undo,
hotkey_redo,
@@ -360,6 +378,7 @@ struct project_state
int32 PreviewSource = -1;
hotkey_input HotkeyInput;
+ real32 HotkeyExtra[4]; // bloat?
void *Dump1;
void *Dump2;
@@ -564,6 +583,7 @@ struct block_layer {
uint8 Occupied;
bool32 IsPrecomp;
+ bool32 IsShapeLayer;
bool32 Precomp_Toggled;
// NOTE(fox): References a precomp index if IsPrecomp is true, not a source index.
uint16 Block_Source_Index;
@@ -571,12 +591,11 @@ struct block_layer {
// References the precomp that the layer belongs to.
uint16 Block_Composition_Index;
- uint16 Block_Mask_Index[MAX_MASKS];
- uint16 Block_Mask_Count;
-
uint16 Block_Effect_Index[MAX_EFFECTS];
uint16 Block_Effect_Count;
+ shape_layer Shape;
+
blend_mode BlendMode;
union