#define DCPOMATIC_PLAYER_VIDEO_H
-#include "types.h"
-#include "position.h"
-#include "dcpomatic_time.h"
#include "colour_conversion.h"
+#include "dcpomatic_time.h"
+#include "image.h"
+#include "position.h"
#include "position_image.h"
+#include "types.h"
extern "C" {
#include <libavutil/pixfmt.h>
}
std::shared_ptr<PlayerVideo> shallow_copy () const;
void set_text (PositionImage);
+ boost::optional<PositionImage> text () const {
+ return _text;
+ }
- void prepare (std::function<AVPixelFormat (AVPixelFormat)> pixel_format, VideoRange video_range, bool aligned, bool fast, bool proxy_only);
- std::shared_ptr<Image> image (std::function<AVPixelFormat (AVPixelFormat)> pixel_format, VideoRange video_range, bool aligned, bool fast) const;
- std::shared_ptr<Image> raw_image () const;
+ void prepare (std::function<AVPixelFormat (AVPixelFormat)> pixel_format, VideoRange video_range, Image::Alignment alignment, bool fast, bool proxy_only);
+ std::shared_ptr<Image> image (std::function<AVPixelFormat (AVPixelFormat)> pixel_format, VideoRange video_range, bool fast) const;
+ std::shared_ptr<const Image> raw_image () const;
- static AVPixelFormat force (AVPixelFormat, AVPixelFormat);
+ static AVPixelFormat force (AVPixelFormat);
static AVPixelFormat keep_xyz_or_rgb (AVPixelFormat);
void add_metadata (xmlpp::Node* node) const;
return _inter_size;
}
+ dcp::Size out_size () const {
+ return _out_size;
+ }
+
bool same (std::shared_ptr<const PlayerVideo> other) const;
size_t memory_used () const;
}
private:
- void make_image (std::function<AVPixelFormat (AVPixelFormat)> pixel_format, VideoRange video_range, bool aligned, bool fast) const;
+ void make_image (std::function<AVPixelFormat (AVPixelFormat)> pixel_format, VideoRange video_range, bool fast) const;
std::shared_ptr<const ImageProxy> _in;
Crop _crop;