Blender
V3.3
|
Go to the source code of this file.
This file contains access functions for the Mesh.runtime struct.
Definition in file BKE_mesh_runtime.h.
This function clears runtime cache of the given mesh.
Call this function to recalculate runtime data when used.
Definition at line 99 of file mesh_runtime.cc.
References BKE_id_free(), BKE_mesh_batch_cache_free(), BKE_mesh_clear_derived_normals(), BKE_mesh_runtime_clear_edit_data(), BKE_mesh_runtime_clear_geometry(), Mesh::edit_mesh, mesh, Mesh_Runtime::mesh_eval, and Mesh::runtime.
Referenced by BKE_mesh_clear_geometry(), BKE_mesh_runtime_free_data(), mesh_add_edges(), mesh_add_loops(), mesh_add_polys(), mesh_add_verts(), and sculpt_undo_geometry_restore_data().
Definition at line 232 of file mesh_runtime.cc.
References BKE_mesh_runtime_reset_edit_data(), Mesh_Runtime::edit_data, MEM_freeN, mesh, and Mesh::runtime.
Referenced by BKE_mesh_runtime_clear_cache().
Definition at line 245 of file mesh_runtime.cc.
References BKE_mesh_tag_coords_changed(), BKE_shrinkwrap_discard_boundary_data(), BKE_subdiv_ccg_destroy(), MEM_SAFE_FREE, mesh, Mesh::runtime, Mesh_Runtime::subdiv_ccg, and Mesh_Runtime::subsurf_face_dot_tags.
Referenced by BKE_mesh_nomain_to_mesh(), BKE_mesh_runtime_clear_cache(), BM_mesh_bm_to_me(), ED_mesh_join_objects_exec(), quadriflow_start_job(), and voxel_remesh_exec().
Definition at line 207 of file mesh_runtime.cc.
References Mesh_Runtime::edit_data, mesh, and Mesh::runtime.
Referenced by BKE_mesh_wrapper_from_editmesh_with_coords(), and editbmesh_calc_modifiers().
void BKE_mesh_runtime_eval_to_meshkey | ( | struct Mesh * | me_deformed, |
struct Mesh * | me, | ||
struct KeyBlock * | kb | ||
) |
Definition at line 390 of file DerivedMesh.cc.
References BKE_keyblock_convert_from_mesh(), Mesh::key, and Mesh::totvert.
Referenced by ED_mesh_shapes_join_objects_exec().
Free all data (and mutexes) inside the runtime of the given mesh.
Definition at line 72 of file mesh_runtime.cc.
References BKE_mesh_runtime_clear_cache(), mesh, and mesh_runtime_free_mutexes().
Referenced by mesh_free_data().
Initialize the runtime of the given mesh.
Function expects that the runtime is already cleared.
Definition at line 67 of file mesh_runtime.cc.
References mesh, and mesh_runtime_init_mutexes().
Referenced by mesh_blend_read_data(), and mesh_init_data().
Definition at line 315 of file mesh_runtime.cc.
References BKE_mesh_validate_all_customdata(), BKE_mesh_validate_arrays(), BLI_assert, Mesh::dvert, Mesh::edata, Mesh::id, is_valid, Mesh::ldata, Mesh::medge, Mesh::mface, Mesh::mloop, Mesh::mpoly, Mesh::mvert, ID::name, Mesh::pdata, Mesh::totedge, Mesh::totface, Mesh::totloop, Mesh::totpoly, Mesh::totvert, and Mesh::vdata.
Referenced by BKE_bvhtree_from_mesh_get(), BKE_editmesh_looptri_calc_ex(), BKE_mesh_calc_loop_tangents(), BKE_mesh_remap_calc_loops_from_mesh(), BKE_remesh_reproject_sculpt_face_sets(), C_BVHTree_FromObject(), cloth_from_mesh(), blender::nodes::node_geo_distribute_points_on_faces_cc::compute_attribute_outputs(), deformVerts(), dynamicPaint_createUVSurface(), dynamicPaint_paintMesh(), dynamicPaint_setInitialColor(), blender::bke::mesh_surface_sample::MeshAttributeInterpolator::ensure_barycentric_coords(), blender::bke::mesh_surface_sample::MeshAttributeInterpolator::ensure_nearest_weights(), blender::ed::sculpt_paint::AddOperationExecutor::execute(), blender::ed::sculpt_paint::DensityAddOperationExecutor::execute(), blender::ed::sculpt_paint::PuffOperationExecutor::execute(), blender::ed::sculpt_paint::SlideOperationExecutor::execute(), blender::nodes::node_geo_transfer_attribute_cc::get_closest_mesh_polygons(), harmonic_coordinates_bind(), imapaint_pick_uv(), initSystem(), lineart_geometry_object_load(), blender::nodes::node_geo_deform_curves_on_surface_cc::node_geo_exec(), proj_paint_state_mesh_eval_init(), RE_bake_pixels_populate_from_objects(), blender::bke::mesh_surface_sample::sample_corner_attribute(), blender::bke::mesh_surface_sample::sample_face_attribute(), blender::nodes::node_geo_distribute_points_on_faces_cc::sample_mesh_surface(), blender::bke::mesh_surface_sample::sample_point_attribute(), blender::bke::mesh_surface_sample::sample_surface_points_projected(), blender::bke::mesh_surface_sample::sample_surface_points_spherical(), shrinkwrap_build_boundary_data(), blender::ed::curves::snap_curves_to_surface::snap_curves_to_surface_exec_object(), surfacedeformBind(), blender::ed::curves::convert_to_particle_system::try_convert_single_object(), and blender::nodes::node_geo_distribute_points_on_faces_cc::update_elimination_mask_based_on_density_factors().
int BKE_mesh_runtime_looptri_len | ( | const struct Mesh * | mesh | ) |
Referenced by BKE_bvhtree_from_mesh_get(), C_BVHTree_FromObject(), blender::nodes::node_geo_distribute_points_on_faces_cc::compute_attribute_outputs(), deformVerts(), dynamicPaint_createUVSurface(), dynamicPaint_setInitialColor(), blender::bke::mesh_surface_sample::MeshAttributeInterpolator::ensure_barycentric_coords(), blender::bke::mesh_surface_sample::MeshAttributeInterpolator::ensure_nearest_weights(), blender::ed::sculpt_paint::AddOperationExecutor::execute(), blender::ed::sculpt_paint::DensityAddOperationExecutor::execute(), blender::ed::sculpt_paint::PuffOperationExecutor::execute(), blender::ed::sculpt_paint::SlideOperationExecutor::execute(), blender::nodes::node_geo_transfer_attribute_cc::get_closest_mesh_polygons(), initSystem(), lineart_geometry_object_load(), blender::nodes::node_geo_deform_curves_on_surface_cc::node_geo_exec(), blender::bke::mesh_surface_sample::sample_corner_attribute(), blender::bke::mesh_surface_sample::sample_face_attribute(), blender::nodes::node_geo_distribute_points_on_faces_cc::sample_mesh_surface(), blender::bke::mesh_surface_sample::sample_point_attribute(), blender::bke::mesh_surface_sample::sample_surface_points_projected(), blender::bke::mesh_surface_sample::sample_surface_points_spherical(), shrinkwrap_build_boundary_data(), blender::ed::curves::snap_curves_to_surface::snap_curves_to_surface_exec_object(), blender::ed::curves::convert_to_particle_system::try_convert_single_object(), and blender::nodes::node_geo_distribute_points_on_faces_cc::update_elimination_mask_based_on_density_factors().
Definition at line 146 of file mesh_runtime.cc.
References MLoopTri_Store::array, MLoopTri_Store::array_wip, atomic_cas_ptr(), BKE_mesh_recalc_looptri(), BLI_assert, Mesh_Runtime::looptris, mesh, mesh_ensure_looptri_data(), Mesh::mloop, Mesh::mpoly, Mesh::mvert, Mesh::runtime, Mesh::totloop, and Mesh::totpoly.
Referenced by BKE_mesh_runtime_looptri_ensure().
Definition at line 217 of file mesh_runtime.cc.
References Mesh_Runtime::edit_data, MEM_SAFE_FREE, mesh, EditMeshData::polyCos, EditMeshData::polyNos, Mesh::runtime, EditMeshData::vertexCos, and EditMeshData::vertexNos.
Referenced by BKE_mesh_runtime_clear_edit_data(), and editbmesh_calc_modifiers().
Clear all pointers which we don't want to be shared on copying the datablock. However, keep all the flags which defines what the mesh is (for example, that it's deformed only, or that its custom data layers are out of date.)
Referenced by mesh_copy_data().
void BKE_mesh_runtime_verttri_from_looptri | ( | struct MVertTri * | r_verttri, |
const struct MLoop * | mloop, | ||
const struct MLoopTri * | looptri, | ||
int | looptri_num | ||
) |
Referenced by cloth_from_mesh(), and deformVerts().
struct Mesh* mesh_create_eval_final | ( | struct Depsgraph * | depsgraph, |
const struct Scene * | scene, | ||
struct Object * | ob, | ||
const struct CustomData_MeshMasks * | dataMask | ||
) |
Referenced by bvh_get_mesh(), mesh_new_from_mesh_object_with_layers(), and object_force_modifier_update_for_bind().
struct Mesh* mesh_create_eval_no_deform | ( | struct Depsgraph * | depsgraph, |
const struct Scene * | scene, | ||
struct Object * | ob, | ||
const struct CustomData_MeshMasks * | dataMask | ||
) |
Referenced by bvh_get_mesh().
struct Mesh* mesh_create_eval_no_deform_render | ( | struct Depsgraph * | depsgraph, |
const struct Scene * | scene, | ||
struct Object * | ob, | ||
const struct CustomData_MeshMasks * | dataMask | ||
) |
Referenced by bvh_get_mesh().
struct Mesh* mesh_get_eval_deform | ( | struct Depsgraph * | depsgraph, |
const struct Scene * | scene, | ||
struct Object * | ob, | ||
const struct CustomData_MeshMasks * | dataMask | ||
) |
struct Mesh* mesh_get_eval_final | ( | struct Depsgraph * | depsgraph, |
const struct Scene * | scene, | ||
struct Object * | ob, | ||
const struct CustomData_MeshMasks * | dataMask | ||
) |
Referenced by add_verts_to_dgroups(), bc_get_mesh_copy(), BKE_mesh_to_curve(), BKE_mesh_to_pointcloud(), BKE_object_data_transfer_ex(), BKE_object_data_transfer_layout(), bpy_bmesh_from_object(), bvh_get_mesh(), blender::io::alembic::ABCHairWriter::do_write(), dt_layers_select_src_itemf(), ED_mesh_pick_face_vert(), ED_mesh_pick_vert(), knifeproject_poly_from_object(), meshobject_foreachScreenVert(), multiresModifier_reshapeFromObject(), object_convert_exec(), paint_sample_color(), paint_weight_gradient_exec(), particle_intersect_mesh(), proj_paint_state_mesh_eval_init(), vpaint_proj_dm_map_cosnos_init(), and vpaint_proj_dm_map_cosnos_update().