diff options
author | Jeroen Bakker <j.bakker@atmind.nl> | 2018-07-05 15:38:14 +0300 |
---|---|---|
committer | Jeroen Bakker <j.bakker@atmind.nl> | 2018-07-05 17:46:06 +0300 |
commit | f7ec70895c78900db8e7db88d3713ebb9aa62730 (patch) | |
tree | 40aed2e1ab618eb5fe829ce11d7033e2fc0e92a2 /source/blender/makesdna | |
parent | a4328a4b70f80bbb1c2e8df3b95b793dc5f6fb06 (diff) |
Overlay: enable/disable drawing of specific object types.
Added a option to the overlay popover that controls the visibility of
non-renderable objects like lamps, cameras, speakers, armatures, curves
empties and force fields.
After discussion we went for a single option with more detailed check in
the object_mode draw engine.
Differential Revision: https://developer.blender.org/D3524
Diffstat (limited to 'source/blender/makesdna')
-rw-r--r-- | source/blender/makesdna/DNA_view3d_types.h | 14 |
1 files changed, 13 insertions, 1 deletions
diff --git a/source/blender/makesdna/DNA_view3d_types.h b/source/blender/makesdna/DNA_view3d_types.h index 70f06b2eda0..f7fd4a52a5f 100644 --- a/source/blender/makesdna/DNA_view3d_types.h +++ b/source/blender/makesdna/DNA_view3d_types.h @@ -49,6 +49,7 @@ struct GPUViewport; #include "DNA_defs.h" #include "DNA_listBase.h" #include "DNA_image_types.h" +#include "DNA_object_types.h" #include "DNA_movieclip_types.h" #include "DNA_gpu_types.h" @@ -178,8 +179,8 @@ typedef struct View3DOverlay { /* Other settings */ float wireframe_threshold; + int visible_object_types; - int pad; } View3DOverlay; /* 3D ViewPort Struct */ @@ -383,6 +384,17 @@ enum { V3D_OVERLAY_ONION_SKINS = (1 << 7), }; +/* View3DOverlay->visible_object_types */ +enum { + V3D_OVERLAY_SHOW_EMPTY = (1 << OB_EMPTY), + V3D_OVERLAY_SHOW_LAMP = (1 << OB_LAMP), + V3D_OVERLAY_SHOW_CAMERA = (1 << OB_CAMERA), + V3D_OVERLAY_SHOW_SPEAKER = (1 << OB_SPEAKER), + V3D_OVERLAY_SHOW_LIGHTPROBE = (1 << OB_LIGHTPROBE), + V3D_OVERLAY_SHOW_ARMATURE = (1 << OB_ARMATURE), +}; +#define V3D_OVERLAY_VISIBLE_OBJECT_TYPES_MASK (V3D_OVERLAY_SHOW_EMPTY | V3D_OVERLAY_SHOW_LAMP | V3D_OVERLAY_SHOW_CAMERA | V3D_OVERLAY_SHOW_SPEAKER | V3D_OVERLAY_SHOW_LIGHTPROBE | V3D_OVERLAY_SHOW_ARMATURE) + /* View3DOverlay->edit_flag */ enum { V3D_OVERLAY_EDIT_VERT_NORMALS = (1 << 0), |