Cleanup: match header/source arguments & quiet cppheck warnings

This commit is contained in:
2023-03-04 15:19:00 +11:00
parent 7cb3a79246
commit e22eb23bc2
5 changed files with 10 additions and 12 deletions

View File

@@ -288,7 +288,7 @@ static bool check_path_length(int k,
}
void psys_apply_child_modifiers(ParticleThreadContext *ctx,
struct ListBase *modifiers,
struct ListBase *UNUSED(modifiers),
ChildParticle *cpa,
ParticleTexture *ptex,
const float orco[3],
@@ -302,15 +302,13 @@ void psys_apply_child_modifiers(ParticleThreadContext *ctx,
const bool draw_col_ma = (part->draw_col == PART_DRAW_COL_MAT);
const bool use_length_check = !ELEM(part->kink, PART_KINK_SPIRAL);
ParticlePathModifier *mod;
// ParticlePathModifier *mod;
ParticleCacheKey *key;
int totkeys, k;
float max_length;
/* TODO: for the future: use true particle modifiers that work on the whole curve. */
(void)modifiers;
(void)mod;
/* TODO: for the future: use true particle modifiers that work on the whole curve.
* `modifiers` & `mod` are unused. */
if (part->kink == PART_KINK_SPIRAL) {
do_kink_spiral(

View File

@@ -1051,10 +1051,10 @@ void MOD_lineart_chain_clear_picked_flag(LineartCache *lc)
}
}
LineartElementLinkNode *lineart_find_matching_eln_obj(ListBase *elns, struct Object *obj)
LineartElementLinkNode *lineart_find_matching_eln_obj(ListBase *elns, struct Object *ob)
{
LISTBASE_FOREACH (LineartElementLinkNode *, eln, elns) {
if (eln->object_ref == obj) {
if (eln->object_ref == ob) {
return eln;
}
}

View File

@@ -73,7 +73,7 @@ void imm_draw_circle_fill_aspect_2d(
*/
void imm_draw_circle_wire_3d(uint pos, float x, float y, float radius, int nsegments);
void imm_draw_circle_wire_aspect_3d(
uint pos, float x, float y, float radius_x, float radius_y, int nsegments);
uint shdr_pos, float x, float y, float radius_x, float radius_y, int nsegments);
void imm_draw_circle_dashed_3d(uint pos, float x, float y, float radius, int nsegments);
void imm_draw_circle_fill_3d(uint pos, float x, float y, float radius, int nsegments);
void imm_draw_circle_fill_aspect_3d(

View File

@@ -383,9 +383,9 @@ void imm_draw_circle_wire_3d(uint pos, float x, float y, float radius, int nsegm
}
void imm_draw_circle_wire_aspect_3d(
uint shdr_pos, float x, float y, float radius_x, float radius_y, int nsegments)
uint pos, float x, float y, float radius_x, float radius_y, int nsegments)
{
imm_draw_circle_3D(GPU_PRIM_LINE_LOOP, shdr_pos, x, y, radius_x, radius_y, nsegments);
imm_draw_circle_3D(GPU_PRIM_LINE_LOOP, pos, x, y, radius_x, radius_y, nsegments);
}
void imm_draw_circle_dashed_3d(uint pos, float x, float y, float radius, int nsegments)

View File

@@ -236,7 +236,7 @@ struct ImBuf *IMB_thumb_load_image(const char *filepath,
else {
/* Skip images of other types if over 100MB. */
const size_t file_size = BLI_file_size(filepath);
if (file_size != -1 && file_size > THUMB_SIZE_MAX) {
if (file_size != (size_t)-1 && file_size > THUMB_SIZE_MAX) {
return NULL;
}
ibuf = IMB_loadiffname(filepath, flags, colorspace);