Units: add support for light power units in Watt. Use for Eevee lights.
This affects point, spot and area lights. Sun light strength remains without a unit. This change does not affect .blend file compatibility in any way, as with the rest of the unit system it's purely a display and editing feature. Not used for Cycles yet, that will be done after unifying the settings with Eevee.
This commit is contained in:
@@ -131,6 +131,7 @@ static const EnumPropertyItem property_subtype_array_items[] = {
|
||||
{PROP_COLOR_GAMMA, "COLOR_GAMMA", 0, "Color Gamma", ""},
|
||||
{PROP_LAYER, "LAYER", 0, "Layer", ""},
|
||||
{PROP_LAYER_MEMBER, "LAYER_MEMBER", 0, "Layer Member", ""},
|
||||
{PROP_POWER, "Power", 0, "Power", ""},
|
||||
|
||||
{PROP_NONE, "NONE", 0, "None", ""},
|
||||
{0, NULL, 0, NULL, NULL},
|
||||
@@ -139,7 +140,7 @@ static const EnumPropertyItem property_subtype_array_items[] = {
|
||||
#define BPY_PROPDEF_SUBTYPE_ARRAY_DOC \
|
||||
" :arg subtype: Enumerator in ['COLOR', 'TRANSLATION', 'DIRECTION', " \
|
||||
"'VELOCITY', 'ACCELERATION', 'MATRIX', 'EULER', 'QUATERNION', 'AXISANGLE', " \
|
||||
"'XYZ', 'COLOR_GAMMA', 'LAYER', 'LAYER_MEMBER', 'NONE'].\n" \
|
||||
"'XYZ', 'COLOR_GAMMA', 'LAYER', 'LAYER_MEMBER', 'POWER', 'NONE'].\n" \
|
||||
" :type subtype: string\n"
|
||||
|
||||
/* PyObject's */
|
||||
@@ -1902,7 +1903,7 @@ static void bpy_prop_callback_assign_enum(struct PropertyRNA *prop, PyObject *ge
|
||||
" :type description: string\n" \
|
||||
|
||||
#define BPY_PROPDEF_UNIT_DOC \
|
||||
" :arg unit: Enumerator in ['NONE', 'LENGTH', 'AREA', 'VOLUME', 'ROTATION', 'TIME', 'VELOCITY', 'ACCELERATION', 'MASS', 'CAMERA'].\n" \
|
||||
" :arg unit: Enumerator in ['NONE', 'LENGTH', 'AREA', 'VOLUME', 'ROTATION', 'TIME', 'VELOCITY', 'ACCELERATION', 'MASS', 'CAMERA', 'POWER'].\n" \
|
||||
" :type unit: string\n" \
|
||||
|
||||
#define BPY_PROPDEF_NUM_MIN_DOC \
|
||||
|
@@ -59,6 +59,7 @@ static const char *bpyunits_ucategorie_items[] = {
|
||||
"VELOCITY",
|
||||
"ACCELERATION",
|
||||
"CAMERA",
|
||||
"POWER",
|
||||
NULL,
|
||||
};
|
||||
|
||||
|
Reference in New Issue
Block a user