Defines | Functions

ffmpegCommon.h File Reference

#include "libavcodec/avcodec.h"
#include "libswscale/swscale.h"
#include "libavformat/avformat.h"
#include "NDArray.h"
#include "asynDriver.h"

Go to the source code of this file.

Defines

#define __STDC_CONSTANT_MACROS
#define NEUTRAL_FRAME_SIZE   4000 * 3000 / 2

Functions

void ffmpegInitialise ()
int formatArray (NDArray *pArray, asynUser *pasynUser, AVFrame *inPicture, struct SwsContext **pCtx, AVCodecContext *c, AVFrame *scPicture)

Detailed Description

License

Author: Diamond Light Source, Copyright 2010

'ffmpegServer' is free software: you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.

'ffmpegServer' is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more details.

You should have received a copy of the GNU Lesser General Public License along with 'ffmpegServer'. If not, see http://www.gnu.org/licenses/.

Definition in file ffmpegCommon.h.


Define Documentation

#define __STDC_CONSTANT_MACROS

Definition at line 5 of file ffmpegCommon.h.

#define NEUTRAL_FRAME_SIZE   4000 * 3000 / 2

Definition at line 26 of file ffmpegCommon.h.


Function Documentation

void ffmpegInitialise (  ) 

Initialise the ffmpeg library

Definition at line 7 of file ffmpegCommon.cpp.

int formatArray ( NDArray *  pArray,
asynUser *  pasynUser,
AVFrame *  inPicture,
struct SwsContext **  pCtx,
AVCodecContext *  c,
AVFrame *  scPicture 
)

Format an NDArray as an AVFrame using the codec context c. Use inPicture to wrap the data in pArray, use swscale to convert it to scPicture using the output parameters stored in c. Special case for gray8 -> YUVx, can use the data as is and add a neutral array for the colour info.

Definition at line 33 of file ffmpegCommon.cpp.

 All Classes Files Functions Variables Defines