### Godot version

4.1.1 stable

### System information

Windows 10

### Issue description

this is the default size loaded on startup 1024 which seems fine but it actually have loaded the default [2048] and ignored the size in project settings
![image](https://github.com/godotengine/godot/assets/53877170/c8c71de7-468a-487f-8e6c-dba1ce0f8fa5)

changing it now to any size will break it 
[2048]
![image](https://github.com/godotengine/godot/assets/53877170/3082ff09-b7d7-41f7-8fbb-813074a54135)

[512]
![image](https://github.com/godotengine/godot/assets/53877170/5ea4620f-52b5-4d0e-a5f5-747e777cd59d)


### Steps to reproduce

change 2d shadow atlas size in project settings while using compatibility renderer. 

### Minimal reproduction project

_
CanvasShaderGLES3::ShaderVariant variant = state.canvas_instance_batches[i].shader_variant;
		uint64_t specialization = 0;
		specialization |= uint64_t(state.canvas_instance_batches[i].lights_disabled);
		specialization |= uint64_t(!GLES3::Config::get_singleton()->float_texture_supported) << 1;
		RID shader_version = data.canvas_shader_default_version;
		if (material_data) {
			if (material_data->shader_data->version.is_valid() && material_data->shader_data->valid) {
				
				material_data->bind_uniforms();
				shader_version = material_data->shader_data->version;
			}
		}
		bool success = GLES3::MaterialStorage::get_singleton()->shaders.canvas_shader.version_bind_shader(shader_version, variant, specialization);
		if (!success) {
			continue;
		}
		GLES3::CanvasShaderData::BlendMode blend_mode = state.canvas_instance_batches[i].blend_mode;
		Color blend_color = state.canvas_instance_batches[i].blend_color;
		if (last_blend_mode != blend_mode || last_blend_color != blend_color) {
			if (last_blend_mode == GLES3::CanvasShaderData::BLEND_MODE_DISABLED) {
				
				glEnable(GL_BLEND);
			} else if (blend_mode == GLES3::CanvasShaderData::BLEND_MODE_DISABLED) {
				
				glDisable(GL_BLEND);
			}
			switch (blend_mode) {
				case GLES3::CanvasShaderData::BLEND_MODE_DISABLED: {
					
				} break;