diff options
author | Niklas Haas <git@haasn.xyz> | 2017-08-12 20:07:03 +0200 |
---|---|---|
committer | Niklas Haas <git@haasn.xyz> | 2017-08-18 00:19:14 +0200 |
commit | 9ca5a2a5d839476d8a597fcc124cce41279928bc (patch) | |
tree | 6fcc70bcd5c219bdaeba3021b5a65ace014a6ce3 /video/out/opengl/ra.h | |
parent | 82093764684a4c11f9ad0d8c12bf2e34758ea0fe (diff) | |
download | mpv-9ca5a2a5d839476d8a597fcc124cce41279928bc.tar.bz2 mpv-9ca5a2a5d839476d8a597fcc124cce41279928bc.tar.xz |
vo_opengl: make blitting an explicit capability
Instead of merging it into render_dst. This is better for vulkan,
because blitting in vulkan both does not require a FBO *and* requires a
different image layout.
Also less "hacky" for OpenGL, since now the weird blit=FBO requirement
is an implementation detail of ra_gl
Diffstat (limited to 'video/out/opengl/ra.h')
-rw-r--r-- | video/out/opengl/ra.h | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/video/out/opengl/ra.h b/video/out/opengl/ra.h index d7686bce5f..f722d2e8dd 100644 --- a/video/out/opengl/ra.h +++ b/video/out/opengl/ra.h @@ -90,7 +90,8 @@ struct ra_tex_params { const struct ra_format *format; bool render_src; // must be useable as source texture in a shader bool render_dst; // must be useable as target texture in a shader - // this requires creation of a FBO + bool blit_src; // must be usable as a blit source + bool blit_dst; // must be usable as a blit destination // When used as render source texture. bool src_linear; // if false, use nearest sampling (whether this can // be true depends on ra_format.linear_filter) @@ -359,8 +360,7 @@ struct ra_fns { // preserved. The formats of the textures must be losely compatible. The // dst texture can be a swapchain framebuffer, but src can not. Only 2D // textures are supported. - // Both textures must have tex->params.render_dst==true (even src, which is - // an odd GL requirement). + // The textures must have blit_src and blit_dst set, respectively. // Rectangles with negative width/height lead to flipping, different src/dst // sizes lead to point scaling. Coordinates are always in pixels. // Optional. Only available if RA_CAP_BLIT is set (if it's not set, it must |