|
Blender V5.3
|
#include "device/device.h"#include "integrator/shader_eval.h"#include "scene/mesh.h"#include "scene/object.h"#include "scene/scene.h"#include "scene/shader.h"#include "util/progress.h"Go to the source code of this file.
Functions | |
| static CCL_NAMESPACE_BEGIN int | fill_shader_input (const Scene *scene, const Mesh *mesh, const size_t object_index, device_vector< KernelShaderEvalInput > &d_input) |
| static void | read_shader_output (const Scene *scene, Mesh *mesh, const device_vector< float > &d_output) |
| static void | compute_vertex_normals (const Mesh *mesh, const packed_float3 *verts_data, const vector< bool > &tri_recompute, vector< float3 > &vN) |
| static void | store_vertex_normals (const Mesh *mesh, const vector< float3 > &vN_float, const vector< bool > &tri_recompute, const bool flip, packed_normal *vN) |
| static void | apply_corner_normal_delta (const Mesh *mesh, const packed_float3 *verts_data, const vector< float3 > &post_vN, const float3 *pre_vN, const vector< bool > &tri_recompute, const bool flip, packed_normal *cN) |
| static void | save_pre_displacement_normals (const Mesh *mesh, array< float3 > &pre_displace_vN, vector< array< float3 > > &pre_displace_motion_vN) |
| static void | recompute_displaced_corner_normals (Mesh *mesh, const vector< float3 > &vN_float, const array< float3 > &pre_displace_vN, const vector< array< float3 > > &pre_displace_motion_vN, const vector< bool > &tri_recompute, const bool flip) |
| static void | recompute_displaced_vertex_normals (Mesh *mesh, const vector< float3 > &vN_float, const vector< bool > &tri_recompute, const bool flip) |
|
static |
Definition at line 203 of file mesh_displace.cpp.
References apply_corner_normal_delta(), Mesh::Triangle::compute_normal(), Mesh::get_triangle(), Mesh::num_triangles(), packed_normal::packed_normal(), safe_normalize(), smooth, and Mesh::Triangle::v.
Referenced by apply_corner_normal_delta(), and recompute_displaced_corner_normals().
|
static |
Definition at line 142 of file mesh_displace.cpp.
References Mesh::Triangle::compute_normal(), compute_vertex_normals(), Mesh::get_triangle(), Mesh::num_triangles(), Mesh::Triangle::v, and zero_float3().
Referenced by compute_vertex_normals(), GeometryManager::displace(), recompute_displaced_corner_normals(), recompute_displaced_vertex_normals(), and save_pre_displacement_normals().
|
static |
Definition at line 19 of file mesh_displace.cpp.
References device_vector< T >::data(), Scene::default_surface, DISPLACE_BUMP, fill_shader_input(), Mesh::get_triangle(), Shader::has_displacement, in, Mesh::num_triangles(), Mesh::num_verts(), Geometry::prim_offset, array< T, alignment >::size(), and Mesh::Triangle::v.
|
static |
Definition at line 87 of file mesh_displace.cpp.
References ATTR_STD_POSITION, Geometry::attributes, device_vector< T >::data(), Attribute::data_for_write(), Scene::default_surface, DISPLACE_BUMP, ensure_finite(), AttributeSet::find(), Geometry::get_position_for_write(), Mesh::get_triangle(), Shader::has_displacement, Attribute::has_motion(), make_float3(), Mesh::num_triangles(), Mesh::num_verts(), read_shader_output(), array< T, alignment >::size(), step, and Mesh::Triangle::v.
|
static |
Definition at line 282 of file mesh_displace.cpp.
References apply_corner_normal_delta(), ATTR_STD_CORNER_NORMAL, ATTR_STD_POSITION, Geometry::attributes, compute_vertex_normals(), array< T, alignment >::data(), Attribute::data(), Attribute::data_for_write(), AttributeSet::find(), Geometry::get_position(), Attribute::has_motion(), Mesh::has_motion_blur(), Mesh::num_verts(), recompute_displaced_corner_normals(), and zero_float3().
Referenced by GeometryManager::displace(), and recompute_displaced_corner_normals().
|
static |
Definition at line 324 of file mesh_displace.cpp.
References ATTR_STD_POSITION, ATTR_STD_VERTEX_NORMAL, Geometry::attributes, compute_vertex_normals(), Attribute::data(), Attribute::data_for_write(), AttributeSet::find(), Attribute::has_motion(), Mesh::has_motion_blur(), Mesh::num_verts(), recompute_displaced_vertex_normals(), store_vertex_normals(), and zero_float3().
Referenced by GeometryManager::displace(), and recompute_displaced_vertex_normals().
|
static |
Definition at line 243 of file mesh_displace.cpp.
References ATTR_STD_CORNER_NORMAL, ATTR_STD_POSITION, Geometry::attributes, compute_vertex_normals(), Attribute::data(), AttributeSet::find(), Geometry::get_position(), Attribute::has_motion(), Mesh::has_motion_blur(), N, Mesh::num_triangles(), Mesh::num_verts(), safe_normalize(), save_pre_displacement_normals(), Geometry::transform_negative_scaled, and zero_float3().
Referenced by GeometryManager::displace(), and save_pre_displacement_normals().
|
static |
Definition at line 172 of file mesh_displace.cpp.
References Mesh::get_triangle(), N, Mesh::num_triangles(), Mesh::num_verts(), packed_normal::packed_normal(), safe_normalize(), store_vertex_normals(), and Mesh::Triangle::v.
Referenced by recompute_displaced_vertex_normals(), and store_vertex_normals().