|
Blender
V2.93
|
#include <Python.h>#include <float.h>#include <stddef.h>#include "RNA_types.h"#include "BLI_bitmap.h"#include "BLI_dynstr.h"#include "BLI_listbase.h"#include "BLI_math_rotation.h"#include "BLI_string.h"#include "BLI_utildefines.h"#include "BPY_extern.h"#include "BPY_extern_clog.h"#include "bpy_capi_utils.h"#include "bpy_intern_string.h"#include "bpy_props.h"#include "bpy_rna.h"#include "bpy_rna_anim.h"#include "bpy_rna_callback.h"#include "RNA_access.h"#include "RNA_define.h"#include "RNA_enum_types.h"#include "CLG_log.h"#include "MEM_guardedalloc.h"#include "BKE_context.h"#include "BKE_global.h"#include "BKE_idprop.h"#include "BKE_idtype.h"#include "BKE_main.h"#include "BKE_report.h"#include "BKE_node.h"#include "DEG_depsgraph_query.h"#include "../generic/idprop_py_api.h"#include "../generic/py_capi_utils.h"#include "../generic/python_utildefines.h"#include "../mathutils/mathutils.h"Go to the source code of this file.
Classes | |
| struct | BPy_TypesModule_State |
Macros | |
| #define | USE_PEDANTIC_WRITE |
| #define | USE_MATHUTILS |
| #define | USE_STRING_COERCE |
| #define | USE_POSTPONED_ANNOTATIONS |
| #define | BPY_DOC_ID_PROP_TYPE_NOTE |
| #define | MATHUTILS_CB_SUBTYPE_EUL 0 |
| #define | MATHUTILS_CB_SUBTYPE_VEC 1 |
| #define | MATHUTILS_CB_SUBTYPE_QUAT 2 |
| #define | MATHUTILS_CB_SUBTYPE_COLOR 3 |
| #define | PROP_ALL_VECTOR_SUBTYPES |
| #define | PYRNA_PROP_COLLECTION_ABS_INDEX(ret_err) |
| #define | BPY_REPLACEMENT_STRING(rna_attr, py_attr) |
Functions | |
| static PyObject * | pyrna_struct_Subtype (PointerRNA *ptr) |
| static PyObject * | pyrna_prop_collection_values (BPy_PropertyRNA *self) |
| static PyObject * | pyrna_register_class (PyObject *self, PyObject *py_class) |
| static PyObject * | pyrna_unregister_class (PyObject *self, PyObject *py_class) |
| int | pyrna_struct_validity_check (BPy_StructRNA *pysrna) |
| int | pyrna_prop_validity_check (BPy_PropertyRNA *self) |
| void | pyrna_invalidate (BPy_DummyPointerRNA *self) |
| void | BPY_id_release (struct ID *id) |
| static bool | rna_id_write_error (PointerRNA *ptr, PyObject *key) |
| bool | pyrna_write_check (void) |
| void | pyrna_write_set (bool val) |
| static Py_ssize_t | pyrna_prop_collection_length (BPy_PropertyRNA *self) |
| static Py_ssize_t | pyrna_prop_array_length (BPy_PropertyArrayRNA *self) |
| static int | pyrna_py_to_prop (PointerRNA *ptr, PropertyRNA *prop, void *data, PyObject *value, const char *error_prefix) |
| static int | deferred_register_prop (StructRNA *srna, PyObject *key, PyObject *item) |
| static PyObject * | pyrna_prop_array_subscript_slice (BPy_PropertyArrayRNA *self, PointerRNA *ptr, PropertyRNA *prop, Py_ssize_t start, Py_ssize_t stop, Py_ssize_t length) |
| static short | pyrna_rotation_euler_order_get (PointerRNA *ptr, const short order_fallback, PropertyRNA **r_prop_eul_order) |
| static int | mathutils_rna_generic_check (BaseMathObject *bmo) |
| static int | mathutils_rna_vector_get (BaseMathObject *bmo, int subtype) |
| static int | mathutils_rna_vector_set (BaseMathObject *bmo, int subtype) |
| static int | mathutils_rna_vector_get_index (BaseMathObject *bmo, int UNUSED(subtype), int index) |
| static int | mathutils_rna_vector_set_index (BaseMathObject *bmo, int UNUSED(subtype), int index) |
| static int | mathutils_rna_matrix_get (BaseMathObject *bmo, int UNUSED(subtype)) |
| static int | mathutils_rna_matrix_set (BaseMathObject *bmo, int UNUSED(subtype)) |
| PyObject * | pyrna_math_object_from_array (PointerRNA *ptr, PropertyRNA *prop) |
| int | pyrna_enum_value_from_id (const EnumPropertyItem *item, const char *identifier, int *r_value, const char *error_prefix) |
| static int | pyrna_struct_compare (BPy_StructRNA *a, BPy_StructRNA *b) |
| static int | pyrna_prop_compare (BPy_PropertyRNA *a, BPy_PropertyRNA *b) |
| static PyObject * | pyrna_struct_richcmp (PyObject *a, PyObject *b, int op) |
| static PyObject * | pyrna_prop_richcmp (PyObject *a, PyObject *b, int op) |
| static PyObject * | pyrna_struct_str (BPy_StructRNA *self) |
| static PyObject * | pyrna_struct_repr (BPy_StructRNA *self) |
| static PyObject * | pyrna_prop_str (BPy_PropertyRNA *self) |
| static PyObject * | pyrna_prop_repr_ex (BPy_PropertyRNA *self, const int index_dim, const int index) |
| static PyObject * | pyrna_prop_repr (BPy_PropertyRNA *self) |
| static PyObject * | pyrna_prop_array_repr (BPy_PropertyArrayRNA *self) |
| static PyObject * | pyrna_func_repr (BPy_FunctionRNA *self) |
| static Py_hash_t | pyrna_struct_hash (BPy_StructRNA *self) |
| static long | pyrna_prop_hash (BPy_PropertyRNA *self) |
| static void | pyrna_struct_dealloc (BPy_StructRNA *self) |
| static void | pyrna_prop_dealloc (BPy_PropertyRNA *self) |
| static void | pyrna_prop_array_dealloc (BPy_PropertyRNA *self) |
| static const char * | pyrna_enum_as_string (PointerRNA *ptr, PropertyRNA *prop) |
| static int | pyrna_string_to_enum (PyObject *item, PointerRNA *ptr, PropertyRNA *prop, int *r_value, const char *error_prefix) |
| BLI_bitmap * | pyrna_set_to_enum_bitmap (const EnumPropertyItem *items, PyObject *value, int type_size, bool type_convert_sign, int bitmap_size, const char *error_prefix) |
| int | pyrna_set_to_enum_bitfield (const EnumPropertyItem *items, PyObject *value, int *r_value, const char *error_prefix) |
| static int | pyrna_prop_to_enum_bitfield (PointerRNA *ptr, PropertyRNA *prop, PyObject *value, int *r_value, const char *error_prefix) |
| PyObject * | pyrna_enum_bitfield_to_py (const EnumPropertyItem *items, int value) |
| static PyObject * | pyrna_enum_to_py (PointerRNA *ptr, PropertyRNA *prop, int val) |
| PyObject * | pyrna_prop_to_py (PointerRNA *ptr, PropertyRNA *prop) |
| int | pyrna_pydict_to_props (PointerRNA *ptr, PyObject *kw, const bool all_args, const char *error_prefix) |
| static PyObject * | pyrna_func_to_py (const PointerRNA *ptr, FunctionRNA *func) |
| static PyObject * | pyrna_prop_array_to_py_index (BPy_PropertyArrayRNA *self, int index) |
| static int | pyrna_py_to_prop_array_index (BPy_PropertyArrayRNA *self, int index, PyObject *value) |
| static int | pyrna_prop_array_bool (BPy_PropertyRNA *self) |
| static int | pyrna_prop_collection_bool (BPy_PropertyRNA *self) |
| static PyObject * | pyrna_prop_collection_subscript_int (BPy_PropertyRNA *self, Py_ssize_t keynum) |
| static int | pyrna_prop_collection_ass_subscript_int (BPy_PropertyRNA *self, Py_ssize_t keynum, PyObject *value) |
| static PyObject * | pyrna_prop_array_subscript_int (BPy_PropertyArrayRNA *self, int keynum) |
| static PyObject * | pyrna_prop_collection_subscript_str (BPy_PropertyRNA *self, const char *keyname) |
| static int | pyrna_prop_collection_subscript_str_lib_pair_ptr (BPy_PropertyRNA *self, PyObject *key, const char *err_prefix, const short err_not_found, PointerRNA *r_ptr) |
| static PyObject * | pyrna_prop_collection_subscript_str_lib_pair (BPy_PropertyRNA *self, PyObject *key, const char *err_prefix, const bool err_not_found) |
| static PyObject * | pyrna_prop_collection_subscript_slice (BPy_PropertyRNA *self, Py_ssize_t start, Py_ssize_t stop) |
| static PyObject * | pyrna_prop_collection_subscript (BPy_PropertyRNA *self, PyObject *key) |
| static int | pyrna_prop_collection_type_check (BPy_PropertyRNA *self, PyObject *value) |
| static int | pyrna_prop_collection_ass_subscript (BPy_PropertyRNA *self, PyObject *key, PyObject *value) |
| static PyObject * | pyrna_prop_array_subscript (BPy_PropertyArrayRNA *self, PyObject *key) |
| static PyObject * | prop_subscript_ass_array_slice__as_seq_fast (PyObject *value, int length) |
| static int | prop_subscript_ass_array_slice__float_recursive (PyObject **value_items, float *value, int totdim, const int dimsize[], const float range[2]) |
| static int | prop_subscript_ass_array_slice__int_recursive (PyObject **value_items, int *value, int totdim, const int dimsize[], const int range[2]) |
| static int | prop_subscript_ass_array_slice__bool_recursive (PyObject **value_items, bool *value, int totdim, const int dimsize[]) |
| static int | prop_subscript_ass_array_slice (PointerRNA *ptr, PropertyRNA *prop, int arraydim, int arrayoffset, int start, int stop, int length, PyObject *value_orig) |
| static int | prop_subscript_ass_array_int (BPy_PropertyArrayRNA *self, Py_ssize_t keynum, PyObject *value) |
| static int | pyrna_prop_array_ass_subscript (BPy_PropertyArrayRNA *self, PyObject *key, PyObject *value) |
| static int | pyrna_prop_array_contains (BPy_PropertyRNA *self, PyObject *value) |
| static int | pyrna_prop_collection_contains (BPy_PropertyRNA *self, PyObject *key) |
| static int | pyrna_struct_contains (BPy_StructRNA *self, PyObject *value) |
| static PyObject * | pyrna_struct_subscript (BPy_StructRNA *self, PyObject *key) |
| static int | pyrna_struct_ass_subscript (BPy_StructRNA *self, PyObject *key, PyObject *value) |
| PyDoc_STRVAR (pyrna_struct_keys_doc, ".. method:: keys()\n" "\n" " Returns the keys of this objects custom properties (matches Python's\n" " dictionary function of the same name).\n" "\n" " :return: custom property keys.\n" " :rtype: list of strings\n" "\n" BPY_DOC_ID_PROP_TYPE_NOTE) | |
| static PyObject * | pyrna_struct_keys (BPy_PropertyRNA *self) |
| PyDoc_STRVAR (pyrna_struct_items_doc, ".. method:: items()\n" "\n" " Returns the items of this objects custom properties (matches Python's\n" " dictionary function of the same name).\n" "\n" " :return: custom property key, value pairs.\n" " :rtype: list of key, value tuples\n" "\n" BPY_DOC_ID_PROP_TYPE_NOTE) | |
| static PyObject * | pyrna_struct_items (BPy_PropertyRNA *self) |
| PyDoc_STRVAR (pyrna_struct_values_doc, ".. method:: values()\n" "\n" " Returns the values of this objects custom properties (matches Python's\n" " dictionary function of the same name).\n" "\n" " :return: custom property values.\n" " :rtype: list\n" "\n" BPY_DOC_ID_PROP_TYPE_NOTE) | |
| static PyObject * | pyrna_struct_values (BPy_PropertyRNA *self) |
| PyDoc_STRVAR (pyrna_struct_is_property_set_doc, ".. method:: is_property_set(property, ghost=True)\n" "\n" " Check if a property is set, use for testing operator properties.\n" "\n" " :arg ghost: Used for operators that re-run with previous settings.\n" " In this case the property is not marked as set,\n" " yet the value from the previous execution is used.\n" "\n" " In rare cases you may want to set this option to false.\n" "\n" " :type ghost: boolean\n" " :return: True when the property has been set.\n" " :rtype: boolean\n") | |
| static PyObject * | pyrna_struct_is_property_set (BPy_StructRNA *self, PyObject *args, PyObject *kw) |
| PyDoc_STRVAR (pyrna_struct_property_unset_doc, ".. method:: property_unset(property)\n" "\n" " Unset a property, will use default value afterward.\n") | |
| static PyObject * | pyrna_struct_property_unset (BPy_StructRNA *self, PyObject *args) |
| PyDoc_STRVAR (pyrna_struct_is_property_hidden_doc, ".. method:: is_property_hidden(property)\n" "\n" " Check if a property is hidden.\n" "\n" " :return: True when the property is hidden.\n" " :rtype: boolean\n") | |
| static PyObject * | pyrna_struct_is_property_hidden (BPy_StructRNA *self, PyObject *args) |
| PyDoc_STRVAR (pyrna_struct_is_property_readonly_doc, ".. method:: is_property_readonly(property)\n" "\n" " Check if a property is readonly.\n" "\n" " :return: True when the property is readonly (not writable).\n" " :rtype: boolean\n") | |
| static PyObject * | pyrna_struct_is_property_readonly (BPy_StructRNA *self, PyObject *args) |
| PyDoc_STRVAR (pyrna_struct_is_property_overridable_library_doc, ".. method:: is_property_overridable_library(property)\n" "\n" " Check if a property is overridable.\n" "\n" " :return: True when the property is overridable.\n" " :rtype: boolean\n") | |
| static PyObject * | pyrna_struct_is_property_overridable_library (BPy_StructRNA *self, PyObject *args) |
| PyDoc_STRVAR (pyrna_struct_property_overridable_library_set_doc, ".. method:: property_overridable_library_set(property, overridable)\n" "\n" " Define a property as overridable or not (only for custom properties!).\n" "\n" " :return: True when the overridable status of the property was successfully set.\n" " :rtype: boolean\n") | |
| static PyObject * | pyrna_struct_property_overridable_library_set (BPy_StructRNA *self, PyObject *args) |
| PyDoc_STRVAR (pyrna_struct_path_resolve_doc, ".. method:: path_resolve(path, coerce=True)\n" "\n" " Returns the property from the path, raise an exception when not found.\n" "\n" " :arg path: path which this property resolves.\n" " :type path: string\n" " :arg coerce: optional argument, when True, the property will be converted\n" " into its Python representation.\n" " :type coerce: boolean\n") | |
| static PyObject * | pyrna_struct_path_resolve (BPy_StructRNA *self, PyObject *args) |
| PyDoc_STRVAR (pyrna_struct_path_from_id_doc, ".. method:: path_from_id(property=\"\")\n" "\n" " Returns the data path from the ID to this object (string).\n" "\n" " :arg property: Optional property name which can be used if the path is\n" " to a property of this object.\n" " :type property: string\n" " :return: The path from :class:`bpy.types.bpy_struct.id_data`\n" " to this struct and property (when given).\n" " :rtype: str\n") | |
| static PyObject * | pyrna_struct_path_from_id (BPy_StructRNA *self, PyObject *args) |
| PyDoc_STRVAR (pyrna_prop_path_from_id_doc, ".. method:: path_from_id()\n" "\n" " Returns the data path from the ID to this property (string).\n" "\n" " :return: The path from :class:`bpy.types.bpy_struct.id_data` to this property.\n" " :rtype: str\n") | |
| static PyObject * | pyrna_prop_path_from_id (BPy_PropertyRNA *self) |
| PyDoc_STRVAR (pyrna_prop_as_bytes_doc, ".. method:: as_bytes()\n" "\n" " Returns this string property as a byte rather than a Python string.\n" "\n" " :return: The string as bytes.\n" " :rtype: bytes\n") | |
| static PyObject * | pyrna_prop_as_bytes (BPy_PropertyRNA *self) |
| PyDoc_STRVAR (pyrna_prop_update_doc, ".. method:: update()\n" "\n" " Execute the properties update callback.\n" "\n" " .. note::\n" " This is called when assigning a property,\n" " however in rare cases it's useful to call explicitly.\n") | |
| static PyObject * | pyrna_prop_update (BPy_PropertyRNA *self) |
| PyDoc_STRVAR (pyrna_struct_type_recast_doc, ".. method:: type_recast()\n" "\n" " Return a new instance, this is needed because types\n" " such as textures can be changed at runtime.\n" "\n" " :return: a new instance of this object with the type initialized again.\n" " :rtype: subclass of :class:`bpy.types.bpy_struct`\n") | |
| static PyObject * | pyrna_struct_type_recast (BPy_StructRNA *self) |
| static PyObject * | pyrna_struct_bl_rna_find_subclass_recursive (PyObject *cls, const char *id) |
| PyDoc_STRVAR (pyrna_struct_bl_rna_get_subclass_py_doc, ".. classmethod:: bl_rna_get_subclass_py(id, default=None)\n" "\n" " :arg id: The RNA type identifier.\n" " :type id: string\n" " :return: The class or default when not found.\n" " :rtype: type\n") | |
| static PyObject * | pyrna_struct_bl_rna_get_subclass_py (PyObject *cls, PyObject *args) |
| PyDoc_STRVAR (pyrna_struct_bl_rna_get_subclass_doc, ".. classmethod:: bl_rna_get_subclass(id, default=None)\n" "\n" " :arg id: The RNA type identifier.\n" " :type id: string\n" " :return: The RNA type or default when not found.\n" " :rtype: :class:`bpy.types.Struct` subclass\n") | |
| static PyObject * | pyrna_struct_bl_rna_get_subclass (PyObject *cls, PyObject *args) |
| static void | pyrna_dir_members_py__add_keys (PyObject *list, PyObject *dict) |
| static void | pyrna_dir_members_py (PyObject *list, PyObject *self) |
| static void | pyrna_dir_members_rna (PyObject *list, PointerRNA *ptr) |
| static PyObject * | pyrna_struct_dir (BPy_StructRNA *self) |
| static PyObject * | pyrna_struct_getattro (BPy_StructRNA *self, PyObject *pyname) |
| static int | pyrna_struct_meta_idprop_setattro (PyObject *cls, PyObject *attr, PyObject *value) |
| static int | pyrna_struct_setattro (BPy_StructRNA *self, PyObject *pyname, PyObject *value) |
| static PyObject * | pyrna_prop_dir (BPy_PropertyRNA *self) |
| static PyObject * | pyrna_prop_array_getattro (BPy_PropertyRNA *self, PyObject *pyname) |
| static PyObject * | pyrna_prop_collection_getattro (BPy_PropertyRNA *self, PyObject *pyname) |
| static int | pyrna_prop_collection_setattro (BPy_PropertyRNA *self, PyObject *pyname, PyObject *value) |
| static PyObject * | pyrna_prop_collection_idprop_add (BPy_PropertyRNA *self) |
| static PyObject * | pyrna_prop_collection_idprop_remove (BPy_PropertyRNA *self, PyObject *value) |
| static PyObject * | pyrna_prop_collection_idprop_clear (BPy_PropertyRNA *self) |
| static PyObject * | pyrna_prop_collection_idprop_move (BPy_PropertyRNA *self, PyObject *args) |
| PyDoc_STRVAR (pyrna_struct_get_id_data_doc, "The :class:`bpy.types.ID` object this datablock is from or None, (not available for " "all data types)") | |
| static PyObject * | pyrna_struct_get_id_data (BPy_DummyPointerRNA *self) |
| PyDoc_STRVAR (pyrna_struct_get_data_doc, "The data this property is using, *type* :class:`bpy.types.bpy_struct`") | |
| static PyObject * | pyrna_struct_get_data (BPy_DummyPointerRNA *self) |
| PyDoc_STRVAR (pyrna_struct_get_rna_type_doc, "The property type for introspection") | |
| static PyObject * | pyrna_struct_get_rna_type (BPy_PropertyRNA *self) |
| static PyObject * | pyrna_func_doc_get (BPy_FunctionRNA *self, void *closure) |
| PyDoc_STRVAR (pyrna_prop_collection_keys_doc, ".. method:: keys()\n" "\n" " Return the identifiers of collection members\n" " (matching Python's dict.keys() functionality).\n" "\n" " :return: the identifiers for each member of this collection.\n" " :rtype: list of strings\n") | |
| static PyObject * | pyrna_prop_collection_keys (BPy_PropertyRNA *self) |
| PyDoc_STRVAR (pyrna_prop_collection_items_doc, ".. method:: items()\n" "\n" " Return the identifiers of collection members\n" " (matching Python's dict.items() functionality).\n" "\n" " :return: (key, value) pairs for each member of this collection.\n" " :rtype: list of tuples\n") | |
| static PyObject * | pyrna_prop_collection_items (BPy_PropertyRNA *self) |
| PyDoc_STRVAR (pyrna_prop_collection_values_doc, ".. method:: values()\n" "\n" " Return the values of collection\n" " (matching Python's dict.values() functionality).\n" "\n" " :return: the members of this collection.\n" " :rtype: list\n") | |
| PyDoc_STRVAR (pyrna_struct_get_doc, ".. method:: get(key, default=None)\n" "\n" " Returns the value of the custom property assigned to key or default\n" " when not found (matches Python's dictionary function of the same name).\n" "\n" " :arg key: The key associated with the custom property.\n" " :type key: string\n" " :arg default: Optional argument for the value to return if\n" " *key* is not found.\n" " :type default: Undefined\n" "\n" BPY_DOC_ID_PROP_TYPE_NOTE) | |
| static PyObject * | pyrna_struct_get (BPy_StructRNA *self, PyObject *args) |
| PyDoc_STRVAR (pyrna_struct_pop_doc, ".. method:: pop(key, default=None)\n" "\n" " Remove and return the value of the custom property assigned to key or default\n" " when not found (matches Python's dictionary function of the same name).\n" "\n" " :arg key: The key associated with the custom property.\n" " :type key: string\n" " :arg default: Optional argument for the value to return if\n" " *key* is not found.\n" " :type default: Undefined\n" "\n" BPY_DOC_ID_PROP_TYPE_NOTE) | |
| static PyObject * | pyrna_struct_pop (BPy_StructRNA *self, PyObject *args) |
| PyDoc_STRVAR (pyrna_struct_as_pointer_doc, ".. method:: as_pointer()\n" "\n" " Returns the memory address which holds a pointer to Blender's internal data\n" "\n" " :return: int (memory address).\n" " :rtype: int\n" "\n" " .. note:: This is intended only for advanced script writers who need to\n" " pass blender data to their own C/Python modules.\n") | |
| static PyObject * | pyrna_struct_as_pointer (BPy_StructRNA *self) |
| PyDoc_STRVAR (pyrna_prop_collection_get_doc, ".. method:: get(key, default=None)\n" "\n" " Returns the value of the item assigned to key or default when not found\n" " (matches Python's dictionary function of the same name).\n" "\n" " :arg key: The identifier for the collection member.\n" " :type key: string\n" " :arg default: Optional argument for the value to return if\n" " *key* is not found.\n" " :type default: Undefined\n") | |
| static PyObject * | pyrna_prop_collection_get (BPy_PropertyRNA *self, PyObject *args) |
| PyDoc_STRVAR (pyrna_prop_collection_find_doc, ".. method:: find(key)\n" "\n" " Returns the index of a key in a collection or -1 when not found\n" " (matches Python's string find function of the same name).\n" "\n" " :arg key: The identifier for the collection member.\n" " :type key: string\n" " :return: index of the key.\n" " :rtype: int\n") | |
| static PyObject * | pyrna_prop_collection_find (BPy_PropertyRNA *self, PyObject *key_ob) |
| static bool | foreach_attr_type (BPy_PropertyRNA *self, const char *attr, RawPropertyType *r_raw_type, int *r_attr_tot, bool *r_attr_signed) |
| static int | foreach_parse_args (BPy_PropertyRNA *self, PyObject *args, const char **r_attr, PyObject **r_seq, int *r_tot, int *r_size, RawPropertyType *r_raw_type, int *r_attr_tot, bool *r_attr_signed) |
| static bool | foreach_compat_buffer (RawPropertyType raw_type, int attr_signed, const char *format) |
| static PyObject * | foreach_getset (BPy_PropertyRNA *self, PyObject *args, int set) |
| PyDoc_STRVAR (pyrna_prop_collection_foreach_get_doc, ".. method:: foreach_get(attr, seq)\n" "\n" " This is a function to give fast access to attributes within a collection.\n") | |
| static PyObject * | pyrna_prop_collection_foreach_get (BPy_PropertyRNA *self, PyObject *args) |
| PyDoc_STRVAR (pyrna_prop_collection_foreach_set_doc, ".. method:: foreach_set(attr, seq)\n" "\n" " This is a function to give fast access to attributes within a collection.\n") | |
| static PyObject * | pyrna_prop_collection_foreach_set (BPy_PropertyRNA *self, PyObject *args) |
| static PyObject * | pyprop_array_foreach_getset (BPy_PropertyArrayRNA *self, PyObject *args, const bool do_set) |
| PyDoc_STRVAR (pyrna_prop_array_foreach_get_doc, ".. method:: foreach_get(seq)\n" "\n" " This is a function to give fast access to array data.\n") | |
| static PyObject * | pyrna_prop_array_foreach_get (BPy_PropertyArrayRNA *self, PyObject *args) |
| PyDoc_STRVAR (pyrna_prop_array_foreach_set_doc, ".. method:: foreach_set(seq)\n" "\n" " This is a function to give fast access to array data.\n") | |
| static PyObject * | pyrna_prop_array_foreach_set (BPy_PropertyArrayRNA *self, PyObject *args) |
| static PyObject * | pyrna_prop_array_iter (BPy_PropertyArrayRNA *self) |
| static PyObject * | pyrna_prop_collection_iter (BPy_PropertyRNA *self) |
| static PyObject * | pyrna_struct_new (PyTypeObject *type, PyObject *args, PyObject *UNUSED(kwds)) |
| static PyObject * | pyrna_prop_new (PyTypeObject *type, PyObject *args, PyObject *UNUSED(kwds)) |
| static PyObject * | pyrna_param_to_py (PointerRNA *ptr, PropertyRNA *prop, void *data) |
| static PyObject * | small_dict_get_item_string (PyObject *dict, const char *key_lookup) |
| static PyObject * | pyrna_func_call (BPy_FunctionRNA *self, PyObject *args, PyObject *kw) |
| static PyObject * | pyrna_func_doc_get (BPy_FunctionRNA *self, void *UNUSED(closure)) |
| static void | pyrna_prop_collection_iter_dealloc (BPy_PropertyCollectionIterRNA *self) |
| static PyObject * | pyrna_prop_collection_iter_next (BPy_PropertyCollectionIterRNA *self) |
| static PyObject * | pyrna_prop_collection_iter_CreatePyObject (PointerRNA *ptr, PropertyRNA *prop) |
| static void | pyrna_subtype_set_rna (PyObject *newclass, StructRNA *srna) |
| static PyObject * | pyrna_srna_Subtype (StructRNA *srna) |
| static PyObject * | pyrna_srna_PyBase (StructRNA *srna) |
| static PyObject * | pyrna_srna_ExternalType (StructRNA *srna) |
| static StructRNA * | srna_from_ptr (PointerRNA *ptr) |
| PyObject * | pyrna_struct_CreatePyObject (PointerRNA *ptr) |
| PyObject * | pyrna_prop_CreatePyObject (PointerRNA *ptr, PropertyRNA *prop) |
| PyObject * | pyrna_id_CreatePyObject (ID *id) |
| bool | pyrna_id_FromPyObject (PyObject *obj, ID **id) |
| bool | pyrna_id_CheckPyObject (PyObject *obj) |
| void | BPY_rna_init (void) |
| PyObject * | BPY_rna_module (void) |
| void | BPY_update_rna_module (void) |
| StructRNA * | pyrna_struct_as_srna (PyObject *self, const bool parent, const char *error_prefix) |
| StructRNA * | srna_from_self (PyObject *self, const char *error_prefix) |
| static int | pyrna_deferred_register_class_from_type_hints (StructRNA *srna, PyTypeObject *py_class) |
| static int | pyrna_deferred_register_props (StructRNA *srna, PyObject *class_dict) |
| static int | pyrna_deferred_register_class_recursive (StructRNA *srna, PyTypeObject *py_class) |
| int | pyrna_deferred_register_class (StructRNA *srna, PyTypeObject *py_class) |
| static int | rna_function_arg_count (FunctionRNA *func, int *min_count) |
| static int | bpy_class_validate_recursive (PointerRNA *dummyptr, StructRNA *srna, void *py_data, int *have_function) |
| static int | bpy_class_validate (PointerRNA *dummyptr, void *py_data, int *have_function) |
| static int | bpy_class_call (bContext *C, PointerRNA *ptr, FunctionRNA *func, ParameterList *parms) |
| static void | bpy_class_free (void *pyob_ptr) |
| void | pyrna_alloc_types (void) |
| void | pyrna_free_types (void) |
| PyDoc_STRVAR (pyrna_register_class_doc, ".. method:: register_class(cls)\n" "\n" " Register a subclass of a Blender type class.\n" "\n" " :arg cls: Blender type class in:\n" " :class:`bpy.types.Panel`, :class:`bpy.types.UIList`,\n" " :class:`bpy.types.Menu`, :class:`bpy.types.Header`,\n" " :class:`bpy.types.Operator`, :class:`bpy.types.KeyingSetInfo`,\n" " :class:`bpy.types.RenderEngine`\n" " :type cls: class\n" " :raises ValueError:\n" " if the class is not a subclass of a registerable blender class.\n" "\n" " .. note::\n" "\n" " If the class has a *register* class method it will be called\n" " before registration.\n") | |
| static PyObject * | pyrna_register_class (PyObject *UNUSED(self), PyObject *py_class) |
| static int | pyrna_srna_contains_pointer_prop_srna (StructRNA *srna_props, StructRNA *srna, const char **r_prop_identifier) |
| PyDoc_STRVAR (pyrna_unregister_class_doc, ".. method:: unregister_class(cls)\n" "\n" " Unload the Python class from blender.\n" "\n" " If the class has an *unregister* class method it will be called\n" " before unregistering.\n") | |
| static PyObject * | pyrna_unregister_class (PyObject *UNUSED(self), PyObject *py_class) |
| void | pyrna_struct_type_extend_capi (struct StructRNA *srna, struct PyMethodDef *method, struct PyGetSetDef *getset) |
| static PyObject * | pyrna_bl_owner_id_get (PyObject *UNUSED(self)) |
| static PyObject * | pyrna_bl_owner_id_set (PyObject *UNUSED(self), PyObject *value) |
RNA Types Module <tt>bpy.types</tt> | |
| static struct PyMethodDef | bpy_types_module_methods [] |
| static struct PyModuleDef | bpy_types_module_def |
| static PyObject * | bpy_types_module_getattro (PyObject *self, PyObject *pyname) |
| static PyObject * | bpy_types_module_dir (PyObject *self) |
| PyDoc_STRVAR (bpy_types_module_doc, "Access to internal Blender types") | |
| PyObject * | BPY_rna_types (void) |
This file is the main interface between Python and Blender's data api (RNA), exposing RNA to Python so blender data can be accessed in a Python like way.
The two main types are BPy_StructRNA and BPy_PropertyRNA - the base classes for most of the data Python accesses in blender.
Definition in file bpy_rna.c.
| #define BPY_DOC_ID_PROP_TYPE_NOTE |
| #define BPY_REPLACEMENT_STRING | ( | rna_attr, | |
| py_attr | |||
| ) |
| #define PROP_ALL_VECTOR_SUBTYPES |
Note that PROP_NONE is included as a vector subtype. this is because it is handy to have x/y access to fcurve keyframes and other fixed size float arrays of length 2-4.
| #define PYRNA_PROP_COLLECTION_ABS_INDEX | ( | ret_err | ) |
| #define USE_POSTPONED_ANNOTATIONS |
This must be enabled to support Python 3.10's postponed annotations, from __future__ import annotations.
This has the disadvantage of evaluating strings at run-time, in the future we might be able to reinstate the older, more efficient logic using descriptors, see: pep-0649
|
static |
Definition at line 8385 of file bpy_rna.c.
References bpy_context_clear(), BPY_context_get(), bpy_context_set(), BPy_errors_to_report(), BPY_LOG_RNA, C, CLOG_WARN, CTX_wm_manager(), CTX_wm_reports(), PointerRNA::data, ParameterIterator::data, err, FUNC_ALLOW_WRITE, FUNC_NO_SELF, FUNC_USE_SELF_TYPE, NULL, ParameterIterator::parm, PARM_OUTPUT, ptr, PyC_Err_Format_Prefix(), pyrna_param_to_py(), pyrna_py_to_prop(), pyrna_struct_CreatePyObject(), wmOperator::reports, ret, rna_disallow_writes, RNA_Function, rna_function_arg_count(), RNA_function_flag(), RNA_function_identifier(), RNA_Gizmo, RNA_Operator, RNA_parameter_flag(), RNA_parameter_list_begin(), RNA_parameter_list_end(), RNA_parameter_list_next(), RNA_pointer_create(), RNA_struct_identifier(), RNA_struct_instance(), RNA_struct_is_a(), RNA_struct_py_type_get(), PointerRNA::type, and ParameterIterator::valid.
Referenced by pyrna_register_class().
|
static |
Definition at line 8710 of file bpy_rna.c.
References bpy_intern_str_bl_rna, G, G_DEBUG_PYTHON, PyC_ObSpit(), and self.
Referenced by pyrna_free_types(), and pyrna_register_class().
|
static |
Definition at line 8379 of file bpy_rna.c.
References bpy_class_validate_recursive(), and PointerRNA::type.
Referenced by pyrna_register_class().
|
static |
Definition at line 8174 of file bpy_rna.c.
References bpy_intern_str___doc__, bpy_intern_str___name__, BPY_REPLACEMENT_STRING, ListBase::first, FUNC_NO_SELF, FUNC_REGISTER, FUNC_REGISTER_OPTIONAL, FUNC_USE_SELF_TYPE, Link::next, NULL, BPy_TypesModule_State::prop, PROP_REGISTER, PROP_REGISTER_OPTIONAL, pyrna_py_to_prop(), rna_function_arg_count(), RNA_function_flag(), RNA_function_identifier(), RNA_property_flag(), RNA_property_identifier(), RNA_struct_base(), RNA_struct_identifier(), RNA_struct_py_type_get(), RNA_struct_type_functions(), and RNA_struct_type_properties().
Referenced by bpy_class_validate().
| void BPY_id_release | ( | struct ID * | id | ) |
Definition at line 306 of file bpy_rna.c.
Referenced by BKE_libblock_free_data_py().
| void BPY_rna_init | ( | void | ) |
Definition at line 7638 of file bpy_rna.c.
References Mathutils_RegisterCallback(), mathutils_rna_array_cb, mathutils_rna_array_cb_index, mathutils_rna_matrix_cb, mathutils_rna_matrix_cb_index, pyrna_func_Type, pyrna_prop_array_Type, pyrna_prop_collection_idprop_Type, pyrna_prop_collection_iter_Type, pyrna_prop_collection_Type, pyrna_prop_Type, pyrna_struct_meta_idprop_Type, and pyrna_struct_Type.
Referenced by BPy_init_modules().
| PyObject* BPY_rna_module | ( | void | ) |
Definition at line 7688 of file bpy_rna.c.
References G_MAIN, BPy_StructRNA::ptr, ptr, pyrna_struct_CreatePyObject(), RNA_main_pointer_create(), and rna_module_ptr.
Referenced by BPy_init_modules(), and BPY_modules_update().
| PyObject* BPY_rna_types | ( | void | ) |
Accessed from Python as 'bpy.types'
Definition at line 7819 of file bpy_rna.c.
References ARRAY_SIZE, bpy_types_module_def, pyrna_func_Type, pyrna_prop_array_Type, pyrna_prop_collection_Type, pyrna_prop_Type, pyrna_struct_meta_idprop_Type, pyrna_struct_Type, RNA_blender_rna_pointer_create(), RNA_struct_find_property(), and state.
Referenced by BPy_init_modules(), and BPY_modules_update().
|
static |
Definition at line 7776 of file bpy_rna.c.
References pos, ret, RNA_PROP_BEGIN, RNA_PROP_END, RNA_struct_identifier(), and state.
|
static |
Definition at line 7743 of file bpy_rna.c.
References NULL, pyrna_struct_Subtype(), ret, RNA_property_collection_lookup_string(), and state.
| void BPY_update_rna_module | ( | void | ) |
Definition at line 7701 of file bpy_rna.c.
References PointerRNA::data, G_MAIN, RNA_main_pointer_create(), and rna_module_ptr.
Referenced by BPY_driver_exec(), and BPY_modules_update().
|
static |
Definition at line 7937 of file bpy_rna.c.
References BPy_CollectionProperty(), bpy_intern_str_attr, BPy_PointerProperty(), BPy_PropDeferred_CheckTypeExact, NULL, RNA_struct_identifier(), RNA_struct_idprops_contains_datablock(), RNA_struct_idprops_datablock_allowed(), srna_from_self(), and type.
Referenced by pyrna_deferred_register_class_from_type_hints(), pyrna_deferred_register_props(), and pyrna_struct_meta_idprop_setattro().
|
static |
Definition at line 5137 of file bpy_rna.c.
References PROP_RAW_UNSET, PROP_UNSIGNED, RNA_PROP_BEGIN, RNA_PROP_END, RNA_property_array_length(), RNA_property_raw_type(), RNA_property_subtype(), RNA_struct_find_property(), and self.
Referenced by foreach_parse_args().
|
static |
Definition at line 5252 of file bpy_rna.c.
References PROP_RAW_BOOLEAN, PROP_RAW_CHAR, PROP_RAW_DOUBLE, PROP_RAW_FLOAT, PROP_RAW_INT, PROP_RAW_SHORT, and PROP_RAW_UNSET.
Referenced by foreach_getset().
|
static |
Definition at line 5291 of file bpy_rna.c.
References BLI_assert, double(), float(), foreach_compat_buffer(), foreach_parse_args(), NULL, PROP_RAW_BOOLEAN, PROP_RAW_CHAR, PROP_RAW_DOUBLE, PROP_RAW_FLOAT, PROP_RAW_INT, PROP_RAW_SHORT, PROP_RAW_UNSET, RNA_property_collection_raw_get(), RNA_property_collection_raw_set(), self, and size().
Referenced by pyrna_prop_collection_foreach_get(), and pyrna_prop_collection_foreach_set().
|
static |
Definition at line 5169 of file bpy_rna.c.
References foreach_attr_type(), PROP_COLLECTION, PROP_RAW_UNSET, RNA_property_array_length(), RNA_property_collection_length(), RNA_property_identifier(), RNA_property_type(), RNA_raw_type_sizeof(), RNA_struct_identifier(), and self.
Referenced by foreach_getset().
|
static |
Definition at line 410 of file bpy_rna.c.
References PYRNA_PROP_CHECK_INT.
|
static |
Definition at line 554 of file bpy_rna.c.
References NULL, PYRNA_PROP_CHECK_INT, RNA_property_float_get_array(), and self.
|
static |
Definition at line 568 of file bpy_rna.c.
References BPY_context_get(), NULL, PYRNA_PROP_CHECK_INT, rna_disallow_writes, rna_id_write_error(), RNA_property_editable_flag(), RNA_property_float_set_array(), RNA_property_identifier(), RNA_property_update(), RNA_property_update_check(), RNA_struct_identifier(), and self.
|
static |
Definition at line 419 of file bpy_rna.c.
References MATHUTILS_CB_SUBTYPE_EUL, NULL, EulerObject::order, PYRNA_PROP_CHECK_INT, pyrna_rotation_euler_order_get(), RNA_property_float_get_array(), and self.
|
static |
Definition at line 495 of file bpy_rna.c.
References NULL, PYRNA_PROP_CHECK_INT, RNA_property_float_get_index(), and self.
|
static |
Definition at line 441 of file bpy_rna.c.
References BPY_context_get(), CLAMP, len, MATHUTILS_CB_SUBTYPE_EUL, max, min, NULL, order, EulerObject::order, PYRNA_PROP_CHECK_INT, pyrna_rotation_euler_order_get(), rna_disallow_writes, rna_id_write_error(), RNA_property_array_length(), RNA_property_editable_flag(), RNA_property_enum_set(), RNA_property_float_range(), RNA_property_float_set_array(), RNA_property_identifier(), RNA_property_update(), RNA_property_update_check(), RNA_struct_identifier(), and self.
|
static |
Definition at line 509 of file bpy_rna.c.
References BPY_context_get(), NULL, PYRNA_PROP_CHECK_INT, rna_disallow_writes, rna_id_write_error(), RNA_property_editable_flag(), RNA_property_float_clamp(), RNA_property_float_set_index(), RNA_property_identifier(), RNA_property_update(), RNA_property_update_check(), RNA_struct_identifier(), and self.
|
static |
Definition at line 3264 of file bpy_rna.c.
References len, pyrna_prop_array_length(), PYRNA_PROP_CHECK_INT, and pyrna_py_to_prop_array_index().
Referenced by pyrna_prop_array_ass_subscript().
|
static |
Definition at line 3119 of file bpy_rna.c.
References BLI_assert, length(), NULL, PROP_BOOLEAN, PROP_FLOAT, PROP_INT, prop_subscript_ass_array_slice__bool_recursive(), prop_subscript_ass_array_slice__float_recursive(), prop_subscript_ass_array_slice__int_recursive(), ptr, PYRNA_STACK_ARRAY, ret, RNA_property_array_dimension(), RNA_property_array_length(), RNA_property_boolean_get_array(), RNA_property_boolean_set_array(), RNA_property_float_get_array(), RNA_property_float_range(), RNA_property_float_set_array(), RNA_property_int_get_array(), RNA_property_int_range(), RNA_property_int_set_array(), and RNA_property_type().
Referenced by pyrna_prop_array_ass_subscript().
|
static |
Helpers for prop_subscript_ass_array_slice
Definition at line 3002 of file bpy_rna.c.
References length(), and NULL.
Referenced by prop_subscript_ass_array_slice__bool_recursive(), prop_subscript_ass_array_slice__float_recursive(), and prop_subscript_ass_array_slice__int_recursive().
|
static |
Definition at line 3086 of file bpy_rna.c.
References BLI_assert, length(), NULL, prop_subscript_ass_array_slice__as_seq_fast(), UNLIKELY, and v.
Referenced by prop_subscript_ass_array_slice().
|
static |
Definition at line 3022 of file bpy_rna.c.
References BLI_assert, CLAMP, length(), max, min, NULL, prop_subscript_ass_array_slice__as_seq_fast(), UNLIKELY, and v.
Referenced by prop_subscript_ass_array_slice().
|
static |
Definition at line 3054 of file bpy_rna.c.
References BLI_assert, CLAMP, length(), max, min, NULL, prop_subscript_ass_array_slice__as_seq_fast(), UNLIKELY, and v.
Referenced by prop_subscript_ass_array_slice().
| PyDoc_STRVAR | ( | bpy_types_module_doc | , |
| "Access to internal Blender types" | |||
| ) |
| PyDoc_STRVAR | ( | pyrna_prop_array_foreach_get_doc | , |
| ".. method:: foreach_get(seq)\n" "\n" " This is a function to give fast access to array data.\n" | |||
| ) |
| PyDoc_STRVAR | ( | pyrna_prop_array_foreach_set_doc | , |
| ".. method:: foreach_set(seq)\n" "\n" " This is a function to give fast access to array data.\n" | |||
| ) |
| PyDoc_STRVAR | ( | pyrna_prop_as_bytes_doc | , |
| ".. method:: as_bytes()\n" "\n" " Returns this string property as a byte rather than a Python string.\n" "\n" " :return: The string as bytes.\n" " :rtype: bytes\n" | |||
| ) |
| PyDoc_STRVAR | ( | pyrna_prop_collection_find_doc | , |
| ".. method:: find(key)\n" "\n" " Returns the index of a key in a collection or -1 when not found\n" " (matches Python's string find function of the same name).\n" "\n" " :arg key: The identifier for the collection member.\n" " :type key: string\n" " :return: index of the key.\n" " :rtype: int\n" | |||
| ) |
| PyDoc_STRVAR | ( | pyrna_prop_collection_foreach_get_doc | , |
| ".. method:: foreach_get(attr, seq)\n" "\n" " This is a function to give fast access to attributes within a collection.\n" | |||
| ) |
| PyDoc_STRVAR | ( | pyrna_prop_collection_foreach_set_doc | , |
| ".. method:: foreach_set(attr, seq)\n" "\n" " This is a function to give fast access to attributes within a collection.\n" | |||
| ) |
| PyDoc_STRVAR | ( | pyrna_prop_collection_get_doc | , |
| ".. method:: get(key, default=None)\n" "\n" " Returns the value of the item assigned to key or default when not found\n" " (matches Python's dictionary function of the same name).\n" "\n" " :arg key: The identifier for the collection member.\n" " :type key: string\n" " :arg default: Optional argument for the value to return if\n" " *key* is not found.\n" " :type default: Undefined\n" | |||
| ) |
| PyDoc_STRVAR | ( | pyrna_prop_collection_items_doc | , |
| ".. method:: items()\n" "\n" " Return the identifiers of collection members\n" " (matching Python's dict.items() functionality).\n" "\n" " :return: (key, value) pairs for each member of this collection.\n" " :rtype: list of tuples\n" | |||
| ) |
| PyDoc_STRVAR | ( | pyrna_prop_collection_keys_doc | , |
| ".. method:: keys()\n" "\n" " Return the identifiers of collection members\n" " (matching Python's dict.keys() functionality).\n" "\n" " :return: the identifiers for each member of this collection.\n" " :rtype: list of strings\n" | |||
| ) |
| PyDoc_STRVAR | ( | pyrna_prop_collection_values_doc | , |
| ".. method:: values()\n" "\n" " Return the values of collection\n" " (matching Python's dict.values() functionality).\n" "\n" " :return: the members of this collection.\n" " :rtype: list\n" | |||
| ) |
| PyDoc_STRVAR | ( | pyrna_prop_path_from_id_doc | , |
| ".. method:: path_from_id()\n" "\n" " Returns the data path from the ID to this property (string).\n" "\n" " :return: The path from :class:`bpy.types.bpy_struct.id_data` to this property.\n" " :rtype: str\n" | |||
| ) |
| PyDoc_STRVAR | ( | pyrna_prop_update_doc | , |
| ".. method:: update()\n" "\n" " Execute the properties update callback.\n" "\n" " .. note::\n" " This is called when assigning a | property, | ||
| \n" " however in rare cases it 's useful to call explicitly.\n" | |||
| ) |
| PyDoc_STRVAR | ( | pyrna_register_class_doc | , |
| ".. method:: register_class(cls)\n" "\n" " Register a subclass of a Blender type class.\n" "\n" " :arg cls: Blender type class in:\n" " :class:`bpy.types.Panel` | , | ||
| :class:`bpy.types.UIList` | , | ||
| \n" " :class:`bpy.types.Menu` | , | ||
| :class:`bpy.types.Header` | , | ||
| \n" " :class:`bpy.types.Operator` | , | ||
| :class:`bpy.types.KeyingSetInfo` | , | ||
| \n" " :class:`bpy.types.RenderEngine`\n" " :type cls:class\n" " :raises ValueError:\n" " if the class is not a subclass of a registerable blender class.\n" "\n" " .. note::\n" "\n" " If the class has a *register *class method it will be called\n" " before registration.\n" | |||
| ) |
There is currently a bug where moving the registration of a Python class does not properly manage reference-counts from the Python class. As the srna owns the Python class this should not be so tricky, but changing the references as you'd expect when changing ownership crashes blender on exit so I had to comment out the #Py_DECREF. This is not so bad because the leak only happens when re-registering (continuously running SCRIPT_OT_reload).
| PyDoc_STRVAR | ( | pyrna_struct_as_pointer_doc | , |
| ".. method:: as_pointer()\n" "\n" " Returns the memory address which holds a pointer to Blender's internal data\n" "\n" " :return: int (memory address).\n" " :rtype: int\n" "\n" " .. note:: This is intended only for advanced script writers who need to\n" " pass blender data to their own C/Python modules.\n" | |||
| ) |
| PyDoc_STRVAR | ( | pyrna_struct_bl_rna_get_subclass_doc | , |
| ".. classmethod:: bl_rna_get_subclass(id, default=None)\n" "\n" " :arg id: The RNA type identifier.\n" " :type id: string\n" " :return: The RNA type or default when not found.\n" " :rtype: :class:`bpy.types.Struct` subclass\n" | |||
| ) |
| PyDoc_STRVAR | ( | pyrna_struct_bl_rna_get_subclass_py_doc | , |
| ".. classmethod:: bl_rna_get_subclass_py(id, default=None)\n" "\n" " :arg id: The RNA type identifier.\n" " :type id: string\n" " :return: The class or default when not found.\n" " :rtype: type\n" | |||
| ) |
| PyDoc_STRVAR | ( | pyrna_struct_get_data_doc | , |
| "The data this property is | using, | ||
| *type *:class:`bpy.types.bpy_struct`" | |||
| ) |
| PyDoc_STRVAR | ( | pyrna_struct_get_doc | , |
| ".. method:: get(key, default=None)\n" "\n" " Returns the value of the custom property assigned to key or default\n" " when not found (matches Python's dictionary function of the same name).\n" "\n" " :arg key: The key associated with the custom property.\n" " :type key: string\n" " :arg default: Optional argument for the value to return if\n" " *key* is not found.\n" " :type default: Undefined\n" "\n" | BPY_DOC_ID_PROP_TYPE_NOTE | ||
| ) |
| PyDoc_STRVAR | ( | pyrna_struct_get_id_data_doc | , |
| "The :class:`bpy.types.ID` object this datablock is from or | None, | ||
| (not available for " "all data types)" | |||
| ) |
| PyDoc_STRVAR | ( | pyrna_struct_get_rna_type_doc | , |
| "The property type for introspection" | |||
| ) |
| PyDoc_STRVAR | ( | pyrna_struct_is_property_hidden_doc | , |
| ".. method:: is_property_hidden(property)\n" "\n" " Check if a property is hidden.\n" "\n" " :return: True when the property is hidden.\n" " :rtype: boolean\n" | |||
| ) |
| PyDoc_STRVAR | ( | pyrna_struct_is_property_overridable_library_doc | , |
| ".. method:: is_property_overridable_library(property)\n" "\n" " Check if a property is overridable.\n" "\n" " :return: True when the property is overridable.\n" " :rtype: boolean\n" | |||
| ) |
| PyDoc_STRVAR | ( | pyrna_struct_is_property_readonly_doc | , |
| ".. method:: is_property_readonly(property)\n" "\n" " Check if a property is readonly.\n" "\n" " :return: True when the property is readonly (not writable).\n" " :rtype: boolean\n" | |||
| ) |
| PyDoc_STRVAR | ( | pyrna_struct_is_property_set_doc | , |
| ".. method:: is_property_set(property, ghost=True)\n" "\n" " Check if a property is | set, | ||
| use for testing operator properties.\n" "\n" " :arg ghost:Used for operators that re-run with previous settings.\n" " In this case the property is not marked as | set, | ||
| \n" " yet the value from the previous execution is used.\n" "\n" " In rare cases you may want to set this option to false.\n" "\n" " :type ghost:boolean\n" " :return:True when the property has been set.\n" " :rtype:boolean\n" | |||
| ) |
| PyDoc_STRVAR | ( | pyrna_struct_items_doc | , |
| ".. method:: items()\n" "\n" " Returns the items of this objects custom properties (matches Python's\n" " dictionary function of the same name).\n" "\n" " :return: custom property | key, | ||
| value pairs.\n" " :rtype:list of | key, | ||
| value tuples\n" "\n" | BPY_DOC_ID_PROP_TYPE_NOTE | ||
| ) |
| PyDoc_STRVAR | ( | pyrna_struct_keys_doc | , |
| ".. method:: keys()\n" "\n" " Returns the keys of this objects custom properties (matches Python's\n" " dictionary function of the same name).\n" "\n" " :return: custom property keys.\n" " :rtype: list of strings\n" "\n" | BPY_DOC_ID_PROP_TYPE_NOTE | ||
| ) |
| PyDoc_STRVAR | ( | pyrna_struct_path_from_id_doc | , |
| ".. method:: path_from_id(property=\"\")\n" "\n" " Returns the data path from the ID to this object (string).\n" "\n" " :arg property: Optional property name which can be used if the path is\n" " to a property of this object.\n" " :type property: string\n" " :return: The path from :class:`bpy.types.bpy_struct.id_data`\n" " to this struct and property (when given).\n" " :rtype: str\n" | |||
| ) |
| PyDoc_STRVAR | ( | pyrna_struct_path_resolve_doc | , |
| ".. method:: path_resolve(path, coerce=True)\n" "\n" " Returns the property from the | path, | ||
| raise an exception when not found.\n" "\n" " :arg path:path which this property resolves.\n" " :type path:string\n" " :arg coerce:optional | argument, | ||
| when | True, | ||
| the property will be converted\n" " into its Python representation.\n" " :type coerce:boolean\n" | |||
| ) |
| PyDoc_STRVAR | ( | pyrna_struct_pop_doc | , |
| ".. method:: pop(key, default=None)\n" "\n" " Remove and return the value of the custom property assigned to key or default\n" " when not found (matches Python's dictionary function of the same name).\n" "\n" " :arg key: The key associated with the custom property.\n" " :type key: string\n" " :arg default: Optional argument for the value to return if\n" " *key* is not found.\n" " :type default: Undefined\n" "\n" | BPY_DOC_ID_PROP_TYPE_NOTE | ||
| ) |
| PyDoc_STRVAR | ( | pyrna_struct_property_overridable_library_set_doc | , |
| ".. method:: property_overridable_library_set(property, overridable)\n" "\n" " Define a property as overridable or not (only for custom properties!).\n" "\n" " :return: True when the overridable status of the property was successfully set.\n" " :rtype: boolean\n" | |||
| ) |
| PyDoc_STRVAR | ( | pyrna_struct_property_unset_doc | , |
| ".. method:: property_unset(property)\n" "\n" " Unset a | property, | ||
| will use default value afterward.\n" | |||
| ) |
| PyDoc_STRVAR | ( | pyrna_struct_type_recast_doc | , |
| ".. method:: type_recast()\n" "\n" " Return a new | instance, | ||
| this is needed because types\n" " such as textures can be changed at runtime.\n" "\n" " :return:a new instance of this object with the type initialized again.\n" " :rtype:subclass of :class:`bpy.types.bpy_struct`\n" | |||
| ) |
| PyDoc_STRVAR | ( | pyrna_struct_values_doc | , |
| ".. method:: values()\n" "\n" " Returns the values of this objects custom properties (matches Python's\n" " dictionary function of the same name).\n" "\n" " :return: custom property values.\n" " :rtype: list\n" "\n" | BPY_DOC_ID_PROP_TYPE_NOTE | ||
| ) |
| PyDoc_STRVAR | ( | pyrna_unregister_class_doc | , |
| ".. method:: unregister_class(cls)\n" "\n" " Unload the Python class from blender.\n" "\n" " If the class has an *unregister* class method it will be called\n" " before unregistering.\n" | |||
| ) |
|
static |
Definition at line 5475 of file bpy_rna.c.
References BLI_assert_unreachable, ELEM, float(), NULL, PROP_BOOLEAN, PROP_COLLECTION, PROP_ENUM, PROP_FLOAT, PROP_INT, PROP_POINTER, PROP_STRING, pyrna_prop_array_length(), RNA_property_float_get_array(), RNA_property_float_set_array(), RNA_property_int_get_array(), RNA_property_int_set_array(), RNA_property_type(), self, and size().
Referenced by pyrna_prop_array_foreach_get(), and pyrna_prop_array_foreach_set().
| void pyrna_alloc_types | ( | void | ) |
Definition at line 8743 of file bpy_rna.c.
References NULL, BPy_TypesModule_State::prop, ptr, pyrna_struct_Subtype(), RNA_blender_rna_pointer_create(), RNA_PROP_BEGIN, RNA_PROP_END, and RNA_struct_find_property().
Referenced by BPY_python_start().
|
static |
Definition at line 9165 of file bpy_rna.c.
References RNA_struct_state_owner_get().
|
static |
Definition at line 9174 of file bpy_rna.c.
References NULL, and RNA_struct_state_owner_set().
| int pyrna_deferred_register_class | ( | StructRNA * | srna, |
| PyTypeObject * | py_class | ||
| ) |
Definition at line 8122 of file bpy_rna.c.
References pyrna_deferred_register_class_from_type_hints(), pyrna_deferred_register_class_recursive(), and RNA_struct_idprops_register_check().
Referenced by gizmo_properties_init(), gizmogroup_properties_init(), operator_properties_init(), and pyrna_register_class().
|
static |
Extract __annotations__ using typing.get_type_hints which handles the delayed evaluation.
Definition at line 8010 of file bpy_rna.c.
References BLI_assert, deferred_register_prop(), NULL, pos, and ret.
Referenced by pyrna_deferred_register_class().
|
static |
Definition at line 8089 of file bpy_rna.c.
References len, pyrna_deferred_register_props(), pyrna_struct_Type, and ret.
Referenced by pyrna_deferred_register_class().
|
static |
Definition at line 8066 of file bpy_rna.c.
References bpy_intern_str___annotations__, deferred_register_prop(), pos, and ret.
Referenced by pyrna_deferred_register_class_recursive().
|
static |
Definition at line 4150 of file bpy_rna.c.
References BPy_PropertyRNA_Check, BPy_PropertyRNA::prop, PROP_COLLECTION, BPy_PropertyRNA::ptr, pyrna_dir_members_py__add_keys(), pyrna_struct_Subtype(), RNA_property_collection_type_get(), and RNA_property_type().
Referenced by pyrna_prop_dir(), and pyrna_struct_dir().
|
static |
Definition at line 4141 of file bpy_rna.c.
Referenced by pyrna_dir_members_py().
|
static |
Definition at line 4182 of file bpy_rna.c.
References MEM_freeN, NULL, ptr, RNA_function_defined(), RNA_function_identifier(), RNA_pointer_create(), RNA_PROP_BEGIN, RNA_PROP_END, RNA_property_is_idprop(), RNA_Struct, RNA_struct_find_property(), RNA_struct_iterator_property(), RNA_struct_name_get_alloc(), and PointerRNA::type.
Referenced by pyrna_prop_dir(), and pyrna_struct_dir().
|
static |
Definition at line 1243 of file bpy_rna.c.
References BPY_context_get(), BPy_enum_as_string(), free(), MEM_freeN, NULL, ptr, result, and RNA_property_enum_items().
Referenced by pyrna_string_to_enum().
| PyObject* pyrna_enum_bitfield_to_py | ( | const EnumPropertyItem * | items, |
| int | value | ||
| ) |
Definition at line 1444 of file bpy_rna.c.
References NULL, ret, RNA_enum_bitflag_identifiers(), and RNA_ENUM_BITFLAG_SIZE.
Referenced by pyop_call().
|
static |
Definition at line 1462 of file bpy_rna.c.
References BLI_assert, BLI_snprintf(), BPY_context_get(), BPY_LOG_RNA, CLOG_WARN, DummyRNA_NULL_items, MEM_freeN, NULL, PROP_ENUM_FLAG, ptr, ret, RNA_ENUM_BITFLAG_SIZE, RNA_property_enum_bitflag_identifiers(), RNA_property_enum_identifier(), RNA_property_enum_items_ex(), RNA_property_flag(), RNA_property_identifier(), RNA_struct_identifier(), RNA_struct_name_get_alloc(), and PointerRNA::type.
Referenced by pyrna_param_to_py(), and pyrna_prop_to_py().
| int pyrna_enum_value_from_id | ( | const EnumPropertyItem * | item, |
| const char * | identifier, | ||
| int * | r_value, | ||
| const char * | error_prefix | ||
| ) |
Same as RNA_enum_value_from_id, but raises an exception.
Definition at line 804 of file bpy_rna.c.
References BPy_enum_as_string(), MEM_freeN, and RNA_enum_value_from_id().
Referenced by bpy_gizmotype_target_property_def(), pyrna_callback_classmethod_add(), pyrna_callback_classmethod_remove(), pyrna_set_to_enum_bitfield(), and pyrna_set_to_enum_bitmap().
| void pyrna_free_types | ( | void | ) |
Definition at line 8775 of file bpy_rna.c.
References bpy_class_free(), NULL, BPy_TypesModule_State::prop, ptr, RNA_blender_rna_pointer_create(), RNA_PROP_BEGIN, RNA_PROP_END, RNA_struct_find_property(), RNA_struct_py_type_get(), RNA_struct_py_type_set(), and srna_from_ptr().
Referenced by BPY_python_end().
|
static |
Definition at line 6105 of file bpy_rna.c.
References BKE_reports_init(), BLI_assert, BLI_dynstr_appendf(), BLI_dynstr_free(), BLI_dynstr_get_cstring(), BLI_dynstr_new(), BLI_snprintf(), BPY_context_get(), BPy_reports_to_error(), C, ParameterIterator::data, err, MEM_freeN, NULL, PointerRNA::owner_id, ParameterIterator::parm, PARM_OUTPUT, PARM_REQUIRED, pos, PyC_FileAndNum(), pyrna_param_to_py(), pyrna_py_to_prop(), ret, RNA_Function, RNA_function_call(), RNA_function_identifier(), RNA_parameter_flag(), RNA_parameter_list_arg_count(), RNA_parameter_list_begin(), RNA_parameter_list_create(), RNA_parameter_list_end(), RNA_parameter_list_free(), RNA_parameter_list_next(), RNA_pointer_create(), RNA_property_identifier(), RNA_struct_identifier(), RPT_STORE, small_dict_get_item_string(), STREQ, PointerRNA::type, UNLIKELY, and ParameterIterator::valid.
|
static |
|
static |
Definition at line 6436 of file bpy_rna.c.
References MEM_freeN, NULL, ret, RNA_function_as_string_keywords(), RNA_function_identifier(), RNA_function_ui_description(), RNA_struct_identifier(), and self.
|
static |
Definition at line 1125 of file bpy_rna.c.
References RNA_function_identifier(), RNA_struct_identifier(), and self.
|
static |
Definition at line 1694 of file bpy_rna.c.
References BPy_FunctionRNA::func, BPy_FunctionRNA::ptr, ptr, and pyrna_func_Type.
Referenced by pyrna_prop_collection_getattro(), pyrna_struct_getattro(), and pyrna_subtype_set_rna().
| bool pyrna_id_CheckPyObject | ( | PyObject * | obj | ) |
Definition at line 7633 of file bpy_rna.c.
References BPy_StructRNA_Check, ptr, RNA_struct_is_ID(), and PointerRNA::type.
Referenced by idp_from_PyObject(), and pyrna_id_FromPyObject().
| PyObject* pyrna_id_CreatePyObject | ( | ID * | id | ) |
Definition at line 7611 of file bpy_rna.c.
References ptr, pyrna_struct_CreatePyObject(), and RNA_id_pointer_create().
Referenced by bpy_user_map(), foreach_libblock_id_user_map_callback(), and idprop_py_from_idp_id().
| bool pyrna_id_FromPyObject | ( | PyObject * | obj, |
| ID ** | id | ||
| ) |
Definition at line 7622 of file bpy_rna.c.
References NULL, and pyrna_id_CheckPyObject().
Referenced by bpy_batch_remove(), bpy_lib_write(), and idp_from_DatablockPointer().
| void pyrna_invalidate | ( | BPy_DummyPointerRNA * | self | ) |
Definition at line 133 of file bpy_rna.c.
References RNA_POINTER_INVALIDATE, and self.
Referenced by BPY_DECREF_RNA_INVALIDATE().
| PyObject* pyrna_math_object_from_array | ( | PointerRNA * | ptr, |
| PropertyRNA * | prop | ||
| ) |
Definition at line 644 of file bpy_rna.c.
References col, Color_CreatePyObject(), Color_CreatePyObject_cb(), Euler_CreatePyObject(), Euler_CreatePyObject_cb(), EULER_ORDER_XYZ, GHash::flag, len, MATHUTILS_CB_SUBTYPE_COLOR, MATHUTILS_CB_SUBTYPE_EUL, MATHUTILS_CB_SUBTYPE_QUAT, MATHUTILS_CB_SUBTYPE_VEC, mathutils_rna_array_cb_index, mathutils_rna_matrix_cb_index, Matrix_CreatePyObject(), Matrix_CreatePyObject_cb(), NULL, order, PROP_ALL_VECTOR_SUBTYPES, PROP_COLOR, PROP_COLOR_GAMMA, PROP_DYNAMIC, PROP_EULER, PROP_FLOAT, PROP_INT, PROP_MATRIX, PROP_QUATERNION, PROP_THICK_WRAP, ptr, pyrna_prop_array_subscript_slice(), pyrna_prop_CreatePyObject(), pyrna_rotation_euler_order_get(), Quaternion_CreatePyObject(), Quaternion_CreatePyObject_cb(), ret, RNA_property_array_dimension(), RNA_property_array_length(), RNA_property_flag(), RNA_property_float_get_array(), RNA_property_subtype(), RNA_property_type(), type, Vector_CreatePyObject(), and Vector_CreatePyObject_cb().
Referenced by pyrna_py_from_array().
|
static |
Definition at line 5910 of file bpy_rna.c.
References Freestyle::a, ParameterDynAlloc::array, ParameterDynAlloc::array_tot, ATTR_FALLTHROUGH, data, PointerRNA::data, ELEM, CollectionListBase::first, len, Matrix_CreatePyObject(), CollectionPointerLink::next, NULL, PointerRNA::owner_id, PARM_RNAPTR, PROP_ALL_VECTOR_SUBTYPES, PROP_BOOLEAN, PROP_BYTESTRING, PROP_COLLECTION, PROP_DIRPATH, PROP_DYNAMIC, PROP_ENUM, PROP_FILENAME, PROP_FILEPATH, PROP_FLOAT, PROP_INT, PROP_MATRIX, PROP_POINTER, PROP_STRING, PROP_THICK_WRAP, CollectionPointerLink::ptr, ptr, PyC_UnicodeFromByte(), pyrna_enum_to_py(), pyrna_struct_CreatePyObject(), ret, RNA_id_pointer_create(), RNA_parameter_flag(), RNA_pointer_create(), RNA_property_array_check(), RNA_property_array_length(), RNA_property_flag(), RNA_property_pointer_type(), RNA_property_subtype(), RNA_property_type(), RNA_struct_is_ID(), type, and Vector_CreatePyObject().
Referenced by bpy_class_call(), and pyrna_func_call().
|
static |
Definition at line 3286 of file bpy_rna.c.
References BPY_context_get(), len, prop_subscript_ass_array_int(), prop_subscript_ass_array_slice(), pyrna_prop_array_length(), PYRNA_PROP_CHECK_INT, ret, RNA_property_editable_flag(), RNA_property_identifier(), RNA_property_update(), RNA_property_update_check(), RNA_struct_identifier(), and self.
|
static |
Definition at line 2357 of file bpy_rna.c.
References PYRNA_PROP_CHECK_INT, RNA_property_array_length(), and self.
|
static |
Definition at line 3384 of file bpy_rna.c.
References pyrna_array_contains_py(), and self.
|
static |
|
static |
Definition at line 5625 of file bpy_rna.c.
References pyprop_array_foreach_getset(), and PYRNA_PROP_CHECK_OBJ.
|
static |
Definition at line 5636 of file bpy_rna.c.
References pyprop_array_foreach_getset(), and PYRNA_PROP_CHECK_OBJ.
|
static |
|
static |
Definition at line 5645 of file bpy_rna.c.
References len, NULL, pyrna_prop_array_length(), pyrna_prop_array_subscript_slice(), PYRNA_PROP_CHECK_OBJ, ret, and self.
|
static |
Definition at line 2337 of file bpy_rna.c.
References NULL, PYRNA_PROP_CHECK_INT, RNA_property_array_dimension(), RNA_property_array_length(), RNA_property_multi_array_length(), and self.
Referenced by prop_subscript_ass_array_int(), pyprop_array_foreach_getset(), pyrna_prop_array_ass_subscript(), pyrna_prop_array_iter(), pyrna_prop_array_subscript(), pyrna_prop_array_subscript_int(), and pyrna_prop_str().
|
static |
Definition at line 1120 of file bpy_rna.c.
References pyrna_prop_repr_ex(), and self.
|
static |
Definition at line 2945 of file bpy_rna.c.
References len, NULL, pyrna_prop_array_length(), pyrna_prop_array_subscript_int(), pyrna_prop_array_subscript_slice(), PYRNA_PROP_CHECK_OBJ, and self.
|
static |
Definition at line 2458 of file bpy_rna.c.
References len, NULL, pyrna_prop_array_length(), pyrna_prop_array_to_py_index(), and PYRNA_PROP_CHECK_OBJ.
Referenced by pyrna_prop_array_subscript().
|
static |
TODO - dimensions
Definition at line 2647 of file bpy_rna.c.
References BLI_assert, count, length(), NULL, PROP_BOOLEAN, PROP_FLOAT, PROP_INT, ptr, pyrna_prop_array_to_py_index(), PYRNA_STACK_ARRAY, RNA_property_array_dimension(), RNA_property_boolean_get_array(), RNA_property_float_get_array(), RNA_property_int_get_array(), and RNA_property_type().
Referenced by pyrna_math_object_from_array(), pyrna_prop_array_iter(), and pyrna_prop_array_subscript().
|
static |
Definition at line 2260 of file bpy_rna.c.
References PYRNA_PROP_CHECK_OBJ, pyrna_py_from_array_index(), and self.
Referenced by pyrna_prop_array_subscript_int(), and pyrna_prop_array_subscript_slice().
|
static |
Definition at line 3981 of file bpy_rna.c.
References MEM_freeN, NULL, PROP_STRING, ret, RNA_property_identifier(), RNA_property_string_get_alloc(), RNA_property_type(), RNA_struct_identifier(), and self.
|
static |
Definition at line 2860 of file bpy_rna.c.
References CLAMP_MIN, len, NULL, PYRNA_PROP_CHECK_INT, pyrna_prop_collection_ass_subscript_int(), pyrna_prop_collection_subscript_slice(), pyrna_prop_collection_subscript_str(), pyrna_prop_collection_type_check(), RNA_property_collection_length(), and self.
|
static |
Definition at line 2425 of file bpy_rna.c.
References len, PointerRNA_NULL, ptr, PYRNA_PROP_CHECK_INT, PYRNA_PROP_COLLECTION_ABS_INDEX, RNA_property_collection_assign_int(), RNA_property_collection_length(), and self.
Referenced by pyrna_prop_collection_ass_subscript().
|
static |
Definition at line 2364 of file bpy_rna.c.
References PYRNA_PROP_CHECK_INT, RNA_property_collection_begin(), RNA_property_collection_end(), self, and CollectionPropertyIterator::valid.
|
static |
Definition at line 3389 of file bpy_rna.c.
References NULL, pyrna_prop_collection_subscript_str_lib_pair_ptr(), RNA_property_collection_lookup_string(), and self.
|
static |
Definition at line 5103 of file bpy_rna.c.
References MEM_freeN, PYRNA_PROP_CHECK_OBJ, RNA_PROP_BEGIN, RNA_PROP_END, RNA_struct_name_get_alloc(), and self.
|
static |
Definition at line 5457 of file bpy_rna.c.
References foreach_getset(), and PYRNA_PROP_CHECK_OBJ.
|
static |
Definition at line 5468 of file bpy_rna.c.
References foreach_getset(), and PYRNA_PROP_CHECK_OBJ.
|
static |
Definition at line 5057 of file bpy_rna.c.
References NULL, PYRNA_PROP_CHECK_OBJ, pyrna_prop_collection_subscript_str_lib_pair(), pyrna_struct_CreatePyObject(), ret, RNA_property_collection_lookup_string(), and self.
|
static |
Definition at line 4587 of file bpy_rna.c.
References NULL, ptr, pyrna_func_to_py(), pyrna_prop_to_py(), pyrna_struct_CreatePyObject(), pyrna_struct_Subtype(), ret, RNA_property_collection_type_get(), RNA_struct_find_function(), RNA_struct_find_property(), self, and PointerRNA::type.
|
static |
Odd case, we need to be able return a Python method from a #PyTypeObject.tp_getset.
Definition at line 4701 of file bpy_rna.c.
References PointerRNA::data, NULL, pyrna_struct_CreatePyObject(), rna_disallow_writes, rna_id_write_error(), RNA_property_collection_add(), and self.
|
static |
Definition at line 4745 of file bpy_rna.c.
References NULL, rna_disallow_writes, rna_id_write_error(), RNA_property_collection_clear(), and self.
|
static |
Definition at line 4758 of file bpy_rna.c.
References NULL, pos, rna_disallow_writes, rna_id_write_error(), RNA_property_collection_move(), and self.
|
static |
Definition at line 4721 of file bpy_rna.c.
References NULL, rna_disallow_writes, rna_id_write_error(), RNA_property_collection_remove(), and self.
|
static |
Definition at line 4885 of file bpy_rna.c.
References MEM_freeN, pyrna_struct_CreatePyObject(), ret, RNA_PROP_BEGIN, RNA_PROP_END, RNA_struct_name_get_alloc(), and self.
|
static |
Definition at line 7166 of file bpy_rna.c.
References pyrna_prop_collection_iter_CreatePyObject(), and self.
|
static |
Definition at line 7152 of file bpy_rna.c.
References NULL, ptr, pyrna_prop_collection_iter_Type, RNA_property_collection_begin(), and self.
Referenced by pyrna_prop_collection_iter().
|
static |
Definition at line 7197 of file bpy_rna.c.
References NULL, RNA_property_collection_end(), and self.
|
static |
Definition at line 7171 of file bpy_rna.c.
References NULL, pyrna_struct_CreatePyObject(), RNA_property_collection_next(), and self.
|
static |
Definition at line 4855 of file bpy_rna.c.
References MEM_freeN, ret, RNA_PROP_BEGIN, RNA_PROP_END, RNA_struct_name_get_alloc(), and self.
|
static |
Definition at line 2348 of file bpy_rna.c.
References PYRNA_PROP_CHECK_INT, RNA_property_collection_length(), and self.
Referenced by pyrna_prop_str().
|
static |
Definition at line 4667 of file bpy_rna.c.
References NULL, pyrna_py_to_prop(), rna_disallow_writes, rna_id_write_error(), RNA_property_collection_type_get(), RNA_struct_find_property(), and self.
|
static |
Definition at line 2743 of file bpy_rna.c.
References CLAMP_MIN, len, NULL, PYRNA_PROP_CHECK_OBJ, pyrna_prop_collection_subscript_int(), pyrna_prop_collection_subscript_slice(), pyrna_prop_collection_subscript_str(), pyrna_prop_collection_subscript_str_lib_pair(), RNA_property_collection_length(), and self.
|
static |
Definition at line 2392 of file bpy_rna.c.
References len, NULL, PYRNA_PROP_CHECK_OBJ, PYRNA_PROP_COLLECTION_ABS_INDEX, pyrna_struct_CreatePyObject(), RNA_property_collection_length(), RNA_property_collection_lookup_int(), and self.
Referenced by pyrna_prop_collection_subscript().
|
static |
Definition at line 2608 of file bpy_rna.c.
References count, CollectionPropertyIterator::ptr, PYRNA_PROP_CHECK_OBJ, pyrna_struct_CreatePyObject(), RNA_property_collection_begin(), RNA_property_collection_end(), RNA_property_collection_next(), RNA_property_collection_skip(), self, and CollectionPropertyIterator::valid.
Referenced by pyrna_prop_collection_ass_subscript(), pyrna_prop_collection_subscript(), and pyrna_prop_collection_values().
|
static |
Definition at line 2478 of file bpy_rna.c.
References NULL, PYRNA_PROP_CHECK_OBJ, pyrna_struct_CreatePyObject(), RNA_property_collection_lookup_string(), and self.
Referenced by pyrna_prop_collection_ass_subscript(), and pyrna_prop_collection_subscript().
|
static |
Definition at line 2592 of file bpy_rna.c.
References NULL, ptr, pyrna_prop_collection_subscript_str_lib_pair_ptr(), and pyrna_struct_CreatePyObject().
Referenced by pyrna_prop_collection_get(), and pyrna_prop_collection_subscript().
|
static |
Special case: bpy.data.objects["some_id_name", "//some_lib_name.blend"] also for: bpy.data.objects.get(("some_id_name", "//some_lib_name.blend"), fallback)
__contains__ values C-API.Definition at line 2504 of file bpy_rna.c.
References BLI_findstring(), id, lib, ID::lib, Main::libraries, ID::name, NULL, RNA_BlendData, RNA_PROP_BEGIN, RNA_PROP_END, RNA_struct_identifier(), self, and STREQLEN.
Referenced by pyrna_prop_collection_contains(), and pyrna_prop_collection_subscript_str_lib_pair().
|
static |
Definition at line 2817 of file bpy_rna.c.
References BPy_StructRNA_Check, PROP_NEVER_NULL, RNA_property_flag(), RNA_property_pointer_type(), RNA_struct_identifier(), RNA_struct_is_a(), and self.
Referenced by pyrna_prop_collection_ass_subscript().
|
static |
Definition at line 4928 of file bpy_rna.c.
References pyrna_prop_collection_subscript_slice().
|
static |
Definition at line 836 of file bpy_rna.c.
References Freestyle::a, PointerRNA::data, BPy_PropertyRNA::prop, BPy_PropertyRNA::ptr, and PointerRNA::type.
Referenced by pyrna_prop_richcmp().
| PyObject* pyrna_prop_CreatePyObject | ( | PointerRNA * | ptr, |
| PropertyRNA * | prop | ||
| ) |
Definition at line 7560 of file bpy_rna.c.
References NULL, PointerRNA::owner_id, BPy_PropertyRNA::prop, PROP_COLLECTION, PROP_IDPROPERTY, BPy_PropertyRNA::ptr, ptr, pyrna_prop_array_Type, pyrna_prop_collection_idprop_Type, pyrna_prop_collection_Type, pyrna_prop_Type, RNA_property_array_check(), RNA_property_flag(), RNA_property_type(), and type.
Referenced by pyrna_math_object_from_array(), pyrna_prop_to_py(), pyrna_py_from_array(), pyrna_py_from_array_index(), and pyrna_struct_path_resolve().
|
static |
|
static |
Definition at line 4560 of file bpy_rna.c.
References BPy_PropertyRNA_CheckExact, PROP_COLLECTION, pyrna_dir_members_py(), pyrna_dir_members_rna(), ret, RNA_property_collection_type_get(), RNA_property_type(), and self.
|
static |
|
static |
Definition at line 5886 of file bpy_rna.c.
References NULL, BPy_PropertyRNA::prop, BPy_PropertyRNA::ptr, pyrna_prop_Type, ret, and type.
|
static |
Definition at line 3952 of file bpy_rna.c.
References MEM_freeN, NULL, ret, RNA_path_from_ID_to_property(), RNA_property_identifier(), RNA_struct_identifier(), and self.
|
static |
Definition at line 1115 of file bpy_rna.c.
References pyrna_prop_repr_ex().
|
static |
Definition at line 1066 of file bpy_rna.c.
References BKE_idtype_idcode_to_name_plural(), G_MAIN, GS, id, MEM_freeN, ID::name, NULL, PYRNA_PROP_CHECK_OBJ, pyrna_prop_str(), ret, RNA_path_from_real_ID_to_property_index(), RNA_property_identifier(), and self.
Referenced by pyrna_prop_array_repr(), and pyrna_prop_repr().
|
static |
Definition at line 874 of file bpy_rna.c.
References Freestyle::a, ATTR_FALLTHROUGH, BPy_PropertyRNA_Check, NULL, and pyrna_prop_compare().
|
static |
Definition at line 1000 of file bpy_rna.c.
References Freestyle::c, len, MEM_freeN, NULL, PROP_COLLECTION, PROP_POINTER, ptr, pyrna_prop_array_length(), PYRNA_PROP_CHECK_OBJ, pyrna_prop_collection_length(), ret, RNA_enum_id_from_value(), rna_enum_property_type_items, RNA_property_array_check(), RNA_property_collection_type_get(), RNA_property_identifier(), RNA_property_pointer_get(), RNA_property_type(), RNA_struct_identifier(), RNA_struct_name_get_alloc(), self, type, and PointerRNA::type.
Referenced by pyrna_prop_repr_ex().
|
static |
Definition at line 1400 of file bpy_rna.c.
References BPY_context_get(), free(), MEM_freeN, NULL, ptr, pyrna_set_to_enum_bitfield(), ret, RNA_property_enum_items(), RNA_property_identifier(), RNA_struct_identifier(), and PointerRNA::type.
Referenced by pyrna_py_to_prop().
| PyObject* pyrna_prop_to_py | ( | PointerRNA * | ptr, |
| PropertyRNA * | prop | ||
| ) |
Definition at line 1537 of file bpy_rna.c.
References PointerRNA::data, ELEM, MEM_freeN, NULL, PROP_BOOLEAN, PROP_BYTESTRING, PROP_COLLECTION, PROP_DIRPATH, PROP_ENUM, PROP_FILENAME, PROP_FILEPATH, PROP_FLOAT, PROP_INT, PROP_POINTER, PROP_STRING, ptr, PyC_UnicodeFromByteAndSize(), pyrna_enum_to_py(), pyrna_prop_CreatePyObject(), pyrna_py_from_array(), pyrna_struct_CreatePyObject(), ret, RNA_property_array_check(), RNA_property_boolean_get(), RNA_property_enum_get(), RNA_property_float_get(), RNA_property_int_get(), RNA_property_pointer_get(), RNA_property_string_get_alloc(), RNA_property_subtype(), RNA_property_type(), and type.
Referenced by pyrna_driver_get_variable_value(), pyrna_prop_collection_getattro(), pyrna_struct_getattro(), and pyrna_struct_path_resolve().
|
static |
Definition at line 4016 of file bpy_rna.c.
References BPY_context_get(), RNA_property_update(), and self.
| int pyrna_prop_validity_check | ( | BPy_PropertyRNA * | self | ) |
Definition at line 121 of file bpy_rna.c.
References RNA_property_identifier(), and self.
|
static |
Definition at line 1702 of file bpy_rna.c.
References BKE_reports_init(), BLI_addtail(), BLI_assert, BLI_strncpy(), BPY_context_get(), bpy_intern_str_properties, BPy_reports_to_error(), BPy_StructRNA_Check, data, PointerRNA::data, ELEM, err, LIB_TAG_TEMP_MAIN, MEM_callocN, NULL, PointerRNA::owner_id, PARM_OUTPUT, PARM_RNAPTR, PointerRNA_NULL, BPy_PropertyRNA::prop, PROP_BOOLEAN, PROP_BYTESTRING, PROP_COLLECTION, PROP_DIRPATH, PROP_ENUM, PROP_ENUM_FLAG, PROP_FILENAME, PROP_FILEPATH, PROP_FLOAT, PROP_ID_SELF_CHECK, PROP_INT, PROP_NEVER_NULL, PROP_POINTER, PROP_STRING, PROP_THICK_WRAP, CollectionPointerLink::ptr, BPy_StructRNA::ptr, BPy_PropertyRNA::ptr, ptr, PyC_Err_Format_Prefix(), PyC_ExceptionBuffer(), PyC_UnicodeAsByte(), pyrna_prop_collection_Type, pyrna_prop_to_enum_bitfield(), pyrna_py_to_array(), pyrna_pydict_to_props(), pyrna_string_to_enum(), pyrna_struct_CreatePyObject(), pyrna_struct_validity_check(), RNA_AnyType, RNA_Function, RNA_Gizmo, RNA_GizmoProperties, RNA_Operator, RNA_OperatorProperties, RNA_parameter_flag(), RNA_pointer_create(), RNA_property_array_check(), RNA_property_boolean_set(), RNA_property_collection_add(), RNA_property_collection_type_get(), RNA_property_enum_set(), RNA_property_flag(), RNA_property_float_clamp(), RNA_property_float_set(), RNA_property_identifier(), RNA_property_int_clamp(), RNA_property_int_set(), RNA_property_pointer_get(), RNA_property_pointer_set(), RNA_property_pointer_type(), RNA_property_string_maxlength(), RNA_property_string_set(), RNA_property_string_set_bytes(), RNA_property_subtype(), RNA_property_type(), RNA_property_update(), RNA_property_update_check(), RNA_struct_base_child_of(), RNA_struct_identifier(), RNA_struct_is_a(), RPT_STORE, STRINGIFY, ID::tag, type, PointerRNA::type, and UNLIKELY.
Referenced by bpy_class_call(), bpy_class_validate_recursive(), pyrna_func_call(), pyrna_prop_collection_setattro(), pyrna_pydict_to_props(), and pyrna_struct_setattro().
|
static |
Definition at line 2266 of file bpy_rna.c.
References BPY_context_get(), NULL, PROP_BOOLEAN, PROP_FLOAT, PROP_INT, ptr, PyC_Long_AsBool(), pyrna_py_to_array_index(), ret, RNA_property_array_dimension(), RNA_property_boolean_set_index(), RNA_property_float_clamp(), RNA_property_float_set_index(), RNA_property_int_clamp(), RNA_property_int_set_index(), RNA_property_type(), RNA_property_update(), RNA_property_update_check(), and self.
Referenced by prop_subscript_ass_array_int().
| int pyrna_pydict_to_props | ( | PointerRNA * | ptr, |
| PyObject * | kw, | ||
| const bool | all_args, | ||
| const char * | error_prefix | ||
| ) |
This function is used by operators and converting dicts into collections. It takes keyword args and fills them with property values.
Definition at line 1622 of file bpy_rna.c.
References NULL, pos, ptr, pyrna_py_to_prop(), RNA_property_identifier(), RNA_STRUCT_BEGIN, RNA_STRUCT_END, RNA_struct_find_property(), and STREQ.
Referenced by pyop_as_string(), pyop_call(), and pyrna_py_to_prop().
|
static |
|
static |
Definition at line 8829 of file bpy_rna.c.
References BKE_reports_clear(), BKE_reports_init(), BLI_listbase_is_empty(), bpy_class_call(), bpy_class_free(), bpy_class_validate(), BPY_context_get(), bpy_intern_str_bl_rna, bpy_intern_str_register, BPy_reports_to_error(), BPy_reports_write_stdout(), C, CTX_data_main(), ReportList::list, NULL, pyrna_deferred_register_class(), pyrna_struct_as_srna(), pyrna_subtype_set_rna(), pyrna_write_check(), ret, RNA_struct_identifier(), RNA_struct_py_type_get(), RNA_struct_py_type_set(), RNA_struct_register(), and RPT_STORE.
|
static |
Definition at line 609 of file bpy_rna.c.
References EULER_ORDER_XYZ, EULER_ORDER_ZYX, NULL, order, ptr, RNA_property_enum_get(), and RNA_struct_find_property().
Referenced by mathutils_rna_vector_get(), mathutils_rna_vector_set(), and pyrna_math_object_from_array().
| int pyrna_set_to_enum_bitfield | ( | const EnumPropertyItem * | items, |
| PyObject * | value, | ||
| int * | r_value, | ||
| const char * | error_prefix | ||
| ) |
Definition at line 1363 of file bpy_rna.c.
References hash, NULL, pos, pyrna_enum_value_from_id(), and ret.
Referenced by bpy_msgbus_subscribe_rna(), pyrna_prop_to_enum_bitfield(), and pyrna_struct_keyframe_parse().
| BLI_bitmap* pyrna_set_to_enum_bitmap | ( | const EnumPropertyItem * | items, |
| PyObject * | value, | ||
| int | type_size, | ||
| bool | type_convert_sign, | ||
| int | bitmap_size, | ||
| const char * | error_prefix | ||
| ) |
Takes a set of strings and map it to and array of booleans.
Useful when the values aren't flags.
| type_convert_sign | Maps signed to unsigned range, needed when we want to use the full range of a signed short/char. |
Definition at line 1299 of file bpy_rna.c.
References BLI_assert, BLI_assert_unreachable, BLI_BITMAP_ENABLE, BLI_BITMAP_NEW, error(), hash, MEM_freeN, NULL, pos, pyrna_enum_value_from_id(), and ret.
Referenced by bpy_user_map().
|
static |
Definition at line 8968 of file bpy_rna.c.
References ListBase::first, LinkData::next, NULL, BPy_TypesModule_State::prop, PROP_POINTER, RNA_pointer_create(), RNA_property_builtin(), RNA_property_identifier(), RNA_property_pointer_type(), RNA_property_type(), RNA_Struct, and RNA_struct_type_properties().
Referenced by pyrna_unregister_class().
|
static |
Definition at line 7294 of file bpy_rna.c.
References bpy_intern_str___slots__, BPY_LOG_RNA, bpy_types_dict, CLOG_ERROR, CLOG_INFO, NULL, PyC_ObSpitStr(), pyrna_srna_PyBase(), and RNA_struct_identifier().
Referenced by pyrna_srna_Subtype().
|
static |
Definition at line 7267 of file bpy_rna.c.
References NULL, pyrna_srna_Subtype(), pyrna_struct_Type, and RNA_struct_base().
Referenced by pyrna_srna_ExternalType(), and pyrna_srna_Subtype().
|
static |
Definition at line 7351 of file bpy_rna.c.
References BLI_assert, bpy_intern_str___module__, bpy_intern_str___slots__, bpy_intern_str_bpy_types, BPY_LOG_RNA, CLOG_ERROR, NULL, pyrna_srna_ExternalType(), pyrna_srna_PyBase(), pyrna_struct_meta_idprop_Type, pyrna_subtype_set_rna(), RNA_struct_identifier(), RNA_struct_idprops_check(), and RNA_struct_py_type_get().
Referenced by pyrna_srna_PyBase(), pyrna_struct_Subtype(), and pyrna_struct_type_extend_capi().
|
static |
Definition at line 1264 of file bpy_rna.c.
References BPY_context_get(), MEM_freeN, NULL, ptr, pyrna_enum_as_string(), and RNA_property_enum_value().
Referenced by pyrna_py_to_prop().
|
static |
| StructRNA* pyrna_struct_as_srna | ( | PyObject * | self, |
| const bool | parent, | ||
| const char * | error_prefix | ||
| ) |
Definition at line 7849 of file bpy_rna.c.
References bpy_intern_str_bl_rna, BPy_StructRNA_Check, PointerRNA::data, NULL, BPy_StructRNA::ptr, RNA_Struct, and PointerRNA::type.
Referenced by py_msgbus_rna_key_from_py(), PYOP_wrap_macro_define(), pyrna_callback_classmethod_add(), pyrna_callback_classmethod_remove(), pyrna_register_class(), pyrna_unregister_class(), and srna_from_self().
|
static |
Definition at line 3520 of file bpy_rna.c.
References BPy_StructRNA_Check, BPy_Wrap_SetMapItem(), NULL, BPy_StructRNA::ptr, PYRNA_STRUCT_CHECK_INT, rna_disallow_writes, rna_id_write_error(), RNA_struct_idprops(), RNA_struct_idprops_contains_datablock(), RNA_struct_idprops_datablock_allowed(), self, and PointerRNA::type.
|
static |
Definition at line 4043 of file bpy_rna.c.
References BLI_assert, bpy_intern_str_bl_rna, PointerRNA::data, NULL, pos, BPy_StructRNA::ptr, RNA_struct_identifier(), and STREQ.
Referenced by pyrna_struct_bl_rna_get_subclass_py().
|
static |
Definition at line 4106 of file bpy_rna.c.
References bpy_intern_str_bl_rna, PointerRNA::data, id, nodeTypeFind(), NULL, BPy_StructRNA::ptr, ptr, pyrna_struct_CreatePyObject(), bNodeType::rna_ext, RNA_Node, RNA_pointer_create(), RNA_Struct, RNA_struct_identifier(), and ExtensionRNA::srna.
|
static |
|
static |
Definition at line 831 of file bpy_rna.c.
References Freestyle::a, PointerRNA::data, BPy_StructRNA::ptr, and PointerRNA::type.
Referenced by pyrna_struct_richcmp().
|
static |
Definition at line 3415 of file bpy_rna.c.
References IDP_GetPropertyFromGroup(), PYRNA_STRUCT_CHECK_INT, RNA_struct_idprops(), RNA_struct_idprops_check(), and self.
| PyObject* pyrna_struct_CreatePyObject | ( | PointerRNA * | ptr | ) |
Definition at line 7469 of file bpy_rna.c.
References BPY_LOG_RNA, CLOG_WARN, PointerRNA::data, NULL, PointerRNA::owner_id, BPy_StructRNA::ptr, ptr, pyrna_struct_Subtype(), pyrna_struct_Type, RNA_struct_identifier(), RNA_struct_instance(), and PointerRNA::type.
Referenced by bpy_app_generic_callback(), bpy_class_call(), BPy_init_modules(), bpy_lib_exit(), bpy_pydriver_depsgraph_as_pyobject(), bpy_rna_data_context_enter(), BPY_rna_module(), bpy_utils_previews_load(), bpy_utils_previews_new(), Freestyle_getCurrentScene(), pyop_getrna_type(), PYOP_wrap_macro_define(), pyrna_driver_get_variable_value(), pyrna_driver_self_from_anim_rna(), pyrna_id_CreatePyObject(), pyrna_param_to_py(), pyrna_prop_collection_get(), pyrna_prop_collection_getattro(), pyrna_prop_collection_idprop_add(), pyrna_prop_collection_items(), pyrna_prop_collection_iter_next(), pyrna_prop_collection_subscript_int(), pyrna_prop_collection_subscript_slice(), pyrna_prop_collection_subscript_str(), pyrna_prop_collection_subscript_str_lib_pair(), pyrna_prop_to_py(), pyrna_py_to_prop(), pyrna_struct_as_instance(), pyrna_struct_bl_rna_get_subclass(), pyrna_struct_driver_add(), pyrna_struct_get_data(), pyrna_struct_get_id_data(), pyrna_struct_getattro(), pyrna_struct_path_resolve(), pyrna_struct_type_recast(), and pyrna_subtype_set_rna().
|
static |
Definition at line 1177 of file bpy_rna.c.
References IDP_FreeProperty(), NULL, and self.
|
static |
Definition at line 4232 of file bpy_rna.c.
References BLI_freelistN(), BPy_StructRNA_CheckExact, CTX_data_dir_get(), LinkData::data, ListBase::first, LinkData::next, pyrna_dir_members_py(), pyrna_dir_members_rna(), PYRNA_STRUCT_CHECK_OBJ, ret, RNA_Context, and self.
|
static |
Definition at line 4946 of file bpy_rna.c.
References BPy_IDGroup_WrapData(), IDP_GetPropertyFromGroup(), NULL, PYRNA_STRUCT_CHECK_OBJ, RNA_struct_idprops(), RNA_struct_idprops_check(), and self.
|
static |
Definition at line 4799 of file bpy_rna.c.
References pyrna_struct_CreatePyObject(), and self.
|
static |
Definition at line 4785 of file bpy_rna.c.
References pyrna_struct_CreatePyObject(), RNA_id_pointer_create(), and self.
|
static |
Definition at line 4805 of file bpy_rna.c.
References NULL, pyrna_struct_Subtype(), RNA_pointer_create(), RNA_Property, and self.
|
static |
Definition at line 4274 of file bpy_rna.c.
References BLI_assert, BLI_freelistN(), C, CTX_data_get(), CTX_DATA_TYPE_COLLECTION, CTX_DATA_TYPE_POINTER, CTX_RESULT_NO_DATA, CTX_RESULT_OK, PointerRNA::data, ListBase::first, CollectionPointerLink::next, NULL, CollectionPointerLink::ptr, pyrna_func_to_py(), pyrna_prop_to_py(), PYRNA_STRUCT_CHECK_OBJ, pyrna_struct_CreatePyObject(), ret, RNA_Context, RNA_function_defined(), RNA_struct_find_function(), RNA_struct_find_property(), RNA_struct_idprops_check(), self, and STR_ELEM.
|
static |
|
static |
Definition at line 3718 of file bpy_rna.c.
References NULL, PROP_HIDDEN, PYRNA_STRUCT_CHECK_OBJ, RNA_property_flag(), RNA_struct_find_property(), RNA_struct_identifier(), and self.
|
static |
Definition at line 3776 of file bpy_rna.c.
References NULL, PYRNA_STRUCT_CHECK_OBJ, RNA_property_overridable_get(), RNA_struct_find_property(), RNA_struct_identifier(), and self.
|
static |
Definition at line 3747 of file bpy_rna.c.
References NULL, PYRNA_STRUCT_CHECK_OBJ, RNA_property_editable(), RNA_struct_find_property(), RNA_struct_identifier(), and self.
|
static |
Definition at line 3658 of file bpy_rna.c.
References NULL, PyC_ParseBool(), PYRNA_STRUCT_CHECK_OBJ, RNA_property_is_set_ex(), RNA_struct_find_property(), RNA_struct_identifier(), and self.
|
static |
Definition at line 3598 of file bpy_rna.c.
References BPy_Wrap_GetItems(), NULL, RNA_struct_idprops(), RNA_struct_idprops_check(), and self.
|
static |
Definition at line 3571 of file bpy_rna.c.
References BPy_Wrap_GetKeys(), NULL, RNA_struct_idprops(), RNA_struct_idprops_check(), and self.
|
static |
Definition at line 4432 of file bpy_rna.c.
References BPy_PropDeferred_CheckTypeExact, deferred_register_prop(), NULL, pyrna_write_check(), ret, RNA_def_property_free_identifier(), RNA_struct_type_find_property(), and srna_from_self().
|
static |
Definition at line 5838 of file bpy_rna.c.
References NULL, BPy_StructRNA::ptr, pyrna_struct_Type, ret, and type.
|
static |
Definition at line 3895 of file bpy_rna.c.
References MEM_freeN, NULL, PYRNA_STRUCT_CHECK_OBJ, ret, RNA_path_from_ID_to_property(), RNA_path_from_ID_to_struct(), RNA_struct_find_property(), RNA_struct_identifier(), and self.
|
static |
Definition at line 3839 of file bpy_rna.c.
References NULL, pyrna_array_index(), pyrna_prop_CreatePyObject(), pyrna_prop_to_py(), PYRNA_STRUCT_CHECK_OBJ, pyrna_struct_CreatePyObject(), RNA_path_resolve_full(), RNA_property_array_length(), RNA_struct_identifier(), and self.
|
static |
Definition at line 4989 of file bpy_rna.c.
References BPy_IDGroup_MapDataToPy(), IDP_FreeFromGroup(), IDP_GetPropertyFromGroup(), NULL, PYRNA_STRUCT_CHECK_OBJ, ret, RNA_struct_idprops(), RNA_struct_idprops_check(), self, and UNLIKELY.
|
static |
Definition at line 3805 of file bpy_rna.c.
References NULL, PYRNA_STRUCT_CHECK_OBJ, RNA_property_overridable_library_set(), RNA_struct_find_property(), RNA_struct_identifier(), and self.
|
static |
Definition at line 3687 of file bpy_rna.c.
References NULL, PYRNA_STRUCT_CHECK_OBJ, RNA_property_unset(), RNA_struct_find_property(), RNA_struct_identifier(), and self.
|
static |
Definition at line 942 of file bpy_rna.c.
References BKE_idtype_idcode_to_name_plural(), BLI_assert, DEG_get_original_id(), ID::flag, G_MAIN, GS, id, LIB_EMBEDDED_DATA, MEM_freeN, ID::name, NULL, PYRNA_STRUCT_IS_VALID, pyrna_struct_str(), ret, RNA_path_from_real_ID_to_struct(), RNA_struct_identifier(), RNA_struct_is_ID(), and self.
|
static |
Definition at line 843 of file bpy_rna.c.
References Freestyle::a, ATTR_FALLTHROUGH, BPy_StructRNA_Check, NULL, and pyrna_struct_compare().
|
static |
Definition at line 4495 of file bpy_rna.c.
References BLI_freelistN(), C, CTX_data_get(), CTX_RESULT_OK, NULL, pyrna_py_to_prop(), PYRNA_STRUCT_CHECK_INT, RNA_Context, rna_disallow_writes, rna_id_write_error(), RNA_property_editable_flag(), RNA_property_identifier(), RNA_struct_find_property(), RNA_struct_identifier(), and self.
|
static |
Definition at line 906 of file bpy_rna.c.
References DEG_get_original_id(), MEM_freeN, NULL, PYRNA_STRUCT_IS_VALID, ret, RNA_struct_identifier(), RNA_struct_name_get_alloc(), and self.
Referenced by pyrna_struct_repr().
|
static |
Definition at line 3484 of file bpy_rna.c.
References BPy_IDGroup_WrapData(), IDP_GetPropertyFromGroup(), NULL, PYRNA_STRUCT_CHECK_OBJ, RNA_struct_idprops(), RNA_struct_idprops_check(), and self.
|
static |
Definition at line 7463 of file bpy_rna.c.
References ptr, pyrna_srna_Subtype(), and srna_from_ptr().
Referenced by bpy_types_module_getattro(), pyrna_alloc_types(), pyrna_dir_members_py(), pyrna_prop_collection_getattro(), pyrna_struct_CreatePyObject(), and pyrna_struct_get_rna_type().
| void pyrna_struct_type_extend_capi | ( | struct StructRNA * | srna, |
| struct PyMethodDef * | method, | ||
| struct PyGetSetDef * | getset | ||
| ) |
Extend RNA types with C/API methods, properties.
Definition at line 9121 of file bpy_rna.c.
References BLI_assert, err, NULL, pyrna_srna_Subtype(), type, and UNUSED_VARS_NDEBUG.
Referenced by BPY_rna_types_extend_capi().
|
static |
Definition at line 4030 of file bpy_rna.c.
References PYRNA_STRUCT_CHECK_OBJ, pyrna_struct_CreatePyObject(), RNA_pointer_recast(), and self.
| int pyrna_struct_validity_check | ( | BPy_StructRNA * | pysrna | ) |
Definition at line 111 of file bpy_rna.c.
References BPy_StructRNA::ptr, and PointerRNA::type.
Referenced by pyrna_py_to_prop().
|
static |
Definition at line 3625 of file bpy_rna.c.
References BPy_Wrap_GetValues(), NULL, RNA_struct_idprops(), RNA_struct_idprops_check(), and self.
|
static |
Definition at line 7213 of file bpy_rna.c.
References bpy_intern_str_bl_rna, ListBase::first, FUNC_NO_SELF, FUNC_REGISTER, Link::next, NULL, ptr, PyC_ObSpit(), pyrna_func_to_py(), pyrna_struct_CreatePyObject(), RNA_function_flag(), RNA_function_identifier(), RNA_pointer_create(), RNA_Struct, RNA_struct_py_type_get(), RNA_struct_py_type_set(), and RNA_struct_type_functions().
Referenced by pyrna_register_class(), and pyrna_srna_Subtype().
|
static |
|
static |
Definition at line 9007 of file bpy_rna.c.
References BPY_context_get(), bpy_intern_str_bl_rna, bpy_intern_str_unregister, C, CTX_data_main(), G, G_DEBUG_PYTHON, NULL, pyrna_srna_contains_pointer_prop_srna(), pyrna_struct_as_srna(), pyrna_write_check(), ret, RNA_blender_rna_pointer_create(), RNA_PROP_BEGIN, RNA_PROP_END, RNA_struct_find_property(), RNA_struct_identifier(), and RNA_struct_unregister().
| bool pyrna_write_check | ( | void | ) |
Definition at line 362 of file bpy_rna.c.
References rna_disallow_writes.
Referenced by bpy_msgbus_notify(), bpy_prop_boolean_array_get_fn(), bpy_prop_boolean_array_set_fn(), bpy_prop_boolean_get_fn(), bpy_prop_boolean_set_fn(), bpy_prop_enum_get_fn(), bpy_prop_enum_set_fn(), bpy_prop_float_array_get_fn(), bpy_prop_float_array_set_fn(), bpy_prop_float_get_fn(), bpy_prop_float_set_fn(), bpy_prop_int_array_get_fn(), bpy_prop_int_array_set_fn(), bpy_prop_int_get_fn(), bpy_prop_int_set_fn(), bpy_prop_pointer_poll_fn(), bpy_prop_string_get_fn(), bpy_prop_string_length_fn(), bpy_prop_string_set_fn(), bpy_prop_update_fn(), pyop_call(), pyrna_register_class(), pyrna_struct_meta_idprop_setattro(), and pyrna_unregister_class().
| void pyrna_write_set | ( | bool | val | ) |
Definition at line 367 of file bpy_rna.c.
References rna_disallow_writes.
Referenced by bpy_msgbus_notify(), bpy_prop_boolean_array_get_fn(), bpy_prop_boolean_array_set_fn(), bpy_prop_boolean_get_fn(), bpy_prop_boolean_set_fn(), bpy_prop_enum_get_fn(), bpy_prop_enum_set_fn(), bpy_prop_float_array_get_fn(), bpy_prop_float_array_set_fn(), bpy_prop_float_get_fn(), bpy_prop_float_set_fn(), bpy_prop_int_array_get_fn(), bpy_prop_int_array_set_fn(), bpy_prop_int_get_fn(), bpy_prop_int_set_fn(), bpy_prop_pointer_poll_fn(), bpy_prop_string_get_fn(), bpy_prop_string_length_fn(), bpy_prop_string_set_fn(), and bpy_prop_update_fn().
|
static |
Definition at line 8144 of file bpy_rna.c.
References count, ListBase::first, FUNC_NO_SELF, FUNC_USE_SELF_TYPE, Link::next, PARM_OUTPUT, PARM_PYFUNC_OPTIONAL, RNA_function_defined_parameters(), RNA_function_flag(), and RNA_parameter_flag().
Referenced by bpy_class_call(), and bpy_class_validate_recursive().
|
static |
Definition at line 328 of file bpy_rna.c.
References BKE_idtype_idcode_to_name(), BLI_assert, ELEM, GS, id, ID_SCR, ID_WM, ID_WS, ID::name, NULL, PointerRNA::owner_id, ptr, RNA_struct_identifier(), and PointerRNA::type.
Referenced by mathutils_rna_matrix_set(), mathutils_rna_vector_set(), mathutils_rna_vector_set_index(), pyrna_prop_collection_idprop_add(), pyrna_prop_collection_idprop_clear(), pyrna_prop_collection_idprop_move(), pyrna_prop_collection_idprop_remove(), pyrna_prop_collection_setattro(), pyrna_struct_ass_subscript(), and pyrna_struct_setattro().
|
static |
|
static |
Definition at line 7453 of file bpy_rna.c.
References PointerRNA::data, ptr, RNA_Struct, and PointerRNA::type.
Referenced by pyrna_free_types(), and pyrna_struct_Subtype().
| StructRNA* srna_from_self | ( | PyObject * | self, |
| const char * | error_prefix | ||
| ) |
Definition at line 7906 of file bpy_rna.c.
References NULL, and pyrna_struct_as_srna().
Referenced by BPy_RemoveProperty(), deferred_register_prop(), pointer_type_from_py(), and pyrna_struct_meta_idprop_setattro().
| BPy_StructRNA* bpy_context_module = NULL |
Definition at line 97 of file bpy_rna.c.
Referenced by BPY_context_get(), BPY_context_set(), BPy_init_modules(), bpy_prop_enum_itemf_fn(), and bpy_prop_update_fn().
|
static |
Definition at line 7292 of file bpy_rna.c.
Referenced by pyrna_srna_ExternalType().
|
static |
Definition at line 7803 of file bpy_rna.c.
Referenced by BPY_rna_types().
|
static |
|
static |
Definition at line 543 of file bpy_rna.c.
Referenced by BPY_rna_init().
|
static |
Definition at line 402 of file bpy_rna.c.
Referenced by BPY_rna_init(), and pyrna_math_object_from_array().
|
static |
Definition at line 601 of file bpy_rna.c.
Referenced by BPY_rna_init().
|
static |
Definition at line 552 of file bpy_rna.c.
Referenced by BPY_rna_init(), and pyrna_math_object_from_array().
| PyMethodDef meth_bpy_owner_id_get |
Definition at line 9194 of file bpy_rna.c.
Referenced by BPy_init_modules().
| PyMethodDef meth_bpy_owner_id_set |
Definition at line 9200 of file bpy_rna.c.
Referenced by BPy_init_modules().
| PyMethodDef meth_bpy_register_class |
Definition at line 8827 of file bpy_rna.c.
Referenced by BPy_init_modules().
| PyMethodDef meth_bpy_unregister_class |
Definition at line 9001 of file bpy_rna.c.
Referenced by BPy_init_modules().
|
static |
| PyTypeObject pyrna_func_Type |
Definition at line 6972 of file bpy_rna.c.
Referenced by BPY_rna_init(), BPY_rna_types(), and pyrna_func_to_py().
|
static |
|
static |
|
static |
|
static |
| PyTypeObject pyrna_prop_array_Type |
Definition at line 6717 of file bpy_rna.c.
Referenced by BPY_rna_init(), BPY_rna_types(), and pyrna_prop_CreatePyObject().
|
static |
|
static |
|
static |
|
static |
|
static |
Definition at line 6886 of file bpy_rna.c.
Referenced by BPY_rna_init(), and pyrna_prop_CreatePyObject().
|
static |
Definition at line 7068 of file bpy_rna.c.
Referenced by BPY_rna_init(), and pyrna_prop_collection_iter_CreatePyObject().
|
static |
| PyTypeObject pyrna_prop_collection_Type |
Definition at line 6800 of file bpy_rna.c.
Referenced by BPY_rna_init(), BPY_rna_types(), pyrna_prop_CreatePyObject(), and pyrna_py_to_prop().
|
static |
|
static |
| PyTypeObject pyrna_prop_Type |
Definition at line 6633 of file bpy_rna.c.
Referenced by BPY_rna_init(), BPY_rna_types(), pyrna_prop_CreatePyObject(), and pyrna_prop_new().
|
static |
|
static |
|
static |
| PyTypeObject pyrna_struct_meta_idprop_Type |
Definition at line 6456 of file bpy_rna.c.
Referenced by BPY_rna_init(), BPY_rna_types(), and pyrna_srna_Subtype().
| PyTypeObject pyrna_struct_Type |
Definition at line 6540 of file bpy_rna.c.
Referenced by BPY_rna_init(), BPY_rna_types(), Freestyle_evaluateColorRamp(), Freestyle_evaluateCurveMappingF(), pyrna_deferred_register_class_recursive(), pyrna_srna_PyBase(), pyrna_struct_CreatePyObject(), and pyrna_struct_new().
|
static |
Definition at line 326 of file bpy_rna.c.
Referenced by bpy_class_call(), mathutils_rna_matrix_set(), mathutils_rna_vector_set(), mathutils_rna_vector_set_index(), pyrna_prop_collection_idprop_add(), pyrna_prop_collection_idprop_clear(), pyrna_prop_collection_idprop_move(), pyrna_prop_collection_idprop_remove(), pyrna_prop_collection_setattro(), pyrna_struct_ass_subscript(), pyrna_struct_setattro(), pyrna_write_check(), and pyrna_write_set().
|
static |
Definition at line 7687 of file bpy_rna.c.
Referenced by BPY_rna_module(), and BPY_update_rna_module().