Changeset View
Changeset View
Standalone View
Standalone View
source/blender/makesrna/intern/rna_camera.c
| /* SPDX-License-Identifier: GPL-2.0-or-later */ | /* SPDX-License-Identifier: GPL-2.0-or-later */ | ||||
| /** \file | /** \file | ||||
| * \ingroup RNA | * \ingroup RNA | ||||
| */ | */ | ||||
| #include <stdlib.h> | #include <stdlib.h> | ||||
| #include "DNA_camera_types.h" | #include "DNA_camera_types.h" | ||||
| #include "BLI_math.h" | #include "BLI_math.h" | ||||
| #include "BLT_translation.h" | |||||
| #include "RNA_access.h" | #include "RNA_access.h" | ||||
| #include "RNA_define.h" | #include "RNA_define.h" | ||||
| #include "rna_internal.h" | #include "rna_internal.h" | ||||
| #include "WM_api.h" | #include "WM_api.h" | ||||
| #include "WM_types.h" | #include "WM_types.h" | ||||
| ▲ Show 20 Lines • Show All 343 Lines • ▼ Show 20 Lines | RNA_def_property_ui_text( | ||||
| prop, "Show On Foreground", "Show this image in front of objects in viewport"); | prop, "Show On Foreground", "Show this image in front of objects in viewport"); | ||||
| RNA_def_property_update(prop, NC_CAMERA | ND_DRAW_RENDER_VIEWPORT, NULL); | RNA_def_property_update(prop, NC_CAMERA | ND_DRAW_RENDER_VIEWPORT, NULL); | ||||
| /* expose 1 flag as a enum of 2 items */ | /* expose 1 flag as a enum of 2 items */ | ||||
| prop = RNA_def_property(srna, "display_depth", PROP_ENUM, PROP_NONE); | prop = RNA_def_property(srna, "display_depth", PROP_ENUM, PROP_NONE); | ||||
| RNA_def_property_enum_bitflag_sdna(prop, NULL, "flag"); | RNA_def_property_enum_bitflag_sdna(prop, NULL, "flag"); | ||||
| RNA_def_property_enum_items(prop, bgpic_display_depth_items); | RNA_def_property_enum_items(prop, bgpic_display_depth_items); | ||||
| RNA_def_property_ui_text(prop, "Depth", "Display under or over everything"); | RNA_def_property_ui_text(prop, "Depth", "Display under or over everything"); | ||||
| RNA_def_property_translation_context(prop, BLT_I18NCONTEXT_ID_CAMERA); | |||||
| RNA_def_property_update(prop, NC_CAMERA | ND_DRAW_RENDER_VIEWPORT, NULL); | RNA_def_property_update(prop, NC_CAMERA | ND_DRAW_RENDER_VIEWPORT, NULL); | ||||
| /* expose 2 flags as a enum of 3 items */ | /* expose 2 flags as a enum of 3 items */ | ||||
| prop = RNA_def_property(srna, "frame_method", PROP_ENUM, PROP_NONE); | prop = RNA_def_property(srna, "frame_method", PROP_ENUM, PROP_NONE); | ||||
| RNA_def_property_enum_bitflag_sdna(prop, NULL, "flag"); | RNA_def_property_enum_bitflag_sdna(prop, NULL, "flag"); | ||||
| RNA_def_property_enum_items(prop, bgpic_camera_frame_items); | RNA_def_property_enum_items(prop, bgpic_camera_frame_items); | ||||
| RNA_def_property_ui_text(prop, "Frame Method", "How the image fits in the camera frame"); | RNA_def_property_ui_text(prop, "Frame Method", "How the image fits in the camera frame"); | ||||
| RNA_def_property_update(prop, NC_CAMERA | ND_DRAW_RENDER_VIEWPORT, NULL); | RNA_def_property_update(prop, NC_CAMERA | ND_DRAW_RENDER_VIEWPORT, NULL); | ||||
| ▲ Show 20 Lines • Show All 473 Lines • Show Last 20 Lines | |||||