diff options
author | Sergey Sharybin <sergey@blender.org> | 2022-05-12 10:43:19 +0300 |
---|---|---|
committer | Sergey Sharybin <sergey@blender.org> | 2022-05-12 12:37:05 +0300 |
commit | 0c9892020b7fd1bfd786cc9cdb9e268cd7371dad (patch) | |
tree | 83b8c8bf70491c5b9fbbe6c675a41eb6b0010ad8 /source/blender/blenkernel/BKE_subdiv.h | |
parent | 9599c5415d803cea752c609976dec8b164310a59 (diff) |
Cleanup: More proper sections in subdiv code
Follows the code style.
Diffstat (limited to 'source/blender/blenkernel/BKE_subdiv.h')
-rw-r--r-- | source/blender/blenkernel/BKE_subdiv.h | 32 |
1 files changed, 24 insertions, 8 deletions
diff --git a/source/blender/blenkernel/BKE_subdiv.h b/source/blender/blenkernel/BKE_subdiv.h index 436853fe47b..c18e8a2986c 100644 --- a/source/blender/blenkernel/BKE_subdiv.h +++ b/source/blender/blenkernel/BKE_subdiv.h @@ -186,13 +186,17 @@ typedef struct Subdiv { } cache_; } Subdiv; -/* =================----====--===== MODULE ==========================------== */ +/* -------------------------------------------------------------------- + * Module. + */ /* (De)initialize the entire subdivision surface module. */ void BKE_subdiv_init(void); void BKE_subdiv_exit(void); -/* ========================== CONVERSION HELPERS ============================ */ +/* -------------------------------------------------------------------- + * Conversion helpers. + */ /* NOTE: uv_smooth is eSubsurfUVSmooth. */ eSubdivFVarLinearInterpolation BKE_subdiv_fvar_interpolation_from_uv_smooth(int uv_smooth); @@ -200,7 +204,9 @@ eSubdivFVarLinearInterpolation BKE_subdiv_fvar_interpolation_from_uv_smooth(int eSubdivVtxBoundaryInterpolation BKE_subdiv_vtx_boundary_interpolation_from_subsurf( int boundary_smooth); -/* =============================== STATISTICS =============================== */ +/* -------------------------------------------------------------------- + * Statistics. + */ void BKE_subdiv_stats_init(SubdivStats *stats); @@ -211,11 +217,15 @@ void BKE_subdiv_stats_reset(SubdivStats *stats, eSubdivStatsValue value); void BKE_subdiv_stats_print(const SubdivStats *stats); -/* ================================ SETTINGS ================================ */ +/* -------------------------------------------------------------------- + * Settings. + */ bool BKE_subdiv_settings_equal(const SubdivSettings *settings_a, const SubdivSettings *settings_b); -/* ============================== CONSTRUCTION ============================== */ +/* -------------------------------------------------------------------- + * Construction. + */ /* Construct new subdivision surface descriptor, from scratch, using given * settings and topology. */ @@ -240,7 +250,9 @@ Subdiv *BKE_subdiv_update_from_mesh(Subdiv *subdiv, void BKE_subdiv_free(Subdiv *subdiv); -/* ============================ DISPLACEMENT API ============================ */ +/* -------------------------------------------------------------------- + * Displacemnt API. + */ void BKE_subdiv_displacement_attach_from_multires(Subdiv *subdiv, struct Mesh *mesh, @@ -248,14 +260,18 @@ void BKE_subdiv_displacement_attach_from_multires(Subdiv *subdiv, void BKE_subdiv_displacement_detach(Subdiv *subdiv); -/* ============================ TOPOLOGY HELPERS ============================ */ +/* -------------------------------------------------------------------- + * Topology helpers. + */ /* For each element in the array, this stores the total number of ptex faces up to that element, * with the total number of ptex faces being the last element in the array. The array is of length * `base face count + 1`. */ int *BKE_subdiv_face_ptex_offset_get(Subdiv *subdiv); -/* =========================== PTEX FACES AND GRIDS ========================= */ +/* -------------------------------------------------------------------- + * PTex faces and grids. + */ /* For a given (ptex_u, ptex_v) within a ptex face get corresponding * (grid_u, grid_v) within a grid. */ |