Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCampbell Barton <campbell@blender.org>2022-09-25 11:30:50 +0300
committerCampbell Barton <campbell@blender.org>2022-09-25 11:31:10 +0300
commitc7b247a118e302a3afc6473797e53b6af28b69e2 (patch)
treed11149a165bfd8f3b3b791f24547499f041b133b /source/blender/draw/intern/draw_cache_impl_subdivision.cc
parent891949cbb47143420f4324cb60efc05ef5d70b39 (diff)
Cleanup: replace static_casts with functional casts for numeric types
Diffstat (limited to 'source/blender/draw/intern/draw_cache_impl_subdivision.cc')
-rw-r--r--source/blender/draw/intern/draw_cache_impl_subdivision.cc8
1 files changed, 4 insertions, 4 deletions
diff --git a/source/blender/draw/intern/draw_cache_impl_subdivision.cc b/source/blender/draw/intern/draw_cache_impl_subdivision.cc
index 8492804775e..c387a47f0a6 100644
--- a/source/blender/draw/intern/draw_cache_impl_subdivision.cc
+++ b/source/blender/draw/intern/draw_cache_impl_subdivision.cc
@@ -368,7 +368,7 @@ MINLINE CompressedPatchCoord make_patch_coord(int ptex_face_index, float u, floa
{
CompressedPatchCoord patch_coord = {
ptex_face_index,
- (static_cast<uint>(u * 65535.0f) << 16) | static_cast<uint>(v * 65535.0f),
+ (uint(u * 65535.0f) << 16) | uint(v * 65535.0f),
};
return patch_coord;
}
@@ -1295,7 +1295,7 @@ static void drw_subdiv_compute_dispatch(const DRWSubdivCache *cache,
uint total_dispatch_size,
const bool has_sculpt_mask = false)
{
- const uint max_res_x = static_cast<uint>(GPU_max_work_group_count(0));
+ const uint max_res_x = uint(GPU_max_work_group_count(0));
const uint dispatch_size = get_dispatch_size(total_dispatch_size);
uint dispatch_rx = dispatch_size;
@@ -2231,13 +2231,13 @@ void DRW_subdivide_loose_geom(DRWSubdivCache *subdiv_cache, MeshBufferCache *cac
blender::Span<DRWSubdivLooseEdge> draw_subdiv_cache_get_loose_edges(const DRWSubdivCache *cache)
{
- return {cache->loose_geom.edges, static_cast<int64_t>(cache->loose_geom.edge_len)};
+ return {cache->loose_geom.edges, int64_t(cache->loose_geom.edge_len)};
}
blender::Span<DRWSubdivLooseVertex> draw_subdiv_cache_get_loose_verts(const DRWSubdivCache *cache)
{
return {cache->loose_geom.verts + cache->loose_geom.edge_len * 2,
- static_cast<int64_t>(cache->loose_geom.vert_len)};
+ int64_t(cache->loose_geom.vert_len)};
}
static OpenSubdiv_EvaluatorCache *g_evaluator_cache = nullptr;