Changeset View
Changeset View
Standalone View
Standalone View
sun_position/__init__.py
| Show All 10 Lines | |||||
| # The geo parser script is by Maximilian Högner, released | # The geo parser script is by Maximilian Högner, released | ||||
| # under the GNU GPL license: | # under the GNU GPL license: | ||||
| # http://hoegners.de/Maxi/geo/ | # http://hoegners.de/Maxi/geo/ | ||||
| # -------------------------------------------------------------------------- | # -------------------------------------------------------------------------- | ||||
| bl_info = { | bl_info = { | ||||
| "name": "Sun Position", | "name": "Sun Position", | ||||
| "author": "Michael Martin", | "author": "Michael Martin", | ||||
| "version": (3, 1, 3), | "version": (3, 2, 0), | ||||
| "blender": (3, 0, 0), | "blender": (3, 0, 0), | ||||
| "location": "World > Sun Position", | "location": "World > Sun Position", | ||||
| "description": "Show sun position with objects and/or sky texture", | "description": "Show sun position with objects and/or sky texture", | ||||
| "doc_url": "{BLENDER_MANUAL_URL}/addons/lighting/sun_position.html", | "doc_url": "{BLENDER_MANUAL_URL}/addons/lighting/sun_position.html", | ||||
| "category": "Lighting", | "category": "Lighting", | ||||
| } | } | ||||
| if "bpy" in locals(): | if "bpy" in locals(): | ||||
| Show All 15 Lines | register_classes, unregister_classes = bpy.utils.register_classes_factory( | ||||
| properties.SunPosAddonPreferences, ui_sun.SUNPOS_OT_AddPreset, | properties.SunPosAddonPreferences, ui_sun.SUNPOS_OT_AddPreset, | ||||
| ui_sun.SUNPOS_MT_Presets, ui_sun.SUNPOS_PT_Panel, | ui_sun.SUNPOS_MT_Presets, ui_sun.SUNPOS_PT_Panel, | ||||
| ui_sun.SUNPOS_PT_Location, ui_sun.SUNPOS_PT_Time, hdr.SUNPOS_OT_ShowHdr)) | ui_sun.SUNPOS_PT_Location, ui_sun.SUNPOS_PT_Time, hdr.SUNPOS_OT_ShowHdr)) | ||||
| @persistent | @persistent | ||||
| def sun_scene_handler(scene): | def sun_scene_handler(scene): | ||||
| sun_props = bpy.context.scene.sun_pos_properties | sun_props = bpy.context.scene.sun_pos_properties | ||||
| sun_props.show_surface = sun_props.show_surface | |||||
| sun_props.show_analemmas = sun_props.show_analemmas | |||||
| sun_props.show_north = sun_props.show_north | sun_props.show_north = sun_props.show_north | ||||
| def register(): | def register(): | ||||
| register_classes() | register_classes() | ||||
| bpy.types.Scene.sun_pos_properties = ( | bpy.types.Scene.sun_pos_properties = ( | ||||
| bpy.props.PointerProperty(type=properties.SunPosProperties, | bpy.props.PointerProperty(type=properties.SunPosProperties, | ||||
| name="Sun Position", | name="Sun Position", | ||||
| Show All 11 Lines | |||||