You've already forked godot
mirror of
https://github.com/godotengine/godot.git
synced 2025-11-07 12:30:27 +00:00
Code simplifications found by cppcheck
They are based on: - Boolean arithmetic simplifications - setting variables that are not accessed - constant variables
This commit is contained in:
@@ -796,7 +796,6 @@ void RendererCanvasRenderRD::_render_item(RD::DrawListID p_draw_list, RID p_rend
|
||||
|
||||
RenderingServerDefault::redraw_request(); // active particles means redraw request
|
||||
|
||||
bool local_coords = true;
|
||||
int dpc = particles_storage->particles_get_draw_passes(pt->particles);
|
||||
if (dpc == 0) {
|
||||
break; //nothing to draw
|
||||
@@ -818,12 +817,7 @@ void RendererCanvasRenderRD::_render_item(RD::DrawListID p_draw_list, RID p_rend
|
||||
|
||||
if (particles_storage->particles_has_collision(pt->particles) && texture_storage->render_target_is_sdf_enabled(p_render_target)) {
|
||||
//pass collision information
|
||||
Transform2D xform;
|
||||
if (local_coords) {
|
||||
xform = p_item->final_transform;
|
||||
} else {
|
||||
xform = p_canvas_transform_inverse;
|
||||
}
|
||||
Transform2D xform = p_item->final_transform;
|
||||
|
||||
RID sdf_texture = texture_storage->render_target_get_sdf_texture(p_render_target);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user