diff --git a/include/Clip.h b/include/Clip.h new file mode 100644 index 00000000..0fe2d415 --- /dev/null +++ b/include/Clip.h @@ -0,0 +1,95 @@ +#ifndef OPENSHOT_CLIP_H +#define OPENSHOT_CLIP_H + +/** + * \file + * \brief Header file for Clip class + * \author Copyright (c) 2011 Jonathan Thomas + */ + +#include "KeyFrame.h" + +using namespace std; +using namespace openshot; + +namespace openshot { + + /** + * This enumeration determines how clips are aligned to their parent container. + */ + enum GravityType + { + TOP_LEFT, + TOP, + TOP_RIGHT, + LEFT, + CENTER, + RIGHT, + BOTTOM_LEFT, + BOTTOM, + BOTTOM_RIGHT + }; + + /** + * This enumeration determines how clips are scaled to fit their parent container. + */ + enum ScaleType + { + CROP, + FIT, + STRETCH, + NONE + }; + + /** + * This enumeration determines what parent a clip should be aligned to. + */ + enum AnchorType + { + CANVAS, + VIEWPORT + }; + + /** + * \brief This class represents a clip + * + * Each image, video, or audio file is represented on a layer as a clip. A clip has many + * properties that affect how it behaves on the timeline, such as its size, position, + * transparency, rotation, speed, volume, etc... + */ + class Clip { + private: + float position; ///