TuttleOFX  1
InputBufferDefinitions.hpp
Go to the documentation of this file.
00001 #ifndef _TUTTLE_PLUGIN_INPUTBUFFER_DEFINITIONS_HPP_
00002 #define _TUTTLE_PLUGIN_INPUTBUFFER_DEFINITIONS_HPP_
00003 
00004 #include <tuttle/plugin/global.hpp>
00005 
00006 #include <ofxsImageEffect.h>
00007 
00008 namespace tuttle {
00009 namespace plugin {
00010 namespace inputBuffer {
00011 
00012 static const std::string kParamInputMode = "mode";
00013 static const std::string kParamInputModeBufferPointer = "bufferPointer";
00014 static const std::string kParamInputModeCallbackPointer = "callbackPointer";
00015 
00016 enum EParamInputMode
00017 {
00018         eParamInputModeBufferPointer = 0,
00019         eParamInputModeCallbackPointer = 1
00020 };
00021 
00022 static const std::string kParamInputBufferPointer = "bufferPointer";
00023 static const std::string kParamInputCallbackPointer = "callbackPointer";
00024 static const std::string kParamInputCustomData = "customData";
00025 static const std::string kParamInputCallbackDestroyCustomData = "callbackDestroyCustomData";
00026 
00027 extern "C" {
00028         typedef void* CustomDataPtr;
00029         typedef void (*CallbackInputImagePtr)( OfxTime time, CustomDataPtr customData, void** outRawdata, int* outWidth, int* outHeight, int* outRowSizeBytes );
00030         typedef void (*CallbackDestroyCustomDataPtr)( CustomDataPtr customData );
00031 }
00032 
00033 static const std::string kParamSize = "size";
00034 static const std::string kParamRowBytesSize = "rowBytesSize";
00035 static const std::string kParamPixelAspectRatio = "par";
00036 static const std::string kParamFramerate = "framerate";
00037 
00038 static const std::string kParamPixelComponents = "components";
00039 static const std::string kParamPixelComponentsAlpha = "Gray";
00040 static const std::string kParamPixelComponentsRGB = "RGB";
00041 static const std::string kParamPixelComponentsRGBA = "RGBA";
00042 
00043 /** @brief Enumerates the component types supported */
00044 enum EParamPixelComponent
00045 {
00046     eParamPixelComponentAlpha = 0,
00047     eParamPixelComponentRGB = 1,
00048     eParamPixelComponentRGBA = 2
00049 };
00050 
00051 static const std::string kParamBitDepth = "bitDepth";
00052 static const std::string kParamBitDepthUByte = "UByte";
00053 static const std::string kParamBitDepthUShort = "UShort";
00054 static const std::string kParamBitDepthFloat = "Float";
00055 
00056 /** @brief Enumerates the pixel depths supported */
00057 enum EParamBitDepth
00058 {
00059     eParamBitDepthUByte = 0,
00060     eParamBitDepthUShort = 1,
00061     eParamBitDepthFloat = 2
00062 };
00063 
00064 static const std::string kParamField = "field";
00065 static const std::string kParamFieldNone = "None";
00066 static const std::string kParamFieldBoth = "Both";
00067 static const std::string kParamFieldLower = "Lower";
00068 static const std::string kParamFieldUpper = "Upper";
00069 
00070 /** @brief Enumerates the fields present in an image */
00071 enum EParamField
00072 {
00073     eParamFieldNone = 0,   /**< @brief unfielded image */
00074     eParamFieldBoth = 1,   /**< @brief fielded image with both fields present */
00075     eParamFieldLower = 2,  /**< @brief only the spatially lower field is present */
00076     eParamFieldUpper = 3   /**< @brief only the spatially upper field is present  */
00077 };
00078 
00079 static const std::string kParamOrientation = "orientation";
00080 static const std::string kParamOrientationFromBottomToTop = "bottomToTop";
00081 static const std::string kParamOrientationFromTopToBottom = "topToBottom";
00082 
00083 /** @brief Enumerates the image memory orientations */
00084 enum EParamOrientation
00085 {
00086     eParamOrientationFromBottomToTop = 0,
00087     eParamOrientationFromTopToBottom = 1
00088 };
00089 
00090 static const std::string kParamTimeDomain = "timeDomain";
00091 
00092 }
00093 }
00094 }
00095 
00096 #endif