|
Blender V5.0
|
#include "BLI_array_utils.hh"#include "BLI_math_geom.h"#include "BKE_bake_data_block_id.hh"#include "BKE_bvhutils.hh"#include "BKE_customdata.hh"#include "BKE_editmesh_cache.hh"#include "BKE_lib_id.hh"#include "BKE_mesh.hh"#include "BKE_mesh_mapping.hh"#include "BKE_mesh_runtime.hh"#include "BKE_shrinkwrap.hh"#include "BKE_subdiv_ccg.hh"Go to the source code of this file.
Namespaces | |
| namespace | blender |
| namespace | blender::bke |
Typedefs | |
| using | float3 |
Functions | |
| static void | blender::bke::free_mesh_eval (MeshRuntime &mesh_runtime) |
| static void | blender::bke::free_batch_cache (MeshRuntime &mesh_runtime) |
| static void | blender::bke::free_bvh_caches (MeshRuntime &mesh_runtime) |
| static int | blender::bke::reset_bits_and_count (MutableBitSpan bits, const Span< int > indices_to_reset) |
| static void | blender::bke::bit_vector_with_reset_bits_or_empty (const Span< int > indices_to_reset, const int indexed_elems_num, BitVector<> &r_bits, int &r_count) |
| static void | blender::bke::try_tag_verts_no_face_none (const Mesh &mesh) |
Mesh Runtime Struct Utils | |
| int | BKE_mesh_runtime_corner_tris_len (const Mesh *mesh) |
| void | BKE_mesh_runtime_ensure_edit_data (Mesh *mesh) |
| void | BKE_mesh_runtime_clear_cache (Mesh *mesh) |
| void | BKE_mesh_runtime_clear_geometry (Mesh *mesh) |
Mesh Runtime Validation | |
| bool | BKE_mesh_runtime_is_valid (Mesh *mesh_eval) |
Mesh Batch Cache Callbacks | |
| void(* | BKE_mesh_batch_cache_dirty_tag_cb )(Mesh *mesh, eMeshBatchDirtyMode mode) = nullptr |
| void(* | BKE_mesh_batch_cache_free_cb )(void *batch_cache) = nullptr |
| void | BKE_mesh_batch_cache_dirty_tag (Mesh *mesh, eMeshBatchDirtyMode mode) |
| void | BKE_mesh_batch_cache_free (void *batch_cache) |
| using blender::float3 |
Definition at line 619 of file BLI_math_vector_types.hh.
| void BKE_mesh_batch_cache_dirty_tag | ( | Mesh * | mesh, |
| eMeshBatchDirtyMode | mode ) |
Definition at line 450 of file mesh_runtime.cc.
References BKE_mesh_batch_cache_dirty_tag_cb, and Mesh::runtime.
Referenced by BKE_object_batch_cache_dirty_tag(), BKE_object_data_select_update(), blender::ed::sculpt_paint::face_set::edit_modify_geometry(), blender::ed::sculpt_paint::fill_active_color(), geometry_extract_apply(), blender::ed::sculpt_paint::trim::gesture_end(), paint_mask_slice_exec(), paintface_flush_flags(), paintvert_flush_flags(), blender::ed::object::quadriflow_start_job(), blender::ed::object::shade_smooth_exec(), blender::ed::sculpt_paint::symmetrize_exec(), tag_object_after_update(), uv_select_tag_update_for_object(), uv_shortest_path_pick_ex(), blender::ed::object::voxel_remesh_exec(), vpaint_mode_toggle_exec(), vpaint_stroke_update_step(), and wpaint_stroke_update_step().
| void BKE_mesh_batch_cache_free | ( | void * | batch_cache | ) |
Definition at line 463 of file mesh_runtime.cc.
References BKE_mesh_batch_cache_free_cb.
Referenced by blender::bke::free_batch_cache().
| void BKE_mesh_runtime_clear_cache | ( | Mesh * | mesh | ) |
Similar to BKE_mesh_runtime_clear_geometry, but subtly different in that it also clears data-block level features like evaluated data-blocks and edit mode data. They will be functionally the same in most cases, but prefer this function if unsure, since it clears more data.
Definition at line 304 of file mesh_runtime.cc.
References BKE_mesh_runtime_clear_geometry(), blender::bke::free_batch_cache(), and blender::bke::free_mesh_eval().
Referenced by BKE_mesh_clear_geometry(), BKE_mesh_clear_geometry_and_metadata(), BKE_mesh_validate(), blender::nodes::node_geo_extrude_mesh_cc::extrude_mesh_vertices(), mesh_add_edges(), mesh_add_faces(), mesh_add_loops(), mesh_add_verts(), and blender::nodes::node_geo_extrude_mesh_cc::tag_mesh_added_faces().
| void BKE_mesh_runtime_clear_geometry | ( | Mesh * | mesh | ) |
Clear and free any derived caches associated with the mesh geometry data. Examples include BVH caches, normals, triangulation, etc. This should be called when replacing a mesh's geometry directly or making other large changes to topology. It does not need to be called on new meshes.
For "smaller" changes to meshes like updating positions, consider calling a more specific update function like #Mesh::tag_positions_changed().
Definition at line 313 of file mesh_runtime.cc.
References blender::bke::free_bvh_caches(), ME_FLAG_UV_SELECT_SYNC_VALID, and ME_NO_OVERLAPPING_TOPOLOGY.
Referenced by BKE_mesh_runtime_clear_cache(), and BM_mesh_bm_to_me_compact().
| int BKE_mesh_runtime_corner_tris_len | ( | const Mesh * | mesh | ) |
Return the number of derived triangles (corner_tris).
Definition at line 291 of file mesh_runtime.cc.
References poly_to_tri_count().
Referenced by RE_bake_pixels_populate_from_objects().
| void BKE_mesh_runtime_ensure_edit_data | ( | Mesh * | mesh | ) |
Definition at line 297 of file mesh_runtime.cc.
Referenced by BKE_mesh_wrapper_from_editmesh().
| bool BKE_mesh_runtime_is_valid | ( | Mesh * | mesh_eval | ) |
Definition at line 476 of file mesh_runtime.cc.
References BKE_mesh_validate_all_customdata(), BKE_mesh_validate_arrays(), BLI_assert, CD_MDEFORMVERT, CD_MFACE, Mesh::corner_data, Mesh::corners_num, CustomData_get_layer_for_write(), blender::MutableSpan< T >::data(), blender::Span< T >::data(), Mesh::edge_data, Mesh::edges_num, Mesh::face_data, Mesh::faces_num, Mesh::fdata_legacy, Mesh::id, ID::name, printf, blender::MutableSpan< T >::size(), blender::Span< T >::size(), Mesh::totface_legacy, Mesh::vert_data, and Mesh::verts_num.
| void(* BKE_mesh_batch_cache_dirty_tag_cb) (Mesh *mesh, eMeshBatchDirtyMode mode) | ( | Mesh * | mesh, |
| eMeshBatchDirtyMode | mode ) = nullptr |
Definition at line 447 of file mesh_runtime.cc.
Referenced by BKE_mesh_batch_cache_dirty_tag(), and DRW_module_init().
| void(* BKE_mesh_batch_cache_free_cb) (void *batch_cache) | ( | void * | batch_cache | ) | = nullptr |
Definition at line 448 of file mesh_runtime.cc.
Referenced by BKE_mesh_batch_cache_free(), and DRW_module_init().