Ignore:
Timestamp:
May 2, 2014, 1:15:12 PM (6 years ago)
Author:
ldelgass
Message:

Use avconv instead of ffmpeg if found (Debian uses the libav fork and ffmpeg
is removed in e.g. Ubuntu 14.04).

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/packages/vizservers/nanovis/FlowCmd.cpp

    r4106 r4353  
    969969}
    970970
    971 #ifdef HAVE_FFMPEG
     971#if defined(HAVE_FFMPEG) || defined(HAVE_AVCONV)
    972972
    973973/**
     
    11121112          FlowVideoSwitches *switchesPtr)
    11131113{
     1114    char cmd[BUFSIZ];
     1115#ifdef HAVE_AVCONV
     1116    /* Generate the movie from the frame images by exec-ing avconv */
     1117    /* The avconv command is
     1118     *   avconv -f image2 -i /var/tmp/xxxxx/image%d.ppm                 \
     1119     *      -f outformat -b bitrate -r framerate /var/tmp/xxxxx/movie.mpeg
     1120     */
     1121#ifndef AVCONV
     1122#  define AVCONV "/usr/bin/avconv"
     1123#endif
     1124    sprintf(cmd, "%s -f image2 -i %s/image%%d.ppm -f %s -b %d -r %f -",
     1125            AVCONV, tmpFileName, Tcl_GetString(switchesPtr->formatObjPtr),
     1126            switchesPtr->bitRate, switchesPtr->frameRate);
     1127#else
     1128    /* Generate the movie from the frame images by exec-ing ffmpeg */
     1129    /* The ffmpeg command is
     1130     *   ffmpeg -f image2 -i /var/tmp/xxxxx/image%d.ppm                 \
     1131     *      -f outformat -b bitrate -r framerate /var/tmp/xxxxx/movie.mpeg
     1132     */
    11141133#ifndef FFMPEG
    11151134#  define FFMPEG "/usr/bin/ffmpeg"
    11161135#endif
    1117     /* Generate the movie from the frame images by exec-ing ffmpeg */
    1118     /* The ffmpeg command is
    1119      *   ffmpeg -f image2 -i /var/tmp/xxxxx/image%d.ppm                 \
    1120      *      -b bitrate -f framerate /var/tmp/xxxxx/movie.mpeg
    1121      */
    1122     char cmd[BUFSIZ];
    11231136    sprintf(cmd, "%s -f image2 -i %s/image%%d.ppm -f %s -b %d -r %f -",
    11241137            FFMPEG, tmpFileName, Tcl_GetString(switchesPtr->formatObjPtr),
    11251138            switchesPtr->bitRate, switchesPtr->frameRate);
     1139#endif
    11261140    TRACE("Enter: %s", cmd);
    11271141    FILE *f;
Note: See TracChangeset for help on using the changeset viewer.