Struct Object

Source
pub struct Object(/* private fields */);
Expand description

Implementations§

Source§

impl Object

Source

pub fn new_camera( py: Python<'_>, location: [f32; 3], rotation: [f32; 3], ) -> BlResult<Self>

Source

pub fn new_empty( py: Python<'_>, location: [f32; 3], rotation: [f32; 3], ) -> BlResult<Empty>

Source

pub fn new_light( py: Python<'_>, type: LightType, location: [f32; 3], rotation: [f32; 3], ) -> BlResult<Self>

Source

pub fn new_mesh( py: Python<'_>, location: [f32; 3], rotation: [f32; 3], ) -> BlResult<Self>

Source

pub fn new_pointcloud( py: Python<'_>, location: [f32; 3], rotation: [f32; 3], ) -> BlResult<Self>

Source

pub fn new_text( py: Python<'_>, location: [f32; 3], rotation: [f32; 3], ) -> BlResult<Self>

Source

pub fn new_volume( py: Python<'_>, location: [f32; 3], rotation: [f32; 3], ) -> BlResult<Self>

Source

pub fn from_name(name: &str) -> BlResult<Self>

Source

pub fn from_active(py: Python<'_>) -> BlResult<Self>

Source

pub fn set_active(&self, py: Python<'_>) -> BlResult<()>

Source

pub fn delete(self, py: Python<'_>) -> BlResult<()>

Source

pub fn object_type(&self, py: Python<'_>) -> BlResult<ObjectType>

Source

pub fn translate( &mut self, py: Python<'_>, translation: [f32; 3], ) -> BlResult<()>

Source

pub fn rotate_euler( &mut self, py: Python<'_>, rotation: [f32; 3], ) -> BlResult<()>

Source

pub fn rotate_quaternion( &mut self, py: Python<'_>, rotation: Quaternion<f32>, ) -> BlResult<()>

Source

pub fn resize(&mut self, py: Python<'_>, size: [f32; 3]) -> BlResult<()>

Source

pub fn set_mode(&self, py: Python<'_>, mode: ObjectMode) -> BlResult<()>

Source

pub fn set_origin( &self, py: Python<'_>, type: OriginType, center: OriginCenter, ) -> BlResult<()>

Source

pub fn active_material(&self, py: Python<'_>) -> PyResult<Material>

Source

pub fn set_active_material( &mut self, py: Python<'_>, value: &Material, ) -> PyResult<()>

Source

pub fn active_material_index(&self, py: Python<'_>) -> PyResult<usize>

Source

pub fn set_active_material_index( &mut self, py: Python<'_>, value: usize, ) -> PyResult<()>

Source

pub fn active_shape_key<'py>(&'py self, py: Python<'py>) -> PyResult<&'py PyAny>

Source

pub fn active_shape_key_index(&self, py: Python<'_>) -> PyResult<i16>

Source

pub fn set_active_shape_key_index( &mut self, py: Python<'_>, value: i16, ) -> PyResult<()>

Source

pub fn add_rest_position_attribute(&self, py: Python<'_>) -> PyResult<bool>

Source

pub fn set_add_rest_position_attribute( &mut self, py: Python<'_>, value: bool, ) -> PyResult<()>

Source

pub fn animation_data<'py>(&'py self, py: Python<'py>) -> PyResult<&'py PyAny>

Source

pub fn animation_visualization<'py>( &'py self, py: Python<'py>, ) -> PyResult<&'py PyAny>

Source

pub fn bound_box<'py>(&'py self, py: Python<'py>) -> PyResult<&'py PyAny>

Source

pub fn collision<'py>(&'py self, py: Python<'py>) -> PyResult<&'py PyAny>

Source

pub fn color(&self, py: Python<'_>) -> PyResult<[f32; 4]>

Source

pub fn set_color(&mut self, py: Python<'_>, value: [f32; 4]) -> PyResult<()>

Source

pub fn constraints<'py>(&'py self, py: Python<'py>) -> PyResult<&'py PyAny>

Source

pub fn cycles<'py>(&'py self, py: Python<'py>) -> PyResult<&'py PyAny>

Source

pub fn data<'py>(&'py self, py: Python<'py>) -> PyResult<&'py PyAny>

Source

pub fn set_data(&mut self, py: Python<'_>, value: &PyAny) -> PyResult<()>

Source

pub fn delta_location(&self, py: Python<'_>) -> PyResult<[f32; 3]>

Source

pub fn set_delta_location( &mut self, py: Python<'_>, value: [f32; 3], ) -> PyResult<()>

Source

pub fn delta_rotation_euler(&self, py: Python<'_>) -> PyResult<[f32; 3]>

Source

pub fn set_delta_rotation_euler( &mut self, py: Python<'_>, value: [f32; 3], ) -> PyResult<()>

Source

pub fn delta_rotation_quaternion(&self, py: Python<'_>) -> PyResult<[f32; 4]>

Source

pub fn set_delta_rotation_quaternion( &mut self, py: Python<'_>, value: [f32; 4], ) -> PyResult<()>

Source

pub fn delta_scale(&self, py: Python<'_>) -> PyResult<[f32; 3]>

Source

pub fn set_delta_scale( &mut self, py: Python<'_>, value: [f32; 3], ) -> PyResult<()>

Source

pub fn dimensions(&self, py: Python<'_>) -> PyResult<[f32; 3]>

Source

pub fn set_dimensions( &mut self, py: Python<'_>, value: [f32; 3], ) -> PyResult<()>

Source

pub fn display<'py>(&'py self, py: Python<'py>) -> PyResult<&'py PyAny>

Source

pub fn display_bounds_type(&self, py: Python<'_>) -> PyResult<String>

Source

pub fn set_display_bounds_type( &mut self, py: Python<'_>, value: &str, ) -> PyResult<()>

Source

pub fn display_type(&self, py: Python<'_>) -> PyResult<String>

Source

pub fn set_display_type(&mut self, py: Python<'_>, value: &str) -> PyResult<()>

Source

pub fn empty_display_size(&self, py: Python<'_>) -> PyResult<f32>

Source

pub fn set_empty_display_size( &mut self, py: Python<'_>, value: f32, ) -> PyResult<()>

Source

pub fn empty_display_type<'py>( &'py self, py: Python<'py>, ) -> PyResult<&'py PyAny>

Source

pub fn set_empty_display_type( &mut self, py: Python<'_>, value: &PyAny, ) -> PyResult<()>

Source

pub fn empty_image_depth(&self, py: Python<'_>) -> PyResult<String>

Source

pub fn set_empty_image_depth( &mut self, py: Python<'_>, value: &str, ) -> PyResult<()>

Source

pub fn empty_image_offset<'py>( &'py self, py: Python<'py>, ) -> PyResult<&'py PyAny>

Source

pub fn set_empty_image_offset( &mut self, py: Python<'_>, value: &PyAny, ) -> PyResult<()>

Source

pub fn empty_image_side(&self, py: Python<'_>) -> PyResult<String>

Source

pub fn set_empty_image_side( &mut self, py: Python<'_>, value: &str, ) -> PyResult<()>

Source

pub fn face_maps<'py>(&'py self, py: Python<'py>) -> PyResult<&'py PyAny>

Source

pub fn field<'py>(&'py self, py: Python<'py>) -> PyResult<&'py PyAny>

Source

pub fn grease_pencil_modifiers<'py>( &'py self, py: Python<'py>, ) -> PyResult<&'py PyAny>

Source

pub fn hide_render(&self, py: Python<'_>) -> PyResult<bool>

Source

pub fn set_hide_render(&mut self, py: Python<'_>, value: bool) -> PyResult<()>

Source

pub fn hide_select(&self, py: Python<'_>) -> PyResult<bool>

Source

pub fn set_hide_select(&mut self, py: Python<'_>, value: bool) -> PyResult<()>

Source

pub fn hide_viewport(&self, py: Python<'_>) -> PyResult<bool>

Source

pub fn set_hide_viewport(&mut self, py: Python<'_>, value: bool) -> PyResult<()>

Source

pub fn image_user<'py>(&'py self, py: Python<'py>) -> PyResult<&'py PyAny>

Source

pub fn instance_collection<'py>( &'py self, py: Python<'py>, ) -> PyResult<&'py PyAny>

Source

pub fn set_instance_collection( &mut self, py: Python<'_>, value: &PyAny, ) -> PyResult<()>

Source

pub fn instance_faces_scale(&self, py: Python<'_>) -> PyResult<f32>

Source

pub fn set_instance_faces_scale( &mut self, py: Python<'_>, value: f32, ) -> PyResult<()>

Source

pub fn instance_type(&self, py: Python<'_>) -> PyResult<String>

Source

pub fn set_instance_type(&mut self, py: Python<'_>, value: &str) -> PyResult<()>

Source

pub fn is_from_instancer(&self, py: Python<'_>) -> PyResult<bool>

Source

pub fn is_from_set(&self, py: Python<'_>) -> PyResult<bool>

Source

pub fn is_holdout(&self, py: Python<'_>) -> PyResult<bool>

Source

pub fn set_is_holdout(&mut self, py: Python<'_>, value: bool) -> PyResult<()>

Source

pub fn is_instancer(&self, py: Python<'_>) -> PyResult<bool>

Source

pub fn is_shadow_catcher(&self, py: Python<'_>) -> PyResult<bool>

Source

pub fn set_is_shadow_catcher( &mut self, py: Python<'_>, value: bool, ) -> PyResult<()>

Source

pub fn lightgroup(&self, py: Python<'_>) -> PyResult<String>

Source

pub fn set_lightgroup(&mut self, py: Python<'_>, value: &str) -> PyResult<()>

Source

pub fn lineart<'py>(&'py self, py: Python<'py>) -> PyResult<&'py PyAny>

Source

pub fn location(&self, py: Python<'_>) -> PyResult<[f32; 3]>

Source

pub fn set_location(&mut self, py: Python<'_>, value: [f32; 3]) -> PyResult<()>

Source

pub fn lock_location<'py>(&'py self, py: Python<'py>) -> PyResult<&'py PyAny>

Source

pub fn set_lock_location( &mut self, py: Python<'_>, value: &PyAny, ) -> PyResult<()>

Source

pub fn lock_rotation<'py>(&'py self, py: Python<'py>) -> PyResult<&'py PyAny>

Source

pub fn set_lock_rotation( &mut self, py: Python<'_>, value: &PyAny, ) -> PyResult<()>

Source

pub fn lock_rotation_w<'py>(&'py self, py: Python<'py>) -> PyResult<&'py PyAny>

Source

pub fn set_lock_rotation_w( &mut self, py: Python<'_>, value: &PyAny, ) -> PyResult<()>

Source

pub fn lock_rotations_4d<'py>( &'py self, py: Python<'py>, ) -> PyResult<&'py PyAny>

Source

pub fn set_lock_rotations_4d( &mut self, py: Python<'_>, value: &PyAny, ) -> PyResult<()>

Source

pub fn lock_scale<'py>(&'py self, py: Python<'py>) -> PyResult<&'py PyAny>

Source

pub fn set_lock_scale(&mut self, py: Python<'_>, value: &PyAny) -> PyResult<()>

Source

pub fn material_slots<'py>(&'py self, py: Python<'py>) -> PyResult<&'py PyAny>

Source

pub fn matrix_basis<'py>(&'py self, py: Python<'py>) -> PyResult<&'py PyAny>

Source

pub fn set_matrix_basis( &mut self, py: Python<'_>, value: &PyAny, ) -> PyResult<()>

Source

pub fn matrix_local<'py>(&'py self, py: Python<'py>) -> PyResult<&'py PyAny>

Source

pub fn set_matrix_local( &mut self, py: Python<'_>, value: &PyAny, ) -> PyResult<()>

Source

pub fn matrix_parent_inverse<'py>( &'py self, py: Python<'py>, ) -> PyResult<&'py PyAny>

Source

pub fn set_matrix_parent_inverse( &mut self, py: Python<'_>, value: &PyAny, ) -> PyResult<()>

Source

pub fn matrix_world<'py>(&'py self, py: Python<'py>) -> PyResult<&'py PyAny>

Source

pub fn set_matrix_world( &mut self, py: Python<'_>, value: &PyAny, ) -> PyResult<()>

Source

pub fn mode(&self, py: Python<'_>) -> PyResult<ContextMode>

Source

pub fn modifiers(&self, py: Python<'_>) -> PyResult<ObjectModifiers>

Source

pub fn motion_path<'py>(&'py self, py: Python<'py>) -> PyResult<&'py PyAny>

Source

pub fn parent(&self, py: Python<'_>) -> PyResult<Self>

Source

pub fn set_parent(&mut self, py: Python<'_>, value: &Self) -> PyResult<()>

Source

pub fn parent_bone(&self, py: Python<'_>) -> PyResult<String>

Source

pub fn set_parent_bone(&mut self, py: Python<'_>, value: &str) -> PyResult<()>

Source

pub fn parent_type(&self, py: Python<'_>) -> PyResult<ObjectType>

Source

pub fn parent_vertices<'py>(&'py self, py: Python<'py>) -> PyResult<&'py PyAny>

Source

pub fn set_parent_vertices( &mut self, py: Python<'_>, value: &PyAny, ) -> PyResult<()>

Source

pub fn particle_systems<'py>(&'py self, py: Python<'py>) -> PyResult<&'py PyAny>

Source

pub fn pass_index(&self, py: Python<'_>) -> PyResult<i16>

Source

pub fn set_pass_index(&mut self, py: Python<'_>, value: i16) -> PyResult<()>

Source

pub fn pose<'py>(&'py self, py: Python<'py>) -> PyResult<&'py PyAny>

Source

pub fn rigid_body<'py>(&'py self, py: Python<'py>) -> PyResult<&'py PyAny>

Source

pub fn rigid_body_constraint<'py>( &'py self, py: Python<'py>, ) -> PyResult<&'py PyAny>

Source

pub fn rotation_axis_angle(&self, py: Python<'_>) -> PyResult<[f32; 4]>

Source

pub fn set_rotation_axis_angle( &mut self, py: Python<'_>, value: [f32; 4], ) -> PyResult<()>

Source

pub fn rotation_euler(&self, py: Python<'_>) -> PyResult<[f32; 3]>

Source

pub fn set_rotation_euler( &mut self, py: Python<'_>, value: [f32; 3], ) -> PyResult<()>

Source

pub fn rotation_mode(&self, py: Python<'_>) -> PyResult<String>

Source

pub fn set_rotation_mode(&mut self, py: Python<'_>, value: &str) -> PyResult<()>

Source

pub fn rotation_quaternion(&self, py: Python<'_>) -> PyResult<[f32; 4]>

Source

pub fn set_rotation_quaternion( &mut self, py: Python<'_>, value: [f32; 4], ) -> PyResult<()>

Source

pub fn scale(&self, py: Python<'_>) -> PyResult<[f32; 3]>

Source

pub fn set_scale(&mut self, py: Python<'_>, value: [f32; 3]) -> PyResult<()>

Source

pub fn shader_effects<'py>(&'py self, py: Python<'py>) -> PyResult<&'py PyAny>

Source

pub fn set_shader_effects( &mut self, py: Python<'_>, value: &PyAny, ) -> PyResult<()>

Source

pub fn show_all_edges(&self, py: Python<'_>) -> PyResult<bool>

Source

pub fn set_show_all_edges( &mut self, py: Python<'_>, value: bool, ) -> PyResult<()>

Source

pub fn show_axis(&self, py: Python<'_>) -> PyResult<bool>

Source

pub fn set_show_axis(&mut self, py: Python<'_>, value: bool) -> PyResult<()>

Source

pub fn show_bounds(&self, py: Python<'_>) -> PyResult<bool>

Source

pub fn set_show_bounds(&mut self, py: Python<'_>, value: bool) -> PyResult<()>

Source

pub fn show_empty_image_only_axis_aligned( &self, py: Python<'_>, ) -> PyResult<bool>

Source

pub fn set_show_empty_image_only_axis_aligned( &mut self, py: Python<'_>, value: bool, ) -> PyResult<()>

Source

pub fn show_empty_image_orthographic(&self, py: Python<'_>) -> PyResult<bool>

Source

pub fn set_show_empty_image_orthographic( &mut self, py: Python<'_>, value: bool, ) -> PyResult<()>

Source

pub fn show_empty_image_perspective(&self, py: Python<'_>) -> PyResult<bool>

Source

pub fn set_show_empty_image_perspective( &mut self, py: Python<'_>, value: bool, ) -> PyResult<()>

Source

pub fn show_in_front(&self, py: Python<'_>) -> PyResult<bool>

Source

pub fn set_show_in_front(&mut self, py: Python<'_>, value: bool) -> PyResult<()>

Source

pub fn show_instancer_for_render(&self, py: Python<'_>) -> PyResult<bool>

Source

pub fn set_show_instancer_for_render( &mut self, py: Python<'_>, value: bool, ) -> PyResult<()>

Source

pub fn show_instancer_for_viewport(&self, py: Python<'_>) -> PyResult<bool>

Source

pub fn set_show_instancer_for_viewport( &mut self, py: Python<'_>, value: bool, ) -> PyResult<()>

Source

pub fn show_name(&self, py: Python<'_>) -> PyResult<bool>

Source

pub fn set_show_name(&mut self, py: Python<'_>, value: bool) -> PyResult<()>

Source

pub fn show_only_shape_key(&self, py: Python<'_>) -> PyResult<bool>

Source

pub fn set_show_only_shape_key( &mut self, py: Python<'_>, value: bool, ) -> PyResult<()>

Source

pub fn show_texture_space(&self, py: Python<'_>) -> PyResult<bool>

Source

pub fn set_show_texture_space( &mut self, py: Python<'_>, value: bool, ) -> PyResult<()>

Source

pub fn show_transparent(&self, py: Python<'_>) -> PyResult<bool>

Source

pub fn set_show_transparent( &mut self, py: Python<'_>, value: bool, ) -> PyResult<()>

Source

pub fn show_wire(&self, py: Python<'_>) -> PyResult<bool>

Source

pub fn set_show_wire(&mut self, py: Python<'_>, value: bool) -> PyResult<()>

Source

pub fn soft_body<'py>(&'py self, py: Python<'py>) -> PyResult<&'py PyAny>

Source

pub fn track_axis<'py>(&'py self, py: Python<'py>) -> PyResult<&'py PyAny>

Source

pub fn up_axis<'py>(&'py self, py: Python<'py>) -> PyResult<&'py PyAny>

Source

pub fn use_camera_lock_parent(&self, py: Python<'_>) -> PyResult<bool>

Source

pub fn set_use_camera_lock_parent( &mut self, py: Python<'_>, value: bool, ) -> PyResult<()>

Source

pub fn use_dynamic_topology_sculpting(&self, py: Python<'_>) -> PyResult<bool>

Source

pub fn use_empty_image_alpha(&self, py: Python<'_>) -> PyResult<bool>

Source

pub fn set_use_empty_image_alpha( &mut self, py: Python<'_>, value: bool, ) -> PyResult<()>

Source

pub fn use_grease_pencil_lights(&self, py: Python<'_>) -> PyResult<bool>

Source

pub fn set_use_grease_pencil_lights( &mut self, py: Python<'_>, value: bool, ) -> PyResult<()>

Source

pub fn use_instance_faces_scale(&self, py: Python<'_>) -> PyResult<bool>

Source

pub fn set_use_instance_faces_scale( &mut self, py: Python<'_>, value: bool, ) -> PyResult<()>

Source

pub fn use_instance_vertices_rotation(&self, py: Python<'_>) -> PyResult<bool>

Source

pub fn set_use_instance_vertices_rotation( &mut self, py: Python<'_>, value: bool, ) -> PyResult<()>

Source

pub fn use_mesh_mirror_x(&self, py: Python<'_>) -> PyResult<bool>

Source

pub fn set_use_mesh_mirror_x( &mut self, py: Python<'_>, value: bool, ) -> PyResult<()>

Source

pub fn use_mesh_mirror_y(&self, py: Python<'_>) -> PyResult<bool>

Source

pub fn set_use_mesh_mirror_y( &mut self, py: Python<'_>, value: bool, ) -> PyResult<()>

Source

pub fn use_mesh_mirror_z(&self, py: Python<'_>) -> PyResult<bool>

Source

pub fn set_use_mesh_mirror_z( &mut self, py: Python<'_>, value: bool, ) -> PyResult<()>

Source

pub fn use_shape_key_edit_mode(&self, py: Python<'_>) -> PyResult<bool>

Source

pub fn set_use_shape_key_edit_mode( &mut self, py: Python<'_>, value: bool, ) -> PyResult<()>

Source

pub fn use_simulation_cache(&self, py: Python<'_>) -> PyResult<bool>

Source

pub fn set_use_simulation_cache( &mut self, py: Python<'_>, value: bool, ) -> PyResult<()>

Source

pub fn vertex_groups<'py>(&'py self, py: Python<'py>) -> PyResult<&'py PyAny>

Source

pub fn visible_camera(&self, py: Python<'_>) -> PyResult<bool>

Source

pub fn set_visible_camera( &mut self, py: Python<'_>, value: bool, ) -> PyResult<()>

Source

pub fn visible_diffuse(&self, py: Python<'_>) -> PyResult<bool>

Source

pub fn set_visible_diffuse( &mut self, py: Python<'_>, value: bool, ) -> PyResult<()>

Source

pub fn visible_glossy(&self, py: Python<'_>) -> PyResult<bool>

Source

pub fn set_visible_glossy( &mut self, py: Python<'_>, value: bool, ) -> PyResult<()>

Source

pub fn visible_shadow(&self, py: Python<'_>) -> PyResult<bool>

Source

pub fn set_visible_shadow( &mut self, py: Python<'_>, value: bool, ) -> PyResult<()>

Source

pub fn visible_transmission(&self, py: Python<'_>) -> PyResult<bool>

Source

pub fn set_visible_transmission( &mut self, py: Python<'_>, value: bool, ) -> PyResult<()>

Source

pub fn visible_volume_scatter(&self, py: Python<'_>) -> PyResult<bool>

Source

pub fn set_visible_volume_scatter( &mut self, py: Python<'_>, value: bool, ) -> PyResult<()>

Source

pub fn children(&self, py: Python<'_>) -> PyResult<Vec<Self>>

Source

pub fn children_recursive(&self, py: Python<'_>) -> PyResult<Vec<Self>>

Source

pub fn users_collection(&self, py: Python<'_>) -> PyResult<Vec<Collection>>

Source

pub fn users_scene<'py>(&'py self, py: Python<'py>) -> PyResult<Vec<Scene<'py>>>

Source

pub fn select_get( &self, py: Python<'_>, view_layer: Option<ViewLayer>, ) -> PyResult<bool>

Source

pub fn select_set( &self, py: Python<'_>, state: bool, view_layer: Option<ViewLayer>, ) -> PyResult<()>

Source

pub fn hide_get( &self, py: Python<'_>, view_layer: Option<ViewLayer>, ) -> PyResult<bool>

Source

pub fn hide_set( &self, py: Python<'_>, state: bool, view_layer: Option<ViewLayer>, ) -> PyResult<()>

Source

pub fn visible_get( &self, py: Python<'_>, view_layer: Option<ViewLayer>, viewport: Option<SpaceView3D<'_>>, ) -> PyResult<bool>

Source

pub fn holdout_get( &self, py: Python<'_>, view_layer: Option<ViewLayer>, ) -> PyResult<bool>

Source

pub fn indirect_only_get( &self, py: Python<'_>, view_layer: Option<ViewLayer>, ) -> PyResult<bool>

Source

pub fn local_view_get( &self, py: Python<'_>, viewport: SpaceView3D<'_>, ) -> PyResult<bool>

Source

pub fn local_view_set( &self, py: Python<'_>, viewport: SpaceView3D<'_>, state: bool, ) -> PyResult<()>

Source

pub fn visible_in_viewport_get( &self, py: Python<'_>, viewport: SpaceView3D<'_>, ) -> PyResult<bool>

Source

pub fn to_mesh(&self, py: Python<'_>) -> PyResult<Mesh>

Source

pub fn to_mesh_clear(&self, py: Python<'_>) -> PyResult<()>

Source

pub fn to_curve(&self, py: Python<'_>, apply_modifiers: bool) -> PyResult<Curve>

Source

pub fn to_curve_clear(&self, py: Python<'_>) -> PyResult<()>

Source

pub fn find_armature(&self, py: Python<'_>) -> PyResult<Self>

Source

pub fn ray_cast( &self, py: Python<'_>, origin: [f32; 3], direction: [f32; 3], distance: f32, ) -> PyResult<(bool, [f32; 3], [f32; 3], i32)>

Source

pub fn closest_point_on_mesh( &self, py: Python<'_>, origin: [f32; 3], distance: f32, ) -> PyResult<(bool, [f32; 3], [f32; 3], i32)>

Source

pub fn is_modified( &self, py: Python<'_>, scene: Scene<'_>, settings: RenderVariant, ) -> PyResult<bool>

Source

pub fn is_deform_modified( &self, py: Python<'_>, scene: Scene<'_>, settings: RenderVariant, ) -> PyResult<bool>

Source

pub fn update_from_editmode(&self, py: Python<'_>) -> PyResult<bool>

Source

pub fn cache_release(&self, py: Python<'_>) -> PyResult<()>

Source

pub fn generate_gpencil_strokes( &self, py: Python<'_>, grease_pencil_object: &Self, use_collections: bool, scale_thickness: f32, sample: f32, ) -> PyResult<bool>

Source§

impl Object

Source

pub fn new_mesh_primitive_circle( py: Python<'_>, vertices: u32, radius: f32, fill_type: &str, calc_uvs: bool, location: [f32; 3], rotation: [f32; 3], scale: [f32; 3], ) -> BlResult<Self>

Source

pub fn new_mesh_primitive_cone( py: Python<'_>, vertices: u32, radius1: f32, radius2: f32, depth: f32, end_fill_type: &str, calc_uvs: bool, location: [f32; 3], rotation: [f32; 3], scale: [f32; 3], ) -> BlResult<Self>

Source

pub fn new_mesh_primitive_cube( py: Python<'_>, size: f32, calc_uvs: bool, location: [f32; 3], rotation: [f32; 3], scale: [f32; 3], ) -> BlResult<Self>

Source

pub fn new_mesh_primitive_cylinder( py: Python<'_>, vertices: u32, radius: f32, depth: f32, end_fill_type: &str, calc_uvs: bool, location: [f32; 3], rotation: [f32; 3], scale: [f32; 3], ) -> BlResult<Self>

Source

pub fn new_mesh_primitive_grid( py: Python<'_>, x_subdivisions: u32, y_subdivisions: u32, size: f32, calc_uvs: bool, location: [f32; 3], rotation: [f32; 3], scale: [f32; 3], ) -> BlResult<Self>

Source

pub fn new_mesh_primitive_ico_sphere( py: Python<'_>, subdivisions: u32, radius: f32, calc_uvs: bool, location: [f32; 3], rotation: [f32; 3], scale: [f32; 3], ) -> BlResult<Self>

Source

pub fn new_mesh_primitive_monkey( py: Python<'_>, size: f32, calc_uvs: bool, location: [f32; 3], rotation: [f32; 3], scale: [f32; 3], ) -> BlResult<Self>

Source

pub fn new_mesh_primitive_plane( py: Python<'_>, size: f32, calc_uvs: bool, location: [f32; 3], rotation: [f32; 3], scale: [f32; 3], ) -> BlResult<Self>

Source

pub fn new_mesh_primitive_torus( py: Python<'_>, location: [f32; 3], rotation: [f32; 3], major_segments: u32, minor_segments: u32, mode: &str, major_radius: f32, minor_radius: f32, abso_major_rad: f32, abso_minor_rad: f32, generate_uvs: bool, ) -> BlResult<Self>

Source

pub fn new_mesh_primitive_uv_sphere( py: Python<'_>, segments: u32, ring_count: u32, radius: f32, calc_uvs: bool, location: [f32; 3], rotation: [f32; 3], scale: [f32; 3], ) -> BlResult<Self>

Methods from Deref<Target = PyObject>§

Source

pub fn as_ref<'py>( &'py self, _py: Python<'py>, ) -> &'py <T as PyTypeInfo>::AsRefTarget

Borrows a GIL-bound reference to the contained T.

By binding to the GIL lifetime, this allows the GIL-bound reference to not require Python<'py> for any of its methods, which makes calling methods on it more ergonomic.

For native types, this reference is &T. For pyclasses, this is &PyCell<T>.

Note that the lifetime of the returned reference is the shortest of &self and Python<'py>. Consider using Py::into_ref instead if this poses a problem.

§Examples

Get access to &PyList from Py<PyList>:

Python::with_gil(|py| {
    let list: Py<PyList> = PyList::empty(py).into();
    let list: &PyList = list.as_ref(py);
    assert_eq!(list.len(), 0);
});

Get access to &PyCell<MyClass> from Py<MyClass>:

#[pyclass]
struct MyClass {}

Python::with_gil(|py| {
    let my_class: Py<MyClass> = Py::new(py, MyClass {}).unwrap();
    let my_class_cell: &PyCell<MyClass> = my_class.as_ref(py);
    assert!(my_class_cell.try_borrow().is_ok());
});
Source

pub fn as_ptr(&self) -> *mut PyObject

Returns the raw FFI pointer represented by self.

§Safety

Callers are responsible for ensuring that the pointer does not outlive self.

The reference is borrowed; callers should not decrease the reference count when they are finished with the pointer.

Source

pub fn borrow<'py>(&'py self, py: Python<'py>) -> PyRef<'py, T>

Immutably borrows the value T.

This borrow lasts while the returned PyRef exists. Multiple immutable borrows can be taken out at the same time.

For frozen classes, the simpler get is available.

Equivalent to self.as_ref(py).borrow() - see PyCell::borrow.

§Examples
#[pyclass]
struct Foo {
    inner: u8,
}

Python::with_gil(|py| -> PyResult<()> {
    let foo: Py<Foo> = Py::new(py, Foo { inner: 73 })?;
    let inner: &u8 = &foo.borrow(py).inner;

    assert_eq!(*inner, 73);
    Ok(())
})?;
§Panics

Panics if the value is currently mutably borrowed. For a non-panicking variant, use try_borrow.

Source

pub fn borrow_mut<'py>(&'py self, py: Python<'py>) -> PyRefMut<'py, T>
where T: PyClass<Frozen = False>,

Mutably borrows the value T.

This borrow lasts while the returned PyRefMut exists.

Equivalent to self.as_ref(py).borrow_mut() - see PyCell::borrow_mut.

§Examples
#[pyclass]
struct Foo {
    inner: u8,
}

Python::with_gil(|py| -> PyResult<()> {
    let foo: Py<Foo> = Py::new(py, Foo { inner: 73 })?;
    foo.borrow_mut(py).inner = 35;

    assert_eq!(foo.borrow(py).inner, 35);
    Ok(())
})?;
§Panics

Panics if the value is currently borrowed. For a non-panicking variant, use try_borrow_mut.

Source

pub fn try_borrow<'py>( &'py self, py: Python<'py>, ) -> Result<PyRef<'py, T>, PyBorrowError>

Attempts to immutably borrow the value T, returning an error if the value is currently mutably borrowed.

The borrow lasts while the returned PyRef exists.

This is the non-panicking variant of borrow.

For frozen classes, the simpler get is available.

Equivalent to self.as_ref(py).borrow_mut() - see PyCell::try_borrow.

Source

pub fn try_borrow_mut<'py>( &'py self, py: Python<'py>, ) -> Result<PyRefMut<'py, T>, PyBorrowMutError>
where T: PyClass<Frozen = False>,

Attempts to mutably borrow the value T, returning an error if the value is currently borrowed.

The borrow lasts while the returned PyRefMut exists.

This is the non-panicking variant of borrow_mut.

Equivalent to self.as_ref(py).try_borrow_mut() - see PyCell::try_borrow_mut.

Source

pub fn get(&self) -> &T
where T: PyClass<Frozen = True> + Sync,

Provide an immutable borrow of the value T without acquiring the GIL.

This is available if the class is frozen and Sync.

§Examples
use std::sync::atomic::{AtomicUsize, Ordering};

#[pyclass(frozen)]
struct FrozenCounter {
    value: AtomicUsize,
}

let cell  = Python::with_gil(|py| {
    let counter = FrozenCounter { value: AtomicUsize::new(0) };

    Py::new(py, counter).unwrap()
});

cell.get().value.fetch_add(1, Ordering::Relaxed);
Source

pub fn is<U>(&self, o: &U) -> bool
where U: AsPyPointer,

Returns whether self and other point to the same object. To compare the equality of two objects (the == operator), use eq.

This is equivalent to the Python expression self is other.

Source

pub fn get_refcnt(&self, _py: Python<'_>) -> isize

Gets the reference count of the ffi::PyObject pointer.

Source

pub fn clone_ref(&self, py: Python<'_>) -> Py<T>

Makes a clone of self.

This creates another pointer to the same object, increasing its reference count.

You should prefer using this method over Clone if you happen to be holding the GIL already.

§Examples
use pyo3::prelude::*;
use pyo3::types::PyDict;

Python::with_gil(|py| {
    let first: Py<PyDict> = PyDict::new(py).into();
    let second = Py::clone_ref(&first, py);

    // Both point to the same object
    assert!(first.is(&second));
});
Source

pub fn is_none(&self, _py: Python<'_>) -> bool

Returns whether the object is considered to be None.

This is equivalent to the Python expression self is None.

Source

pub fn is_ellipsis(&self) -> bool

Returns whether the object is Ellipsis, e.g. ....

This is equivalent to the Python expression self is ....

Source

pub fn is_true(&self, py: Python<'_>) -> Result<bool, PyErr>

Returns whether the object is considered to be true.

This is equivalent to the Python expression bool(self).

Source

pub fn extract<'p, D>(&'p self, py: Python<'p>) -> Result<D, PyErr>
where D: FromPyObject<'p>,

Extracts some type from the Python object.

This is a wrapper function around FromPyObject::extract().

Source

pub fn getattr<N>( &self, py: Python<'_>, attr_name: N, ) -> Result<Py<PyAny>, PyErr>
where N: IntoPy<Py<PyString>>,

Retrieves an attribute value.

This is equivalent to the Python expression self.attr_name.

If calling this method becomes performance-critical, the intern! macro can be used to intern attr_name, thereby avoiding repeated temporary allocations of Python strings.

§Example: intern!ing the attribute name
#[pyfunction]
fn version(sys: Py<PyModule>, py: Python<'_>) -> PyResult<PyObject> {
    sys.getattr(py, intern!(py, "version"))
}
Source

pub fn setattr<N, V>( &self, py: Python<'_>, attr_name: N, value: V, ) -> Result<(), PyErr>
where N: IntoPy<Py<PyString>>, V: IntoPy<Py<PyAny>>,

Sets an attribute value.

This is equivalent to the Python expression self.attr_name = value.

To avoid repeated temporary allocations of Python strings, the intern! macro can be used to intern attr_name.

§Example: intern!ing the attribute name
#[pyfunction]
fn set_answer(ob: PyObject, py: Python<'_>) -> PyResult<()> {
    ob.setattr(py, intern!(py, "answer"), 42)
}
Source

pub fn call( &self, py: Python<'_>, args: impl IntoPy<Py<PyTuple>>, kwargs: Option<&PyDict>, ) -> Result<Py<PyAny>, PyErr>

Calls the object.

This is equivalent to the Python expression self(*args, **kwargs).

Source

pub fn call1( &self, py: Python<'_>, args: impl IntoPy<Py<PyTuple>>, ) -> Result<Py<PyAny>, PyErr>

Calls the object with only positional arguments.

This is equivalent to the Python expression self(*args).

Source

pub fn call0(&self, py: Python<'_>) -> Result<Py<PyAny>, PyErr>

Calls the object without arguments.

This is equivalent to the Python expression self().

Source

pub fn call_method<N, A>( &self, py: Python<'_>, name: N, args: A, kwargs: Option<&PyDict>, ) -> Result<Py<PyAny>, PyErr>
where N: IntoPy<Py<PyString>>, A: IntoPy<Py<PyTuple>>,

Calls a method on the object.

This is equivalent to the Python expression self.name(*args, **kwargs).

To avoid repeated temporary allocations of Python strings, the intern! macro can be used to intern name.

Source

pub fn call_method1<N, A>( &self, py: Python<'_>, name: N, args: A, ) -> Result<Py<PyAny>, PyErr>
where N: IntoPy<Py<PyString>>, A: IntoPy<Py<PyTuple>>,

Calls a method on the object with only positional arguments.

This is equivalent to the Python expression self.name(*args).

To avoid repeated temporary allocations of Python strings, the intern! macro can be used to intern name.

Source

pub fn call_method0<N>( &self, py: Python<'_>, name: N, ) -> Result<Py<PyAny>, PyErr>
where N: IntoPy<Py<PyString>>,

Calls a method on the object with no arguments.

This is equivalent to the Python expression self.name().

To avoid repeated temporary allocations of Python strings, the intern! macro can be used to intern name.

Source

pub fn downcast<'p, T>( &'p self, py: Python<'p>, ) -> Result<&'p T, PyDowncastError<'p>>
where T: PyTryFrom<'p>,

Downcast this PyObject to a concrete Python type or pyclass.

Note that you can often avoid downcasting yourself by just specifying the desired type in function or method signatures. However, manual downcasting is sometimes necessary.

For extracting a Rust-only type, see Py::extract.

§Example: Downcasting to a specific Python object
use pyo3::prelude::*;
use pyo3::types::{PyDict, PyList};

Python::with_gil(|py| {
    let any: PyObject = PyDict::new(py).into();

    assert!(any.downcast::<PyDict>(py).is_ok());
    assert!(any.downcast::<PyList>(py).is_err());
});
§Example: Getting a reference to a pyclass

This is useful if you want to mutate a PyObject that might actually be a pyclass.

use pyo3::prelude::*;

#[pyclass]
struct Class {
    i: i32,
}

Python::with_gil(|py| {
    let class: PyObject = Py::new(py, Class { i: 0 }).unwrap().into_py(py);

    let class_cell: &PyCell<Class> = class.downcast(py)?;

    class_cell.borrow_mut().i += 1;

    // Alternatively you can get a `PyRefMut` directly
    let class_ref: PyRefMut<'_, Class> = class.extract(py)?;
    assert_eq!(class_ref.i, 1);
    Ok(())
})
Source

pub unsafe fn downcast_unchecked<'p, T>(&'p self, py: Python<'p>) -> &'p T
where T: PyTryFrom<'p>,

Casts the PyObject to a concrete Python object type without checking validity.

§Safety

Callers must ensure that the type is valid or risk type confusion.

Source

pub fn as_bytes<'a>(&'a self, _py: Python<'_>) -> &'a [u8]

Gets the Python bytes as a byte slice. Because Python bytes are immutable, the result may be used for as long as the reference to self is held, including when the GIL is released.

Source

pub fn as_ref<'py>(&'py self, _py: Python<'py>) -> &'py PyIterator

Borrows a GIL-bound reference to the PyIterator. By binding to the GIL lifetime, this allows the GIL-bound reference to not require Python for any of its methods.

Source

pub fn as_ref<'py>(&'py self, _py: Python<'py>) -> &'py PyMapping

Borrows a GIL-bound reference to the PyMapping. By binding to the GIL lifetime, this allows the GIL-bound reference to not require Python for any of its methods.

Source

pub fn as_ref<'py>(&'py self, _py: Python<'py>) -> &'py PySequence

Borrows a GIL-bound reference to the PySequence. By binding to the GIL lifetime, this allows the GIL-bound reference to not require Python for any of its methods.

let seq: Py<PySequence> = PyList::empty(py).as_sequence().into();
let seq: &PySequence = seq.as_ref(py);
assert_eq!(seq.len().unwrap(), 0);

Trait Implementations§

Source§

impl BpyID for Object

Source§

fn asset_data<'py>(&'py self, py: Python<'py>) -> PyResult<&'py PyAny>

Source§

fn is_embedded_data(&self, py: Python<'_>) -> PyResult<bool>

Source§

fn is_evaluated(&self, py: Python<'_>) -> PyResult<bool>

Source§

fn is_library_indirect(&self, py: Python<'_>) -> PyResult<bool>

Source§

fn is_missing(&self, py: Python<'_>) -> PyResult<bool>

Source§

fn is_runtime_data(&self, py: Python<'_>) -> PyResult<bool>

Source§

fn set_is_runtime_data(&mut self, py: Python<'_>, value: bool) -> PyResult<()>

Source§

fn library<'py>(&'py self, py: Python<'py>) -> PyResult<&'py PyAny>

Source§

fn library_weak_reference<'py>( &'py self, py: Python<'py>, ) -> PyResult<&'py PyAny>

Source§

fn name(&self, py: Python<'_>) -> PyResult<String>

Source§

fn set_name(&mut self, py: Python<'_>, value: &str) -> PyResult<()>

Source§

fn name_full(&self, py: Python<'_>) -> PyResult<String>

Source§

fn original<'py>(&'py self, py: Python<'py>) -> PyResult<&'py PyAny>

Source§

fn override_library<'py>(&'py self, py: Python<'py>) -> PyResult<&'py PyAny>

Source§

fn preview<'py>(&'py self, py: Python<'py>) -> PyResult<&'py PyAny>

Source§

fn tag(&self, py: Python<'_>) -> PyResult<bool>

Source§

fn set_tag(&mut self, py: Python<'_>, value: bool) -> PyResult<()>

Source§

fn use_extra_user(&self, py: Python<'_>) -> PyResult<bool>

Source§

fn set_use_extra_user(&mut self, py: Python<'_>, value: bool) -> PyResult<()>

Source§

fn use_fake_user(&self, py: Python<'_>) -> PyResult<bool>

Source§

fn set_use_fake_user(&mut self, py: Python<'_>, value: bool) -> PyResult<()>

Source§

fn users(&self, py: Python<'_>) -> PyResult<u32>

Source§

fn evaluated_get<'py>( &'py self, py: Python<'py>, depsgraph: &PyAny, ) -> PyResult<&'py PyAny>

Source§

fn copy<'py>(&'py self, py: Python<'py>) -> PyResult<&'py PyAny>

Source§

fn asset_mark(&self, py: Python<'_>) -> PyResult<()>

Source§

fn asset_clear(&self, py: Python<'_>) -> PyResult<()>

Source§

fn asset_generate_preview(&self, py: Python<'_>) -> PyResult<()>

Source§

fn override_create<'py>( &'py self, py: Python<'py>, remap_local_usages: bool, ) -> PyResult<&'py PyAny>

Source§

fn override_hierarchy_create<'py>( &'py self, py: Python<'py>, scene: Scene<'_>, view_layer: ViewLayer, reference: Option<impl BpyID>, do_fully_editable: bool, ) -> PyResult<&'py PyAny>

Source§

fn override_template_create(&self, py: Python<'_>) -> PyResult<()>

Source§

fn user_clear(&self, py: Python<'_>) -> PyResult<()>

Source§

fn user_remap(&self, py: Python<'_>, new_id: impl BpyID) -> PyResult<()>

Source§

fn make_local<'py>( &'py self, py: Python<'py>, clear_proxy: bool, ) -> PyResult<&'py PyAny>

Source§

fn user_of_id(&self, py: Python<'_>, id: impl BpyID) -> PyResult<u32>

Source§

fn animation_data_create<'py>( &'py self, py: Python<'py>, ) -> PyResult<&'py PyAny>

Source§

fn animation_data_clear(&self, py: Python<'_>) -> PyResult<()>

Source§

fn update_tag(&self, py: Python<'_>, refresh: HashSet<String>) -> PyResult<()>

Source§

fn preview_ensure<'py>(&'py self, py: Python<'py>) -> PyResult<&'py PyAny>

Source§

impl Clone for Object

Source§

fn clone(&self) -> Object

Returns a copy of the value. Read more
1.0.0 · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Debug for Object

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl Deref for Object

Source§

type Target = Py<PyAny>

The resulting type after dereferencing.
Source§

fn deref(&self) -> &Self::Target

Dereferences the value.
Source§

impl DerefMut for Object

Source§

fn deref_mut(&mut self) -> &mut Self::Target

Mutably dereferences the value.
Source§

impl Display for Object

Source§

fn fmt(&self, _derive_more_display_formatter: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl From<&PyAny> for Object

Source§

fn from(value: &PyAny) -> Self

Converts to this type from the input type.
Source§

impl From<Py<PyAny>> for Object

Source§

fn from(value: PyObject) -> Self

Converts to this type from the input type.
Source§

impl FromPyObject<'_> for Object

Source§

fn extract(value: &PyAny) -> PyResult<Self>

Extracts Self from the source PyObject.
Source§

impl ToPyObject for Object

Source§

fn to_object(&self, py: Python<'_>) -> PyObject

Converts self into a Python object.
Source§

impl TryFrom<&Object> for Armature

Source§

type Error = BlError

The type returned in the event of a conversion error.
Source§

fn try_from(value: &Object) -> BlResult<Self>

Performs the conversion.
Source§

impl TryFrom<&Object> for Camera

Source§

type Error = BlError

The type returned in the event of a conversion error.
Source§

fn try_from(value: &Object) -> BlResult<Self>

Performs the conversion.
Source§

impl TryFrom<&Object> for Curve

Source§

type Error = BlError

The type returned in the event of a conversion error.
Source§

fn try_from(value: &Object) -> BlResult<Self>

Performs the conversion.
Source§

impl TryFrom<&Object> for Curves

Source§

type Error = BlError

The type returned in the event of a conversion error.
Source§

fn try_from(value: &Object) -> BlResult<Self>

Performs the conversion.
Source§

impl TryFrom<&Object> for GreasePencil

Source§

type Error = BlError

The type returned in the event of a conversion error.
Source§

fn try_from(value: &Object) -> BlResult<Self>

Performs the conversion.
Source§

impl TryFrom<&Object> for Lattice

Source§

type Error = BlError

The type returned in the event of a conversion error.
Source§

fn try_from(value: &Object) -> BlResult<Self>

Performs the conversion.
Source§

impl TryFrom<&Object> for Light

Source§

type Error = BlError

The type returned in the event of a conversion error.
Source§

fn try_from(value: &Object) -> BlResult<Self>

Performs the conversion.
Source§

impl TryFrom<&Object> for LightProbe

Source§

type Error = BlError

The type returned in the event of a conversion error.
Source§

fn try_from(value: &Object) -> BlResult<Self>

Performs the conversion.
Source§

impl TryFrom<&Object> for Mesh

Source§

type Error = BlError

The type returned in the event of a conversion error.
Source§

fn try_from(value: &Object) -> BlResult<Self>

Performs the conversion.
Source§

impl TryFrom<&Object> for MetaBall

Source§

type Error = BlError

The type returned in the event of a conversion error.
Source§

fn try_from(value: &Object) -> BlResult<Self>

Performs the conversion.
Source§

impl TryFrom<&Object> for PointCloud

Source§

type Error = BlError

The type returned in the event of a conversion error.
Source§

fn try_from(value: &Object) -> BlResult<Self>

Performs the conversion.
Source§

impl TryFrom<&Object> for Speaker

Source§

type Error = BlError

The type returned in the event of a conversion error.
Source§

fn try_from(value: &Object) -> BlResult<Self>

Performs the conversion.
Source§

impl TryFrom<&Object> for Surface

Source§

type Error = BlError

The type returned in the event of a conversion error.
Source§

fn try_from(value: &Object) -> BlResult<Self>

Performs the conversion.
Source§

impl TryFrom<&Object> for TextCurve

Source§

type Error = BlError

The type returned in the event of a conversion error.
Source§

fn try_from(value: &Object) -> BlResult<Self>

Performs the conversion.
Source§

impl TryFrom<&Object> for Volume

Source§

type Error = BlError

The type returned in the event of a conversion error.
Source§

fn try_from(value: &Object) -> BlResult<Self>

Performs the conversion.
Source§

impl TryFrom<Object> for Armature

Source§

type Error = BlError

The type returned in the event of a conversion error.
Source§

fn try_from(value: Object) -> BlResult<Self>

Performs the conversion.
Source§

impl TryFrom<Object> for Camera

Source§

type Error = BlError

The type returned in the event of a conversion error.
Source§

fn try_from(value: Object) -> BlResult<Self>

Performs the conversion.
Source§

impl TryFrom<Object> for Curve

Source§

type Error = BlError

The type returned in the event of a conversion error.
Source§

fn try_from(value: Object) -> BlResult<Self>

Performs the conversion.
Source§

impl TryFrom<Object> for Curves

Source§

type Error = BlError

The type returned in the event of a conversion error.
Source§

fn try_from(value: Object) -> BlResult<Self>

Performs the conversion.
Source§

impl TryFrom<Object> for Empty

Source§

fn try_from(value: Object) -> BlResult<Self>

Converts an Object into an Empty, if the Object is an Empty. Note the underlying data structure of Empty is identical to the Object data structure (not contained in data as the rest of the objects).

Source§

type Error = BlError

The type returned in the event of a conversion error.
Source§

impl TryFrom<Object> for GreasePencil

Source§

type Error = BlError

The type returned in the event of a conversion error.
Source§

fn try_from(value: Object) -> BlResult<Self>

Performs the conversion.
Source§

impl TryFrom<Object> for Lattice

Source§

type Error = BlError

The type returned in the event of a conversion error.
Source§

fn try_from(value: Object) -> BlResult<Self>

Performs the conversion.
Source§

impl TryFrom<Object> for Light

Source§

type Error = BlError

The type returned in the event of a conversion error.
Source§

fn try_from(value: Object) -> BlResult<Self>

Performs the conversion.
Source§

impl TryFrom<Object> for LightProbe

Source§

type Error = BlError

The type returned in the event of a conversion error.
Source§

fn try_from(value: Object) -> BlResult<Self>

Performs the conversion.
Source§

impl TryFrom<Object> for Mesh

Source§

type Error = BlError

The type returned in the event of a conversion error.
Source§

fn try_from(value: Object) -> BlResult<Self>

Performs the conversion.
Source§

impl TryFrom<Object> for MetaBall

Source§

type Error = BlError

The type returned in the event of a conversion error.
Source§

fn try_from(value: Object) -> BlResult<Self>

Performs the conversion.
Source§

impl TryFrom<Object> for PointCloud

Source§

type Error = BlError

The type returned in the event of a conversion error.
Source§

fn try_from(value: Object) -> BlResult<Self>

Performs the conversion.
Source§

impl TryFrom<Object> for Speaker

Source§

type Error = BlError

The type returned in the event of a conversion error.
Source§

fn try_from(value: Object) -> BlResult<Self>

Performs the conversion.
Source§

impl TryFrom<Object> for Surface

Source§

type Error = BlError

The type returned in the event of a conversion error.
Source§

fn try_from(value: Object) -> BlResult<Self>

Performs the conversion.
Source§

impl TryFrom<Object> for TextCurve

Source§

type Error = BlError

The type returned in the event of a conversion error.
Source§

fn try_from(value: Object) -> BlResult<Self>

Performs the conversion.
Source§

impl TryFrom<Object> for Volume

Source§

type Error = BlError

The type returned in the event of a conversion error.
Source§

fn try_from(value: Object) -> BlResult<Self>

Performs the conversion.

Auto Trait Implementations§

§

impl Freeze for Object

§

impl !RefUnwindSafe for Object

§

impl Send for Object

§

impl Sync for Object

§

impl Unpin for Object

§

impl UnwindSafe for Object

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> IntoEither for T

Source§

fn into_either(self, into_left: bool) -> Either<Self, Self>

Converts self into a Left variant of Either<Self, Self> if into_left is true. Converts self into a Right variant of Either<Self, Self> otherwise. Read more
Source§

fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
where F: FnOnce(&Self) -> bool,

Converts self into a Left variant of Either<Self, Self> if into_left(&self) returns true. Converts self into a Right variant of Either<Self, Self> otherwise. Read more
Source§

impl<P, T> Receiver for P
where P: Deref<Target = T> + ?Sized, T: ?Sized,

Source§

type Target = T

🔬This is a nightly-only experimental API. (arbitrary_self_types)
The target type on which the method may be called.
Source§

impl<T> Same for T

Source§

type Output = T

Should always be Self
Source§

impl<SS, SP> SupersetOf<SS> for SP
where SS: SubsetOf<SP>,

Source§

fn to_subset(&self) -> Option<SS>

The inverse inclusion map: attempts to construct self from the equivalent element of its superset. Read more
Source§

fn is_in_subset(&self) -> bool

Checks if self is actually part of its subset T (and can be converted to it).
Source§

fn to_subset_unchecked(&self) -> SS

Use with care! Same as self.to_subset but without any property checks. Always succeeds.
Source§

fn from_subset(element: &SS) -> SP

The inclusion map: converts self to the equivalent element of its superset.
Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T> ToString for T
where T: Display + ?Sized,

Source§

fn to_string(&self) -> String

Converts the given value to a String. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
Source§

impl<T> Ungil for T
where T: Send,