Blender V4.5
Volume Class Reference

#include <DNA_volume_types.h>

Inherits Mesh.

Public Member Functions

NODE_DECLARE Volume ()
 
void clear (bool preserve_shaders=false) override
 
- Public Member Functions inherited from Mesh
Triangle get_triangle (const size_t i) const
 
size_t num_triangles () const
 
SubdEdgeCrease get_subd_crease (const size_t i) const
 
bool need_tesselation ()
 
 Mesh ()
 
void resize_mesh (const int numverts, const int numtris)
 
void reserve_mesh (const int numverts, const int numtris)
 
void resize_subd_faces (const int numfaces, const int numcorners)
 
void reserve_subd_faces (const int numfaces, const int numcorners)
 
void reserve_subd_creases (const size_t num_creases)
 
void clear_non_sockets ()
 
void add_vertex (const float3 P)
 
void add_vertex_slow (const float3 P)
 
void add_triangle (const int v0, const int v1, const int v2, const int shader, bool smooth)
 
void add_subd_face (const int *corners, const int num_corners, const int shader_, bool smooth_)
 
void add_edge_crease (const int v0, const int v1, const float weight)
 
void add_vertex_crease (const int v, const float weight)
 
void copy_center_to_motion_step (const int motion_step)
 
void compute_bounds () override
 
void apply_transform (const Transform &tfm, const bool apply_to_motion) override
 
void add_vertex_normals ()
 
void add_undisplaced (Scene *scene)
 
void update_generated (Scene *scene)
 
void update_tangents (Scene *scene)
 
void get_uv_tiles (ustring map, unordered_set< int > &tiles) override
 
void pack_shaders (Scene *scene, uint *shader)
 
void pack_normals (packed_float3 *vnormal)
 
void pack_verts (packed_float3 *tri_verts, packed_uint3 *tri_vindex)
 
bool has_motion_blur () const override
 
PrimitiveType primitive_type () const override
 
void tessellate (SubdParams &params)
 
SubdFace get_subd_face (const size_t index) const
 
size_t get_num_subd_faces () const
 
void set_num_subd_faces (const size_t num_subd_faces_)
 
size_t get_num_subd_base_verts () const
 
- Public Member Functions inherited from Geometry
 Geometry (const NodeType *node_type, const Type type)
 
 ~Geometry () override
 
bool need_attribute (Scene *scene, AttributeStandard std)
 
bool need_attribute (Scene *scene, ustring name)
 
AttributeRequestSet needed_attributes ()
 
float motion_time (const int step) const
 
int motion_step (const float time) const
 
void compute_bvh (Device *device, DeviceScene *dscene, SceneParams *params, Progress *progress, const size_t n, size_t total)
 
bool need_build_bvh (BVHLayout layout) const
 
bool is_instanced () const
 
bool has_true_displacement () const
 
bool has_voxel_attributes () const
 
bool is_mesh () const
 
bool is_hair () const
 
bool is_pointcloud () const
 
bool is_volume () const
 
bool is_light () const
 
void tag_update (Scene *scene, bool rebuild)
 
- Public Member Functions inherited from Node
 Node (const NodeType *type, ustring name=ustring())
 
virtual ~Node ()=0
 
void set (const SocketType &input, bool value)
 
void set (const SocketType &input, const int value)
 
void set (const SocketType &input, const uint value)
 
void set (const SocketType &input, const uint64_t value)
 
void set (const SocketType &input, const float value)
 
void set (const SocketType &input, const float2 value)
 
void set (const SocketType &input, const float3 value)
 
void set (const SocketType &input, const char *value)
 
void set (const SocketType &input, ustring value)
 
void set (const SocketType &input, const Transform &value)
 
void set (const SocketType &input, Node *value)
 
template<class ValueType , std::enable_if_t< std::is_enum_v< ValueType >, bool > = true>
void set (const SocketType &input, const ValueType &value)
 
void set (const SocketType &input, array< bool > &value)
 
void set (const SocketType &input, array< int > &value)
 
void set (const SocketType &input, array< float > &value)
 
void set (const SocketType &input, array< float2 > &value)
 
void set (const SocketType &input, array< float3 > &value)
 
void set (const SocketType &input, array< ustring > &value)
 
void set (const SocketType &input, array< Transform > &value)
 
void set (const SocketType &input, array< Node * > &value)
 
bool get_bool (const SocketType &input) const
 
int get_int (const SocketType &input) const
 
uint get_uint (const SocketType &input) const
 
uint64_t get_uint64 (const SocketType &input) const
 
float get_float (const SocketType &input) const
 
float2 get_float2 (const SocketType &input) const
 
float3 get_float3 (const SocketType &input) const
 
ustring get_string (const SocketType &input) const
 
Transform get_transform (const SocketType &input) const
 
Nodeget_node (const SocketType &input) const
 
const array< bool > & get_bool_array (const SocketType &input) const
 
const array< int > & get_int_array (const SocketType &input) const
 
const array< float > & get_float_array (const SocketType &input) const
 
const array< float2 > & get_float2_array (const SocketType &input) const
 
const array< float3 > & get_float3_array (const SocketType &input) const
 
const array< ustring > & get_string_array (const SocketType &input) const
 
const array< Transform > & get_transform_array (const SocketType &input) const
 
const array< Node * > & get_node_array (const SocketType &input) const
 
bool has_default_value (const SocketType &input) const
 
void set_default_value (const SocketType &input)
 
bool equals_value (const Node &other, const SocketType &socket) const
 
void copy_value (const SocketType &socket, const Node &other, const SocketType &other_socket)
 
void set_value (const SocketType &socket, const Node &other, const SocketType &other_socket)
 
bool equals (const Node &other) const
 
void hash (MD5Hash &md5)
 
size_t get_total_size_in_bytes () const
 
bool is_a (const NodeType *type)
 
bool socket_is_modified (const SocketType &input) const
 
bool is_modified () const
 
void tag_modified ()
 
void clear_modified ()
 
void print_modified_sockets () const
 
const NodeOwnerget_owner () const
 
void set_owner (const NodeOwner *owner_)
 
int reference_count () const
 
void reference ()
 
void dereference ()
 
void clear_reference_count ()
 

Public Attributes

ID id
 
struct AnimDataadt
 
char filepath [1024]
 
struct PackedFilepackedfile
 
char is_sequence
 
char sequence_mode
 
char _pad1 [2]
 
int frame_start
 
int frame_duration
 
int frame_offset
 
int flag
 
int active_grid
 
struct Material ** mat
 
short totcol
 
short _pad2 [3]
 
VolumeRender render
 
VolumeDisplay display
 
char velocity_grid [64]
 
char _pad3 [3]
 
char velocity_unit
 
float velocity_scale
 
void * batch_cache
 
VolumeRuntimeHandleruntime
 
- Public Attributes inherited from Mesh
ID id
 
struct AnimDataadt
 
struct Ipo *ipo DNA_DEPRECATED
 
struct Keykey
 
struct Material ** mat
 
int verts_num
 
int edges_num
 
int faces_num
 
int corners_num
 
int * face_offset_indices
 
struct AttributeStorage attribute_storage
 
CustomData vert_data
 
CustomData edge_data
 
CustomData face_data
 
CustomData corner_data
 
ListBase vertex_group_names
 
int vertex_group_active_index
 
int attributes_active_index
 
struct MSelectmselect
 
int totselect
 
int act_face
 
struct Meshtexcomesh
 
float texspace_location [3]
 
float texspace_size [3]
 
char texspace_flag
 
char editflag
 
uint16_t flag
 
float smoothresh_legacy DNA_DEPRECATED
 
float remesh_voxel_size
 
float remesh_voxel_adaptivity
 
int face_sets_color_seed
 
int face_sets_color_default
 
char * active_color_attribute
 
char * default_color_attribute
 
char * active_uv_map_attribute
 
char * default_uv_map_attribute
 
char symmetry
 
char remesh_mode
 
short totcol
 
char cd_flag DNA_DEPRECATED
 
char subdiv DNA_DEPRECATED
 
char subdivr DNA_DEPRECATED
 
char subsurftype DNA_DEPRECATED
 
struct MPoly *mpoly DNA_DEPRECATED
 
struct MLoop *mloop DNA_DEPRECATED
 
struct MVert *mvert DNA_DEPRECATED
 
struct MEdge *medge DNA_DEPRECATED
 
struct MDeformVert *dvert DNA_DEPRECATED
 
struct MTFace *mtface DNA_DEPRECATED
 
struct TFace *tface DNA_DEPRECATED
 
struct MCol *mcol DNA_DEPRECATED
 
struct MFace *mface DNA_DEPRECATED
 
CustomData fdata_legacy
 
int totface_legacy
 
char _pad1 [4]
 
MeshRuntimeHandleruntime
 
AttributeSet subd_attributes
 
size_t vert_offset
 
size_t face_offset
 
size_t corner_offset
 
- Public Attributes inherited from Geometry
Type geometry_type
 
AttributeSet attributes
 
BoundBox bounds
 
bool transform_applied
 
bool transform_negative_scaled
 
Transform transform_normal
 
unique_ptr< BVHbvh
 
size_t attr_map_offset
 
size_t prim_offset
 
bool has_volume
 
bool has_surface_bssrdf
 
bool need_update_rebuild
 
bool need_update_bvh_for_offset
 
size_t index
 
- Public Attributes inherited from Node
ustring name
 
const NodeTypetype
 
InternalNode internal
 
LeafNode leaf
 

Additional Inherited Members

- Public Types inherited from Mesh
enum  SubdivisionType { SUBDIVISION_NONE , SUBDIVISION_LINEAR , SUBDIVISION_CATMULL_CLARK }
 
enum  SubdivisionBoundaryInterpolation { SUBDIVISION_BOUNDARY_NONE , SUBDIVISION_BOUNDARY_EDGE_ONLY , SUBDIVISION_BOUNDARY_EDGE_AND_CORNER }
 
enum  SubdivisionFVarInterpolation {
  SUBDIVISION_FVAR_LINEAR_NONE , SUBDIVISION_FVAR_LINEAR_CORNERS_ONLY , SUBDIVISION_FVAR_LINEAR_CORNERS_PLUS1 , SUBDIVISION_FVAR_LINEAR_CORNERS_PLUS2 ,
  SUBDIVISION_FVAR_LINEAR_BOUNDARIES , SUBDIVISION_FVAR_LINEAR_ALL
}
 
- Public Types inherited from Geometry
enum  Type {
  MESH , HAIR , VOLUME , POINTCLOUD ,
  LIGHT
}
 
- Static Public Attributes inherited from Geometry
static const uint MAX_MOTION_STEPS = 129
 
- Protected Member Functions inherited from Mesh
 Mesh (const NodeType *node_type_, Type geom_type_)
 
void clear (bool preserve_shaders, bool preserve_voxel_data)
 
- Protected Member Functions inherited from Node
template<typename T >
void set_if_different (const SocketType &input, T value)
 
void set_if_different (const SocketType &input, Node *value)
 
template<typename T >
void set_if_different (const SocketType &input, array< T > &value)
 
void set_if_different (const SocketType &input, array< Node * > &value)
 
void dereference_all_used_nodes ()
 
- Static Protected Member Functions inherited from Node
template<typename T >
static Tget_socket_value (const Node *node, const SocketType &socket)
 
- Protected Attributes inherited from Node
const NodeOwnerowner
 
int ref_count {0}
 
SocketModifiedFlags socket_modified
 

Detailed Description

Definition at line 42 of file DNA_volume_types.h.

Constructor & Destructor Documentation

◆ Volume()

Volume::Volume ( )

Definition at line 37 of file scene/volume.cpp.

Member Function Documentation

◆ clear()

void Volume::clear ( bool preserve_shaders = false)
overridevirtual

Reimplemented from Mesh.

Definition at line 44 of file scene/volume.cpp.

References Mesh::clear().

Referenced by GeometryManager::create_volume_mesh().

Member Data Documentation

◆ _pad1

char Volume::_pad1[2]

Definition at line 58 of file DNA_volume_types.h.

◆ _pad2

short Volume::_pad2[3]

Definition at line 72 of file DNA_volume_types.h.

◆ _pad3

char Volume::_pad3[3]

Definition at line 81 of file DNA_volume_types.h.

◆ active_grid

int Volume::active_grid

Definition at line 67 of file DNA_volume_types.h.

Referenced by BKE_volume_grid_active_get_for_read().

◆ adt

struct AnimData* Volume::adt

Definition at line 49 of file DNA_volume_types.h.

Referenced by acf_dsvolume_setting_ptr(), and make_new_animlistelem().

◆ batch_cache

◆ display

◆ filepath

◆ flag

int Volume::flag

Definition at line 64 of file DNA_volume_types.h.

Referenced by acf_dsvolume_setting_ptr().

◆ frame_duration

◆ frame_offset

◆ frame_start

◆ id

◆ is_sequence

◆ mat

◆ packedfile

◆ render

VolumeRender Volume::render

Definition at line 75 of file DNA_volume_types.h.

Referenced by BKE_volume_density_scale(), and BKE_volume_new_for_eval().

◆ runtime

◆ sequence_mode

char Volume::sequence_mode

Definition at line 57 of file DNA_volume_types.h.

Referenced by volume_sequence_frame().

◆ totcol

◆ velocity_grid

char Volume::velocity_grid[64]

Definition at line 79 of file DNA_volume_types.h.

Referenced by BKE_volume_set_velocity_grid_by_name(), and volume_init_data().

◆ velocity_scale

float Volume::velocity_scale

Definition at line 88 of file DNA_volume_types.h.

Referenced by sync_volume_object().

◆ velocity_unit

char Volume::velocity_unit

Definition at line 85 of file DNA_volume_types.h.


The documentation for this class was generated from the following files: