[vlc-devel] [PATCH 04/17] android: utils: add get_texture to picture_context

Alexandre Janniaux ajanni at videolabs.io
Wed Jan 13 11:07:17 UTC 2021


Abstract the storage of SurfaceTexture in the Android video context, so
that the interop doesn't have to bother on how the SurfaceTexture is
handled by the image producer. In particular, this will allow multiple
SurfaceTexture to be used in a single Android context, thus provides the
ability to use SurfaceTexture as a single buffer in each picture_t sent
from an Android producer.
---
 modules/video_output/android/utils.h | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/modules/video_output/android/utils.h b/modules/video_output/android/utils.h
index a7fc84d7a8..405f8a8b05 100644
--- a/modules/video_output/android/utils.h
+++ b/modules/video_output/android/utils.h
@@ -76,6 +76,9 @@ struct android_video_context_t
     void *dec_opaque;
     bool (*render)(struct picture_context_t *ctx);
     bool (*render_ts)(struct picture_context_t *ctx, vlc_tick_t ts);
+
+    struct vlc_asurfacetexture *
+        (*get_texture)(struct picture_context_t *ctx);
 };
 
 struct vlc_asurfacetexture
-- 
2.30.0



More information about the vlc-devel mailing list