[MPlayer-users] opengl pipeline modification
Reimar Döffinger
Reimar.Doeffinger at gmx.de
Thu Jul 1 19:02:15 CEST 2010
On Thu, Jul 01, 2010 at 05:48:50PM +0800, Bruce Mills wrote:
> I will clean up stereo opengl example, and post.
>
> Meanwhile ...
>
> The left and right frames are side by side in the frame; so, I could
> extract the two frames by giving different pointer and stride values
> (well, same stride). Yes. This is comes under what I intended to mean
> by splitting in to left and right frames. It was not physically
> seperating the frames in memory that was bothering me, but rather
> doubling the frame rate -- thus seperating them in time.
At least I am completely confused, you seem to seamlessly switch between
describing completely different and almost unrelated problems, and
I at least have no longer any idea what your real problem is.
Why do you want to double the frames? If it is for 3D, putting left and
right side into different frames really is not a good idea, you'll almost
certainly somewhen end up with left and right image swapped at some point.
For side-by-side or over-under 3D it should be enough to just change
libvo/vo_gl.c:do_render, and replace
glDrawTex(0, 0, image_width, image_height,
0, 0, image_width, image_height, ...
by something like
mpglDrawBuffer(vo_doublebuffering?GL_BACK_LEFT:GL_FRONT_LEFT);
glDrawTex(0, 0, image_width, image_height,
0, 0, image_width >> 1, image_height, ...
mpglDrawBuffer(vo_doublebuffering?GL_BACK_RIGHT:GL_FRONT_RIGHT);
glDrawTex(0, 0, image_width, image_height,
image_width >> 1, 0, image_width >> 1, image_height, ...
mpglDrawBuffer(vo_doublebuffering?GL_BACK:GL_FRONT);
OSD will of course be quite visually displeasing (as always when rendering a
2D object on top of a 3D scene).
More information about the MPlayer-users
mailing list