comp.lang.idl-pvwave archive
Messages from Usenet group comp.lang.idl-pvwave, compiled by Paulo Penteado

Home » Public Forums » archive » Video input
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Switch to threaded view of this topic Create a new topic Submit Reply
Video input [message #80094] Sun, 06 May 2012 14:43
David Grier is currently offline  David Grier
Messages: 35
Registered: July 2010
Member
Dear Folks,

Given that IDL has no native capabilities for reading video data, I
thought it might be useful to use open-source software to enable
frame-by-frame video input without requiring users to build libraries.

The result works for me, and may be useful for others in the community.
It can be downloaded under the terms of the GPL at

http://physics.nyu.edu/grierlab/software/dgggrmplayer__defin e.pro

The movie reader is an object called DGGgrMPlayer, which uses
software from the mplayer project to read frames out of a file.
It can read any video source supported by mplayer.
This allows me to analyze video data without first having to rip
the videos to frames, thereby saving disk space and time.

To play a movie called "mymovie.avi":

IDL> movie = dgggrmplayer("mymovie.avi")
IDL> screen = image(movie.next)
IDL> while ~movie.eof do screen.putdata, movie.next

movie.next is the next video frame in the movie
movie.eof is a flag that is true at the end of the movie
The object also can cast a movie to greyscale, can flip it (/order) and
can scale it to desired dimensions.

The documentation explains basic usage and requirements.

Suggestions, bug reports and bug fixes are warmly solicited.

All the best,

David
  Switch to threaded view of this topic Create a new topic Submit Reply
Previous Topic: IDL crashes after Mac OSX 10.7.3 upgrade from 10.7.2
Next Topic: Matrix multiplication again...

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ] [ PDF ]

Current Time: Wed Oct 08 20:10:03 PDT 2025

Total time taken to generate the page: 0.04198 seconds