### Godot version

4.0.2 stable

### System information

issue tested on win10 with ryzen 7 and rx 6600, win11 with ryzen 7 and gtx 3050

### Issue description

When creating a screen reading post processing shader, the normal buffer functions correctly in the editor, but does not seem to be functioning as expected in debug, producing only a solid colour when run. I am unsure if this behaviour is intended, but if so, I feel it should be properly documented.

Running correctly in editor:
![image](https://user-images.githubusercontent.com/71034402/230672620-fc5e4baf-c12e-4755-b7a2-206087459307.png)

Solid colour in debug:
![image](https://user-images.githubusercontent.com/71034402/230672489-d9c29755-c2d3-4e72-9ea0-355148e916fe.png)


### Steps to reproduce

*this shader should be attached to a MeshInstance3D quadmesh*
minimal shader to reproduce:

```glsl
shader_type spatial;
render_mode unshaded, cull_disabled;

uniform sampler2D NORMAL_TEXTURE : hint_normal_roughness_texture, filter_linear_mipmap;

void vertex(){
	VERTEX *= 2.0;
	POSITION = vec4(VERTEX, 1.0);
}

void fragment(){
	ALBEDO = texture(NORMAL_TEXTURE, SCREEN_UV).rgb;
}
```

### Minimal reproduction project

N/A
copy_effects->copy_to_fb_rect(texture, color_only_framebuffer, Rect2i(), false, false, false, false, RID(), false, false, true);
				}
				keep_color = true;
			} break;
			case RS::ENV_BG_KEEP: {
				keep_color = true;
			} break;
			case RS::ENV_BG_CAMERA_FEED: {
			} break;
			default: {
			}
		}
		
		if (draw_sky || draw_sky_fog_only || environment_get_reflection_source(p_render_data->environment) == RS::ENV_REFLECTION_SOURCE_SKY || environment_get_ambient_source(p_render_data->environment) == RS::ENV_AMBIENT_SOURCE_SKY) {
			RENDER_TIMESTAMP("Setup Sky");
			RD::get_singleton()->draw_command_begin_label("Setup Sky");
			
			if (is_reflection_probe) {
				Vector3 eye_offset;
				Projection correction;
				correction.set_depth_correction(true);
				Projection projection = correction * p_render_data->scene_data->cam_projection;
				sky.setup_sky(p_render_data->environment, rb, *p_render_data->lights, p_render_data->camera_attributes, 1, &projection, &eye_offset, p_render_data->scene_data->cam_transform, screen_size, this);
			} else {
				sky.setup_sky(p_render_data->environment, rb, *p_render_data->lights, p_render_data->camera_attributes, p_render_data->scene_data->view_count, p_render_data->scene_data->view_projection, p_render_data->scene_data->view_eye_offset, p_render_data->scene_data->cam_transform, screen_size, this);
			}
			sky_energy_multiplier *= bg_energy_multiplier;
			RID sky_rid = environment_get_sky(p_render_data->environment);
			if (sky_rid.is_valid()) {
				sky.update_radiance_buffers(rb, p_render_data->environment, p_render_data->scene_data->cam_transform.origin, time, sky_energy_multiplier);