Blender  V3.3
BKE_cdderivedmesh.h
Go to the documentation of this file.
1 /* SPDX-License-Identifier: GPL-2.0-or-later
2  * Copyright 2006 Blender Foundation. All rights reserved. */
3 
13 #pragma once
14 
15 #ifdef __cplusplus
16 extern "C" {
17 #endif
18 
19 struct DerivedMesh;
20 struct Mesh;
21 
22 /* creates a CDDerivedMesh from the given Mesh, this will reference the
23  * original data in Mesh, but it is safe to apply vertex coordinates or
24  * calculate normals as those functions will automatically create new
25  * data to not overwrite the original. */
26 struct DerivedMesh *CDDM_from_mesh(struct Mesh *mesh);
27 
28 /* Copies the given DerivedMesh with verts, faces & edges stored as
29  * custom element data. */
30 struct DerivedMesh *CDDM_copy(struct DerivedMesh *source);
31 
32 #ifdef __cplusplus
33 }
34 #endif
struct DerivedMesh * CDDM_copy(struct DerivedMesh *source)
struct DerivedMesh * CDDM_from_mesh(struct Mesh *mesh)