You must call updateTexImage() on SurfaceTexture when a new frame is
available (use an OnFrameAvailableListener to be notified.)


On Thu, Nov 29, 2012 at 11:39 AM, bob <[email protected]> wrote:

> Does anyone know how to play a video on an OpenGL texture?
>
> I tried something like this, but no dice:
>
>         int[] textures = new int[1];
>         GLES20.glGenTextures(1, textures, 0);
>         SurfaceTexture st = new SurfaceTexture(textures[0]);
>         Statics.mp.setSurface(new Surface(st));
>
>
>
> try {
>  Statics.mp.prepare();
> } catch (IllegalStateException e1) {
> // TODO Auto-generated catch block
>  e1.printStackTrace();
> } catch (IOException e1) {
> // TODO Auto-generated catch block
>  e1.printStackTrace();
> }
>         Statics.mp.start();
>
>
>  --
> You received this message because you are subscribed to the Google
> Groups "Android Developers" group.
> To post to this group, send email to [email protected]
> To unsubscribe from this group, send email to
> [email protected]
> For more options, visit this group at
> http://groups.google.com/group/android-developers?hl=en




-- 
Romain Guy
Android framework engineer
[email protected]

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Reply via email to