Fix more -Wmaybe-uninitialized warnings with target=release_debug
I have no idea why those don't get triggered in target=debug builds. Fixes #37461.
This commit is contained in:
@ -424,7 +424,7 @@ Error ResourceImporterTexture::import(const String &p_source_file, const String
|
||||
String normal_map = p_options["roughness/src_normal"];
|
||||
|
||||
Ref<Image> normal_image;
|
||||
Image::RoughnessChannel roughness_channel;
|
||||
Image::RoughnessChannel roughness_channel = Image::ROUGHNESS_CHANNEL_R;
|
||||
|
||||
if (mipmaps && roughness > 1 && FileAccess::exists(normal_map)) {
|
||||
normal_image.instance();
|
||||
|
||||
@ -337,18 +337,15 @@ void MeshInstance3DEditor::_create_uv_lines(int p_layer) {
|
||||
const Vector2 *r = uv.ptr();
|
||||
|
||||
Vector<int> indices = a[Mesh::ARRAY_INDEX];
|
||||
const int *ri;
|
||||
const int *ri = NULL;
|
||||
|
||||
int ic;
|
||||
bool use_indices;
|
||||
|
||||
if (indices.size()) {
|
||||
ic = indices.size();
|
||||
ri = indices.ptr();
|
||||
use_indices = true;
|
||||
} else {
|
||||
ic = uv.size();
|
||||
use_indices = false;
|
||||
}
|
||||
|
||||
for (int j = 0; j < ic; j += 3) {
|
||||
@ -356,7 +353,7 @@ void MeshInstance3DEditor::_create_uv_lines(int p_layer) {
|
||||
for (int k = 0; k < 3; k++) {
|
||||
|
||||
MeshInstance3DEditorEdgeSort edge;
|
||||
if (use_indices) {
|
||||
if (ri) {
|
||||
edge.a = r[ri[j + k]];
|
||||
edge.b = r[ri[j + ((k + 1) % 3)]];
|
||||
} else {
|
||||
|
||||
@ -1031,7 +1031,7 @@ void Polygon2DEditor::_uv_draw() {
|
||||
uvs = node->get_polygon();
|
||||
}
|
||||
|
||||
const float *weight_r;
|
||||
const float *weight_r = NULL;
|
||||
|
||||
if (uv_edit_mode[3]->is_pressed()) {
|
||||
int bone_selected = -1;
|
||||
@ -1044,7 +1044,6 @@ void Polygon2DEditor::_uv_draw() {
|
||||
}
|
||||
|
||||
if (bone_selected != -1 && node->get_bone_weights(bone_selected).size() == uvs.size()) {
|
||||
|
||||
weight_r = node->get_bone_weights(bone_selected).ptr();
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user