graphic:python:blender

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revisionBoth sides next revision
graphic:python:blender [2024/01/31 06:41] – [Blender UI code] yinggraphic:python:blender [2024/01/31 07:41] – [Blender variable naming standards] ying
Line 393: Line 393:
 ref:  ref: 
   * https://wiki.blender.org/wiki/Reference/Release_Notes/2.80/Python_API/Addons   * https://wiki.blender.org/wiki/Reference/Release_Notes/2.80/Python_API/Addons
 +  * https://developer.blender.org/docs/release_notes/2.80/python_api/addons/
   * https://s-nako.work/2020/12/blender-addon-naming-rules/   * https://s-nako.work/2020/12/blender-addon-naming-rules/
 +  * https://b3d.interplanety.org/en/class-naming-conventions-in-blender-2-8-python-api/
  
   * **Class name convention**: UPPER_CASE_{SEPARATOR}_mixed_case   * **Class name convention**: UPPER_CASE_{SEPARATOR}_mixed_case
Line 422: Line 424:
  
 Example of class name, balancing between Python PEP Example of class name, balancing between Python PEP
-  * BLOSM addon, <code python>+  * example addon, <code python> 
 +class BUILDMAKER_OT_CreateAsset(bpy.types.Operator): 
 +    bl_idname = "custom.buildmaker_create_asset" 
 +     
 +class CreateAsset(bpy.types.Operator): 
 +    bl_idname = "BUILDMAKER_OT_CreateAsset" 
 + 
 +class BUILDMAKER_OT_createAsset(bpy.types.Operator): 
 + 
 +# 2.8x onwards, property 
 +class MyOperator(bpy.types.Operator): 
 +    value: IntProperty()
  
 </code> </code>
  • graphic/python/blender.txt
  • Last modified: 2024/06/12 06:47
  • by ying