[GRASS-dev] OSX FFMPEG build instructions available
Hamish
hamish_nospam at yahoo.com
Sat Dec 1 00:00:12 EST 2007
Bob Covill wrote:
> On Mon, 2007-10-22, Glynn Clements wrote:
> > William Kyngesburye wrote:
> >
> > > I finally got back to FFMPEG on OSX. It went fairly smooth this
> > > time. I added build instructions to the GRASS OSX readme. My
> > > future OSX builds will now have ffmpeg support, yay!
> > >
> > > Question: what is the minimum needed in the ffmpeg libraries for
> > > GRASS? I'm thinking of disabling codecs and formats that GRASS
> > > can't use to reduce the library size (a basic universal build
> > > without debug symbols added ~6.5MB to libgrass_ogsf!). Or can
> > > GRASS use any codec available in ffmpeg?
> >
> > It only uses MPEG-1. There's a compile-time option to use XviD, but
> > that gives you a "raw" XviD stream (no AVI etc container), which isn't
> > much use.
> >
>
> I have attached a patch for gsd_img_mpeg.c (ogsf) which is based on the
> later releases of ffmpeg (output_example.c). This uses a function
> guess_format to guess the format based upon the file extension given. If
> the format is unknown it reverts to mpeg1. With this patch you can save
> to any (almost) format supported by ffmpeg. For example you can save to
> asf, avi, flv, swf, etc. To use this with nviz the auto name extension
> in panel_kanimator.tcl will have to be commented out ...
>
> # if { [string compare $fnameExt ".mpg"] != 0 &&
> # [string compare $fnameExt ".mpeg"] != 0 } then {
> # append keyanimBaseName ".mpg"
> # }
>
> The patch needs testing, etc.
>
> Let me know if you have any questions.
>
> --
> Bob
Hi,
I have applied this patch now in 6.3-cvs.
I also reinserted the USE_XVID code to force the encoder to use the Xvid codec, but I haven't tested that.
In other NVIZ news for Max res PPM output I have changed the rendering logic in 6.3.0 release branch to use the safe methods by default and only use pixmaps/pbuffers if asked for with the GRASS_GLX_PIXMAPS or GRASS_GLX_PBUFFERS enviro vars.
For me, to get it to export the image correctly in 6.3-cvs I need to do:
export GRASS_NO_GLX_PIXMAPS=TRUE
( unset GRASS_NO_GLX_PBUFFERS )
otherwise NVIZ exits with an error:
G63.cvs> nviz elevation.dem
Loading Data
Update elev null mask
Loading Data
translating colors
recalculating normals...
Create PixMap Using GLX 1.1
X Error of failed request: GLXBadContext
Major opcode of failed request: 143 (GLX)
Minor opcode of failed request: 5 (X_GLXMakeCurrent)
Serial number of failed request: 5281
Current serial number in output stream: 5281
Hamish
More information about the grass-dev
mailing list