### Godot version

4.0.2

### System information

Windows 11, GLES3, nVidia RTX 3070, driver 528.49

### Issue description

When drawing a viewport in Compatibility (GLES3) mode, the filter mode for the CanvasItem doing the drawing is ignored and nearest is always used. This is true regardless of using SubViewportContainer or TextureRect to perform the drawing.

From https://github.com/godotengine/godot-proposals/issues/1467, the culprit appears to be here:

https://github.com/godotengine/godot/blob/677b63d7656fd0f11e224e0858fcf9479486595d/drivers/gles3/rasterizer_gles3.cpp#L302

### Steps to reproduce

- Open the minimal reproduction project.
- Run the project with Compatibility renderer.
- Viewport texture is not filtered even though it's explicitly set to use Linear.
- Set renderer to Forward+ or Mobile.
- Run the project.
- Viewport texture is filtered.

### Minimal reproduction project

[ViewportTextureFilterBug.zip](https://github.com/godotengine/godot/files/11216987/ViewportTextureFilterBug.zip)

r_gl_format = GL_RGBA;
				r_gl_type = GL_UNSIGNED_BYTE;
				r_compressed = true;
			} else {
				need_decompress = true;
			}
		} break;
		case Image::FORMAT_ASTC_4x4_HDR: {
			if (config->astc_hdr_supported) {
				r_gl_internal_format = _EXT_COMPRESSED_RGBA_ASTC_4x4_KHR;
				r_gl_format = GL_RGBA;
				r_gl_type = GL_UNSIGNED_BYTE;
				r_compressed = true;
			} else {
				need_decompress = true;
			}
		} break;
		case Image::FORMAT_ASTC_8x8: {
			if (config->astc_supported) {
				r_gl_internal_format = _EXT_COMPRESSED_RGBA_ASTC_8x8_KHR;
				r_gl_format = GL_RGBA;
				r_gl_type = GL_UNSIGNED_BYTE;
				r_compressed = true;
			} else {
				need_decompress = true;
			}
		} break;
		case Image::FORMAT_ASTC_8x8_HDR: {
			if (config->astc_hdr_supported) {
				r_gl_internal_format = _EXT_COMPRESSED_RGBA_ASTC_8x8_KHR;