diff options
author | Campbell Barton <ideasman42@gmail.com> | 2019-09-11 23:48:13 +0300 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2019-09-11 23:48:13 +0300 |
commit | ff085e85d3d9824cb0f0b11272e618f6d3272293 (patch) | |
tree | f7f79e73d812ee43f302974db7a505faaf38c618 /source/blender/makesdna/DNA_view3d_defaults.h | |
parent | 6db00065c5e7f0e16e6970d6351560c36a9536ba (diff) |
DNA: move View3D, View3DOverlay into DNA_view3d_defaults.h
Diffstat (limited to 'source/blender/makesdna/DNA_view3d_defaults.h')
-rw-r--r-- | source/blender/makesdna/DNA_view3d_defaults.h | 54 |
1 files changed, 54 insertions, 0 deletions
diff --git a/source/blender/makesdna/DNA_view3d_defaults.h b/source/blender/makesdna/DNA_view3d_defaults.h index 2964e77a421..365b1993d80 100644 --- a/source/blender/makesdna/DNA_view3d_defaults.h +++ b/source/blender/makesdna/DNA_view3d_defaults.h @@ -48,6 +48,27 @@ .studiolight_intensity = 1.0f, \ } +#define _DNA_DEFAULT_View3DOverlay \ + { \ + .wireframe_threshold = 1.0f, \ + .xray_alpha_bone = 0.5f, \ + .texture_paint_mode_opacity = 1.0f, \ + .weight_paint_mode_opacity = 1.0f, \ + .vertex_paint_mode_opacity = 1.0f, \ + /* Intentionally different to vertex/paint mode, \ + * we typically want to see shading too. */ \ + .sculpt_mode_mask_opacity = 0.75f, \ + \ + .edit_flag = V3D_OVERLAY_EDIT_FACES | V3D_OVERLAY_EDIT_SEAMS | \ + V3D_OVERLAY_EDIT_SHARP | V3D_OVERLAY_EDIT_FREESTYLE_EDGE | \ + V3D_OVERLAY_EDIT_FREESTYLE_FACE | V3D_OVERLAY_EDIT_EDGES | \ + V3D_OVERLAY_EDIT_CREASES | V3D_OVERLAY_EDIT_BWEIGHTS | \ + V3D_OVERLAY_EDIT_CU_HANDLES | V3D_OVERLAY_EDIT_CU_NORMALS, \ + \ + .gpencil_paper_opacity = 0.5f, \ + .gpencil_grid_opacity = 0.9f, \ + } + #define _DNA_DEFAULT_View3DCursor \ { \ .rotation_mode = ROT_MODE_XYZ, \ @@ -55,6 +76,39 @@ .rotation_axis = {0, 1, 0}, \ } +#define _DNA_DEFAULT_View3D \ + { \ + .spacetype = SPACE_VIEW3D, \ + .scenelock = true, \ + .grid = 1.0f, \ + .gridlines = 16, \ + .gridsubdiv = 10, \ + .shading = _DNA_DEFAULT_View3DShading, \ + .overlay = _DNA_DEFAULT_View3DOverlay, \ + \ + .gridflag = V3D_SHOW_X | V3D_SHOW_Y | V3D_SHOW_FLOOR | V3D_SHOW_ORTHO_GRID, \ + \ + .flag = V3D_SELECT_OUTLINE, \ + .flag2 = V3D_SHOW_RECONSTRUCTION | V3D_SHOW_ANNOTATION, \ + \ + .lens = 50.0f, \ + .clip_start = 0.01f, \ + .clip_end = 1000.0f, \ + \ + .bundle_size = 0.2f, \ + .bundle_drawtype = OB_PLAINAXES, \ + \ + /* stereo */ \ + .stereo3d_camera = STEREO_3D_ID, \ + .stereo3d_flag = V3D_S3D_DISPPLANE, \ + .stereo3d_convergence_alpha = 0.15f, \ + .stereo3d_volume_alpha = 0.05f, \ + \ + /* Grease pencil settings. */ \ + .vertex_opacity = 1.0f, \ + .gp_flag = V3D_GP_SHOW_EDIT_LINES, \ + } + /** \} */ /* clang-format on */ |