diff options
author | Campbell Barton <campbell@blender.org> | 2022-09-25 10:04:52 +0300 |
---|---|---|
committer | Campbell Barton <campbell@blender.org> | 2022-09-25 11:26:27 +0300 |
commit | 891949cbb47143420f4324cb60efc05ef5d70b39 (patch) | |
tree | fe70a45612ae96f9ce1f37378ef5ff035d3127f5 /source/blender/gpu/intern | |
parent | c9e35c2ced92082c86f1ecb9ecd16c6230218c7c (diff) |
Cleanup: use 'u' prefixed integer types for brevity & cast style
To use function style cast '(unsigned char)x' can't be replaced by
'unsigned char(x)'.
Diffstat (limited to 'source/blender/gpu/intern')
-rw-r--r-- | source/blender/gpu/intern/gpu_framebuffer.cc | 4 | ||||
-rw-r--r-- | source/blender/gpu/intern/gpu_node_graph.c | 2 | ||||
-rw-r--r-- | source/blender/gpu/intern/gpu_shader_builder_stubs.cc | 6 |
3 files changed, 6 insertions, 6 deletions
diff --git a/source/blender/gpu/intern/gpu_framebuffer.cc b/source/blender/gpu/intern/gpu_framebuffer.cc index 4182ce75eac..62ec6c1b7da 100644 --- a/source/blender/gpu/intern/gpu_framebuffer.cc +++ b/source/blender/gpu/intern/gpu_framebuffer.cc @@ -148,9 +148,9 @@ void FrameBuffer::load_store_config_array(const GPULoadStore *load_store_actions } } -unsigned int FrameBuffer::get_bits_per_pixel() +uint FrameBuffer::get_bits_per_pixel() { - unsigned int total_bits = 0; + uint total_bits = 0; for (GPUAttachment &attachment : attachments_) { Texture *tex = reinterpret_cast<Texture *>(attachment.tex); if (tex != nullptr) { diff --git a/source/blender/gpu/intern/gpu_node_graph.c b/source/blender/gpu/intern/gpu_node_graph.c index 3ca2399a547..f02633621db 100644 --- a/source/blender/gpu/intern/gpu_node_graph.c +++ b/source/blender/gpu/intern/gpu_node_graph.c @@ -263,7 +263,7 @@ static int uniform_attr_sort_cmp(const void *a, const void *b) return (attr_a->use_dupli && !attr_b->use_dupli); } -static unsigned int uniform_attr_list_hash(const void *key) +static uint uniform_attr_list_hash(const void *key) { const GPUUniformAttrList *attrs = key; return attrs->hash_code; diff --git a/source/blender/gpu/intern/gpu_shader_builder_stubs.cc b/source/blender/gpu/intern/gpu_shader_builder_stubs.cc index db14d7fbeb9..28456e18354 100644 --- a/source/blender/gpu/intern/gpu_shader_builder_stubs.cc +++ b/source/blender/gpu/intern/gpu_shader_builder_stubs.cc @@ -86,7 +86,7 @@ void UI_GetThemeColorBlendShade4fv(int UNUSED(colorid1), void UI_GetThemeColorBlend3ubv(int UNUSED(colorid1), int UNUSED(colorid2), float UNUSED(fac), - unsigned char UNUSED(col[3])) + uchar UNUSED(col[3])) { BLI_assert_unreachable(); } @@ -94,7 +94,7 @@ void UI_GetThemeColorBlend3ubv(int UNUSED(colorid1), void UI_GetThemeColorShadeAlpha4ubv(int UNUSED(colorid), int UNUSED(coloffset), int UNUSED(alphaoffset), - unsigned char UNUSED(col[4])) + uchar UNUSED(col[4])) { BLI_assert_unreachable(); } @@ -149,7 +149,7 @@ void BKE_paint_face_set_overlay_color_get(const int UNUSED(face_set), BLI_assert_unreachable(); } -bool paint_is_grid_face_hidden(const unsigned int *UNUSED(grid_hidden), +bool paint_is_grid_face_hidden(const uint *UNUSED(grid_hidden), int UNUSED(gridsize), int UNUSED(x), int UNUSED(y)) |