Ignore:
Timestamp:
Apr 1, 2012 11:01:48 AM (12 years ago)
Author:
ldelgass
Message:

formatting

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/packages/vizservers/nanovis/RpAVTranslate.h

    r2798 r2901  
    3939namespace Rappture {
    4040
    41 class AVTranslate {
     41class AVTranslate
     42{
    4243public:
    43     enum VideoFormats { MPEG1, MPEG4, THEORA, QUICKTIME };
     44    enum VideoFormats {
     45        MPEG1,
     46        MPEG4,
     47        THEORA,
     48        QUICKTIME
     49    };
     50
    4451    AVTranslate(size_t width, size_t height);
    4552
     
    4855    virtual ~AVTranslate();
    4956
    50     bool init(Outcome &status, const char *filename );
     57    bool init(Outcome &status, const char *filename);
     58
    5159    bool append(Outcome &status, uint8_t *rgbData, size_t linePad);
     60
    5261    bool done(Outcome &status);
    5362
    5463private:
    5564    bool addVideoStream(Outcome &status, CodecID codecId, AVStream **stream);
     65
    5666    bool allocPicture(Outcome &status, PixelFormat pixFmt, AVFrame **pic );
     67
    5768    bool openVideo(Outcome &status);
     69
    5870    bool writeVideoFrame(Outcome &status);
     71
    5972    bool closeVideo(Outcome &status);
     73
     74    size_t width()
     75    {
     76        return _width;
     77    }
     78
     79    void width(size_t width)
     80    {
     81        _width = width;
     82    }
     83
     84    size_t height()
     85    {
     86        return _width;
     87    }
     88
     89    void height(size_t width)
     90    {
     91        _width = width;
     92    }
     93
     94    size_t bitRate()
     95    {
     96        return _bitRate;
     97    }
     98
     99    void bitRate(size_t bitRate)
     100    {
     101        _bitRate = bitRate;
     102    }
     103
     104    float frameRate()
     105    {
     106        return _frameRate;
     107    }
     108
     109    void frameRate(size_t frameRate)
     110    {
     111        _frameRate = frameRate;
     112    }
    60113
    61114    size_t _width;
    62115    size_t _height;
    63116    size_t _bitRate;
    64     float _frameRate;           // frames/seconds
     117    float _frameRate;         ///< frames/seconds
    65118    size_t _videoOutbufSize;
    66119    uint8_t *_videoOutbuf;
    67120
    68     size_t width(void) {
    69         return _width;
    70     }
    71     void width(size_t width) {
    72         _width = width;
    73     }
    74     size_t height(void) {
    75         return _width;
    76     }
    77     void height(size_t width) {
    78         _width = width;
    79     }
    80     size_t bitRate(void) {
    81         return _bitRate;
    82     }
    83     void bitRate(size_t bitRate) {
    84         _bitRate = bitRate;
    85     }
    86     float frameRate(void) {
    87         return _frameRate;
    88     }
    89     void frameRate(size_t frameRate) {
    90         _frameRate = frameRate;
    91     }
    92121    AVOutputFormat *_fmtPtr;
    93122    AVFormatContext *_ocPtr;
     
    97126};
    98127
    99 } // namespace Rappture
     128}
    100129 
    101 #endif /* RP_AVTRANSLATE_H */
     130#endif
Note: See TracChangeset for help on using the changeset viewer.