1r.out.mpeg(1)                 Grass User's Manual                r.out.mpeg(1)
2
3
4

NAME

6       r.out.mpeg  - Raster File Series to MPEG Conversion Program.
7

KEYWORDS

9       raster
10

SYNOPSIS

12       r.out.mpeg
13       r.out.mpeg help
14       r.out.mpeg [-qc] view1=string[,string,...]  [view2=string[,string,...]]
15       [view3=string[,string,...]]      [view4=string[,string,...]]      [out‐
16       put=string]   [qual=integer]
17
18   Flags:
19       -q  Quiet - suppress progress report
20
21       -c  Convert  on  the  fly, use less disk space (requires r.out.ppm with
22           stdout option)
23
24   Parameters:
25       view1=string[,string,...]
26           Raster file(s) for View1
27
28       view2=string[,string,...]
29           Raster file(s) for View2
30
31       view3=string[,string,...]
32           Raster file(s) for View3
33
34       view4=string[,string,...]
35           Raster file(s) for View4
36
37       output=string
38           Name for output file Default: gmovie.mpg
39
40       qual=integer
41           Quality factor (1 = highest quality, lowest  compression)  Options:
42           1-5 Default: 3
43

DESCRIPTION

45       r.out.mpeg  is a tool for combining a series of GRASS raster files into
46       a single MPEG-1 (Motion Pictures Expert Group) format file.  MPEG-1  is
47       a  "lossy"  video  compression format, so the quality of each resulting
48       frame of the animation will be much diminished from the original raster
49       image.   The  resulting  output  file  may  then  be  viewed using your
50       favorite mpeg-format viewing program.  MPEG-2 and MPEG-4  provide  much
51       better quality animations.
52
53       The  user  may  define  up  to four "views", or sub-windows, to animate
54       simultaneously.  e.g., View 1 could be rainfall, View 2 flooded  areas,
55       View  3  damage to bridges or levees, View 4 other economic damage, all
56       animated as a time series. A black border 2 pixels wide is drawn around
57       each  view. There is an arbitrary limit of 400 files per view (400 ani‐
58       mation frames).  Temporary files are created in the conversion process,
59       so lack of adequate tmp space could also limit the number of frames you
60       are able to convert.
61
62       The environment variable GMPEG_SIZE is checked for a value  to  use  as
63       the  dimension,  in  pixels,  of the longest dimension of the animation
64       image.  If GMPEG_SIZE is not set, the animation size  defaults  to  the
65       rows  &  columns in the current GRASS region, scaling if necessary to a
66       default minimum size of 200 and maximum of 500.   These  size  defaults
67       are  overridden  when using the -c flag (see below).  The resolution of
68       the current GRASS region is  maintained,  independent  of  image  size.
69       Playback  programs  have  to  decode  the compressed data "on-the-fly",
70       therefore smaller dimensioned  animations  will  provide  higher  frame
71       rates and smoother animations.
72
73       UNIX  -  style  wild cards may be used with the command line version in
74       place of a raster file name, but wild cards must be quoted.
75

Example:

77
78       r.out.mpeg view1="rain[1-9]","rain1[0-2]" view2="temp*"
79
80
81       If the number of files differs for each view, the view with the  fewest
82       files will determine the number of frames in the animation.
83
84       With  -c flag the module converts "on the fly", uses less disk space by
85       using r.out.ppm with stdout option to convert frames as needed  instead
86       of  converting all frames to ppm before encoding.  Only use when encod‐
87       ing a single  view.   Use  of  this  option  also  overrides  any  size
88       defaults, using the CURRENTLY DEFINED GRASS REGION for the output size.
89       So be careful to set region to a reasonable size prior to encoding.
90
91       A quality value of qual=1 will yield higher quality  images,  but  with
92       less compression (larger MPEG file size).  Compression ratios will vary
93       depending on the number of frames in the animation, but  an  MPEG  pro‐
94       duced  using qual=5 will usually be about 60% the size of the MPEG pro‐
95       duced using qual=1.
96

BUGS

98       MPEG images must be 16-pixel aligned for successful compression, so  if
99       the  rows  & columns of the calculated image size (scaled, with borders
100       added) are not evenly divisible by 16, a few rows/columns will  be  cut
101       off the bottom & right sides of the image. The MPEG format is optimized
102       to recognize image MOTION, so abrupt changes from one frame to  another
103       will cause a "noisy" encoding.
104

NOTES

106       This program requires the program mpeg_encode (aka ppmtompeg):
107
108       MPEG-1 Video Software Encoder
109       (Version 1.3; March 14, 1994)
110
111       Lawrence  A.  Rowe,  Kevin  Gong, Ketan Patel, and Dan Wallach Computer
112       Science Division-EECS, Univ. of Calif. at Berkeley
113
114       Available          from          Berkeley:           http://bmrc.berke
115       ley.edu/frame/research/mpeg/mpeg_encode.html
116       or  as  part  of  the netpbm package (ppmtompeg): http://netpbm.source
117       forge.net
118
119       Playback may be done with many viewers; mpeg_encode's official  compan‐
120       ion  is  mpeg_play  available  from  Berkeley at ftp://mm-ftp.cs.berke‐
121       ley.edu/pub/multimedia/mpeg/play/ or a precompiled Debian package  from
122       http://packages.debian.org/ucbmpeg-play   (includes  maintained  source
123       code).
124
125       Use of the -c flag requires the r.out.ppm GRASS module with the  stdout
126       option.
127

SEE ALSO

129       r.out.ppm
130

AUTHOR

132       Bill Brown, U.S. Army Construction Engineering Research Laboratories
133
134       Last changed: $Date: 2005/12/12 14:53:40 $
135
136       Full index
137
138
139
140GRASS 6.2.2                                                      r.out.mpeg(1)
Impressum