*nix Documentation Project
·  Home
 +   man pages
·  Linux HOWTOs
·  FreeBSD Tips
·  *niX Forums

  man pages->IRIX man pages -> movie/mvBindWindow (3d)              



mvBindOpenGLWindow(3dm)				       mvBindOpenGLWindow(3dm)

NAME    [Toc]    [Back]

     mvBindOpenGLWindow, mvUnbindOpenGLWindow -	functions to associate movies
     with and dissociate movies	from playback windows

SYNOPSIS    [Toc]    [Back]

     #include <dmedia/movieplay.h>

     DMstatus mvBindOpenGLWindow( MVid movieid,	Display* dpy, Window win,
				  GLXContext ctxt );
     DMstatus mvUnbindOpenGLWindow( MVid movieid );

PARAMETERS    [Toc]    [Back]

	  The specified	movie instance.

     dpy  The X	display	on which the movie instance will appear.

     win  The X	window in which	the movie will appear.

     ctxt The OpenGL graphics context for the movie.

DESCRIPTION    [Toc]    [Back]

     mvBindOpenGLWindow(3dm) associates	a movie	with the window	and OpenGL
     context to	be used	for movie playback. Internally,	the Movie Playback
     Library initializes and prepares the movie	for playback.

     The Movie Playback	Library	uses the OpenGL	graphics library to display
     movie frames on screen.  Therefore, you must supply an X window that you
     have configured for OpenGL. Use the OpenGL	calls for window configuration
     (see the manual pages for glXGetconfig(3g), glXCreateContext(3g), and
     glXChooseVisual(3g)).  If your application	uses the IRIS IM toolkit
     (Silicon Graphics'	port of	the industry-standard OSF/Motif	toolkit	for
     use on Silicon Graphics systems) or ViewKit, you should use the
     GLwCreateMDrawingArea(3X),	which will create an OpenGL-based widget for

     Because mvBindOpenGLWindow(3dm) performs internal initialization, it must
     be	invoked	on a movie before you make several other playback calls	on the

     If	the specified movie contains an	audio track, mvBindOpenGLWindow(3dm)
     will attempt to open an audio port	using the Silicon Graphics Audio
     Library (AL). If the attempt to open an audio port	was successful,	the
     library will create an audio port with the	following format:


     where pid is the system process ID	which is actually using	the audio
     port, and movieid is the movie ID which contains the sound	track being

									Page 1

mvBindOpenGLWindow(3dm)				       mvBindOpenGLWindow(3dm)

     played on the port.  For more information,	see the	manual page for	the
     ALopenport(3A) call.  If the attempt to open an audio port	is
     unsuccessful (perhaps there are no	free audio ports, or the system	you
     are using does not	have audio capability),	the Movie Playback Library
     will play the image track of the movie without the	accompanying audio

     You may bind a movie to only one window at	a time.	 Once you have invoked
     mvBindOpenGLWindow(3dm) on	a movie	it will	remain bound to	the window
     until you call mvUnbindOpenGLWindowmvClose(3dm).

     A window may contain more than one	movie, i.e. you	may bind the same
     window to more than one movie.

     Before you	destroy	any window which contains movies, you should either
     Dis-associate the movies from the window using mvUnbindOpenGLWindow (or
     mvUnbindWindow) or	close the movies using mvClose(3dm).

     mvBindOpenGLWindow(3dm) and mvUnbindOpenGLWindow(3dm) return DM_SUCCESS
     upon success, and DM_FAILURE in the event of error.  If an	error occurs,
     you may call mvGetErrno(3dm) to obtain the	code describing	the error.

     If	you plan to play multiple movies at the	same time in the same
     application, you should advise the	Movie Playback Library of the maximum
     number of movies.	See mvSetNumMoviesHint(3dm).

     See mvPort(3dm) for details on how	to more	accurately control the setup
     of	the graphics screen, audio, and	video output devices.


     mvBindOpenGLWindow(3dm) may set up	the Movie Playback Library engine so
     that it will play the requested movie using hardware accelerated
     decompression.  Currently supported hardware accelerators include Cosmo
     Compress (on Indy with Indy Video), Impact	Compression (on	Indigo2	with
     Impact Video), and	Octane Compression (on Octane with Octane Video).
     Hardware accelerated decompression	is achieved on these systems using a
     memory->decompressor->video out->graphics path.  O2's builtin ICE is also
     supported,	although the data path is memory->decompressor->memory.

     If	a movie	is bound with mvBindOpenGLWindow(3dm) and the movie has	a
     single IMAGE track	in which all frames are	compatible with	the Cosmo
     Compress Hardware Accelerator, then the Movie Playback Library engine
     will attempt to play the movie using Cosmo	Compress if you	have set the
     hardware acceleration flag	for this movie.	 See
     mvSetMovieHwAcceleration(3dm) for details.	 (This feature also be turned
     on	by setting the MV_TRY_COSMO1 environment variable).  Both Impact
     Compression and Octane Compression	are supported similarly.   (For	these
     systems, the MV_TRY_IMPACTCOMP environment	variable may be	used to	turn
     on	this feature).

									Page 2

mvBindOpenGLWindow(3dm)				       mvBindOpenGLWindow(3dm)

     Movies that are successfully bound	in this	way will be displayed in a
     video window that is directly on top of the specified window passed to
     mvBindOpenGLWindow(3dm).  The movie will also play	simulataneously	on the
     video output port as well.	 The compression hardware will be kept open by
     the Movie Library until the movie is unbound or closed.  One caveat is
     that, because movies that are played through Cosmo	Compress, Impact
     Compression, and Octane Compression, are displayed	on a window on top of
     the one passed to mvBindOpenGLWindow(3dm),	any drawing to that window
     will be obscured by the video window.  Movies that	are bound and
     accelerated using a memory->decompressor->memory (e.g. on O2) do not
     suffer this caveat.

     mvBindOpenGLWindow(3dm) only supports playback in singled-buffered	OpenGL
     GL_RGBA_MODE mode windows.	 For playing movies in doubled-buffered
     windows, see mvOpenPort(3dm).

     OSF/Motif is a trademark of the Open Software Foundation, Inc.

ENVIRONMENT    [Toc]    [Back]


SEE ALSO    [Toc]    [Back]

     cl_cosmo(3dm), mvClose(3dm), mvIntro(3dm),	mvOpen(3dm),
     mvSetNumMoviesHint(3dm), mvPort(3dm), mvHwAccel(3dm).

									PPPPaaaaggggeeee 3333
[ Back ]
 Similar pages
Name OS Title
dmPMProcessClip IRIX apply special effects to movies
mvNumMoviesHint IRIX number of simultaneously-playing movies
capture IRIX record movies, images, or sounds
mvRenderToOpenGL IRIX display of visual data from movies and tracks
fxMovieRenderImage IRIX transfer images between movies and special effects
mediarecorder IRIX record movies, still images, or audio files
mvPlayEveryFrame IRIX Make movies play against time base, or without dropping frames
mvRenderAudio IRIX Multi-track, timebased access of audio data from movies.
mvPort IRIX Functions to handle generic playback ports
mvEvent IRIX Movie Playback Library event handling functions
Copyright © 2004-2005 DeniX Solutions SRL
newsletter delivery service