Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorClément Foucault <foucault.clem@gmail.com>2020-07-16 03:50:55 +0300
committerClément Foucault <foucault.clem@gmail.com>2020-07-16 19:01:44 +0300
commit8084b7e6e273e16a4441100a56570627128413da (patch)
treea9a8003a640aea46302a88fceea713ebe73740c6 /source/blender/gpu/GPU_framebuffer.h
parentab19abe22315f2e2dcce989beef6dcabee528299 (diff)
Cleanup: GPU: Replace all glReadPixels by GPU equivalent
Diffstat (limited to 'source/blender/gpu/GPU_framebuffer.h')
-rw-r--r--source/blender/gpu/GPU_framebuffer.h16
1 files changed, 13 insertions, 3 deletions
diff --git a/source/blender/gpu/GPU_framebuffer.h b/source/blender/gpu/GPU_framebuffer.h
index fcbe3ef2a78..6925839256b 100644
--- a/source/blender/gpu/GPU_framebuffer.h
+++ b/source/blender/gpu/GPU_framebuffer.h
@@ -28,7 +28,7 @@
extern "C" {
#endif
-struct GPUTexture;
+#include "GPU_texture.h"
typedef struct GPUAttachment {
struct GPUTexture *tex;
@@ -176,8 +176,15 @@ void GPU_framebuffer_clear(GPUFrameBuffer *fb,
void GPU_framebuffer_multi_clear(GPUFrameBuffer *fb, const float (*clear_cols)[4]);
void GPU_framebuffer_read_depth(GPUFrameBuffer *fb, int x, int y, int w, int h, float *data);
-void GPU_framebuffer_read_color(
- GPUFrameBuffer *fb, int x, int y, int w, int h, int channels, int slot, float *data);
+void GPU_framebuffer_read_color(GPUFrameBuffer *fb,
+ int x,
+ int y,
+ int w,
+ int h,
+ int channels,
+ int slot,
+ eGPUDataFormat format,
+ void *data);
void GPU_framebuffer_blit(GPUFrameBuffer *fb_read,
int read_slot,
@@ -214,6 +221,9 @@ void GPU_clear_color(float red, float green, float blue, float alpha);
void GPU_clear_depth(float depth);
void GPU_clear(eGPUFrameBufferBits flags);
+void GPU_frontbuffer_read_pixels(
+ int x, int y, int w, int h, int channels, eGPUDataFormat format, void *data);
+
#ifdef __cplusplus
}
#endif