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

Home » Public Forums » archive » Re: Creating scientific MPEG using IDL 6
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
Re: Creating scientific MPEG using IDL 6 [message #37620] Wed, 14 January 2004 15:31
Rick Towler is currently offline  Rick Towler
Messages: 821
Registered: August 1998
Senior Member
"Pat Dandenault" wrote in message...

> I'm creating MPEGs using 24-bit JPEG images.
> The MPEG comes out grainy, even with Quality set to 100.
>
> The MPEGs need to be created programatically, so using other codecs
> from within IDL doesn't seem possible (to me, anyway).

If you feel that the built in MPEG encoder is your only option then you can
try a few things:

Writing MPEG-2 files will yield better results than MPEG-1 files. Note that
you will need the appropriate codec to play MPEG-2 files. Any software
capable of playing DVD's will work (winDVD, powerDVD, etc.). If you are on
a Windows machine simply having one of these programs installed will allow
WMP to play them. I'm sure there are programs for other platforms too.

With either format try playing with the individual "quality" parameters
instead of simply the QUALITY keyword. The most influential parameter will
be BITRATE. For MPEG-2 set the bitrate in the range of 3000-9000 kbit/s to
start. This is the DVD spec so running higher than this will potentially
yield files that are unplayable. For MPEG-1 1150 kbit/s is the VCD standard
but the DVD spec does allow for MPEG-1 files at the same 3000-9000 kbit/s.
I don't know about the playability of MPEG-1 files encoded at this bitrate.

If your animations have a lot of motion and you are getting a lot of
artifacts between your I-Frames, set your own IFRAME_GAP value. Lower
values yield higher quality files.

If file size isn't an issue you should be able to go crazy with these
parameters and generate acceptable results. If file size is an issue, then
you'll need to come up with another approach.

If you are creating these on Windows machines, Ronn Kling's IDL2AVI .dlm can
help. While you can't programmatically set the encoder, you can set it once
in an IDL session and every subsequent invocation in that session will
utilize those settings. This .dlm will open up a world of codec options.

If you are on a unix box, you could write the individual frames to disk then
spawn an external program to encode them. I used to do this with .flc
animations back when 8-bit was cool :)

-Rick
  Switch to threaded view of this topic Create a new topic Submit Reply
Previous Topic: Creating scientific MPEG using IDL 6
Next Topic: strsplit bug

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

Current Time: Sun Oct 12 12:09:16 PDT 2025

Total time taken to generate the page: 0.15904 seconds