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

git.blender.org/blender-addons.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCampbell Barton <ideasman42@gmail.com>2017-07-24 18:42:10 +0300
committerCampbell Barton <ideasman42@gmail.com>2017-07-24 18:43:02 +0300
commit49230a4c122013bf851ab37b029e7d4f624d68ad (patch)
tree5cbf15367b776c1086376071a16d66604177c998 /space_view3d_stored_views/properties.py
parentd1b57c76ad5cfd475ad270a93fed2c530fc3e7d0 (diff)
Cleanup: use common prefix for addons
Diffstat (limited to 'space_view3d_stored_views/properties.py')
-rw-r--r--space_view3d_stored_views/properties.py126
1 files changed, 126 insertions, 0 deletions
diff --git a/space_view3d_stored_views/properties.py b/space_view3d_stored_views/properties.py
new file mode 100644
index 00000000..6dffc3d0
--- /dev/null
+++ b/space_view3d_stored_views/properties.py
@@ -0,0 +1,126 @@
+# gpl authors: nfloyd, Francesco Siddi
+
+from bpy.types import PropertyGroup
+from bpy.props import (
+ BoolProperty,
+ BoolVectorProperty,
+ CollectionProperty,
+ FloatProperty,
+ FloatVectorProperty,
+ EnumProperty,
+ IntProperty,
+ IntVectorProperty,
+ PointerProperty,
+ StringProperty,
+ )
+
+
+class POVData(PropertyGroup):
+ distance = FloatProperty()
+ location = FloatVectorProperty(
+ subtype='TRANSLATION'
+ )
+ rotation = FloatVectorProperty(
+ subtype='QUATERNION',
+ size=4
+ )
+ name = StringProperty()
+ perspective = EnumProperty(
+ items=[('PERSP', '', ''),
+ ('ORTHO', '', ''),
+ ('CAMERA', '', '')]
+ )
+ lens = FloatProperty()
+ clip_start = FloatProperty()
+ clip_end = FloatProperty()
+ lock_cursor = BoolProperty()
+ cursor_location = FloatVectorProperty()
+ perspective_matrix_md5 = StringProperty()
+ camera_name = StringProperty()
+ camera_type = StringProperty()
+ camera_pointer = IntProperty()
+ lock_object_name = StringProperty()
+ lock_object_pointer = IntProperty()
+
+
+class LayersData(PropertyGroup):
+ view_layers = BoolVectorProperty(size=20)
+ scene_layers = BoolVectorProperty(size=20)
+ lock_camera_and_layers = BoolProperty()
+ name = StringProperty()
+
+
+class DisplayData(PropertyGroup):
+ name = StringProperty()
+ viewport_shade = EnumProperty(
+ items=[('BOUNDBOX', 'BOUNDBOX', 'BOUNDBOX'),
+ ('WIREFRAME', 'WIREFRAME', 'WIREFRAME'),
+ ('SOLID', 'SOLID', 'SOLID'),
+ ('TEXTURED', 'TEXTURED', 'TEXTURED'),
+ ('MATERIAL', 'MATERIAL', 'MATERIAL'),
+ ('RENDERED', 'RENDERED', 'RENDERED')]
+ )
+ show_only_render = BoolProperty()
+ show_outline_selected = BoolProperty()
+ show_all_objects_origin = BoolProperty()
+ show_relationship_lines = BoolProperty()
+ show_floor = BoolProperty()
+ show_axis_x = BoolProperty()
+ show_axis_y = BoolProperty()
+ show_axis_z = BoolProperty()
+ grid_lines = IntProperty()
+ grid_scale = FloatProperty()
+ grid_subdivisions = IntProperty()
+ material_mode = EnumProperty(
+ items=[('TEXTURE_FACE', '', ''),
+ ('MULTITEXTURE', '', ''),
+ ('GLSL', '', '')]
+ )
+ show_textured_solid = BoolProperty()
+ quad_view = BoolProperty()
+ lock_rotation = BoolProperty()
+ show_sync_view = BoolProperty()
+ use_box_clip = BoolProperty()
+
+
+class ViewData(PropertyGroup):
+ pov = PointerProperty(
+ type=POVData
+ )
+ layers = PointerProperty(
+ type=LayersData
+ )
+ display = PointerProperty(
+ type=DisplayData
+ )
+ name = StringProperty()
+
+
+class StoredViewsData(PropertyGroup):
+ pov_list = CollectionProperty(
+ type=POVData
+ )
+ layers_list = CollectionProperty(
+ type=LayersData
+ )
+ display_list = CollectionProperty(
+ type=DisplayData
+ )
+ view_list = CollectionProperty(
+ type=ViewData
+ )
+ mode = EnumProperty(
+ name="Mode",
+ items=[('VIEW', "View", "3D View settings"),
+ ('POV', "POV", "POV settings"),
+ ('LAYERS', "Layers", "Layers settings"),
+ ('DISPLAY', "Display", "Display settings")],
+ default='VIEW'
+ )
+ current_indices = IntVectorProperty(
+ size=4,
+ default=[-1, -1, -1, -1]
+ )
+ view_modified = BoolProperty(
+ default=False
+ )