began implementation of footage properties
This commit is contained in:
@@ -20,9 +20,14 @@
|
||||
|
||||
#include "imagestream.h"
|
||||
|
||||
ImageStream::ImageStream()
|
||||
#include "render/colormanager.h"
|
||||
|
||||
ImageStream::ImageStream() :
|
||||
premultiplied_alpha_(false)
|
||||
{
|
||||
set_type(kImage);
|
||||
|
||||
connect(ColorManager::instance(), SIGNAL(ConfigChanged()), this, SLOT(ColorConfigChangedSlot()));
|
||||
}
|
||||
|
||||
QString ImageStream::description()
|
||||
@@ -51,3 +56,31 @@ void ImageStream::set_height(const int &height)
|
||||
{
|
||||
height_ = height;
|
||||
}
|
||||
|
||||
bool ImageStream::premultiplied_alpha()
|
||||
{
|
||||
return premultiplied_alpha_;
|
||||
}
|
||||
|
||||
void ImageStream::set_premultiplied_alpha(bool e)
|
||||
{
|
||||
premultiplied_alpha_ = e;
|
||||
}
|
||||
|
||||
const QString &ImageStream::colorspace()
|
||||
{
|
||||
return colorspace_;
|
||||
}
|
||||
|
||||
void ImageStream::set_colorspace(const QString &color)
|
||||
{
|
||||
colorspace_ = color;
|
||||
|
||||
emit ColorSpaceChanged();
|
||||
}
|
||||
|
||||
void ImageStream::ColorConfigChangedSlot()
|
||||
{
|
||||
// FIXME: Update colorspace correctly
|
||||
colorspace_.clear();
|
||||
}
|
||||
|
||||
@@ -26,7 +26,7 @@
|
||||
/**
|
||||
* @brief A Stream derivative containing video-specific information
|
||||
*/
|
||||
class ImageStream : public Stream
|
||||
class ImageStream : public Stream, public QObject
|
||||
{
|
||||
public:
|
||||
ImageStream();
|
||||
@@ -39,9 +39,23 @@ public:
|
||||
const int& height();
|
||||
void set_height(const int& height);
|
||||
|
||||
bool premultiplied_alpha();
|
||||
void set_premultiplied_alpha(bool e);
|
||||
|
||||
const QString& colorspace();
|
||||
void set_colorspace(const QString& color);
|
||||
|
||||
signals:
|
||||
void ColorSpaceChanged();
|
||||
|
||||
private:
|
||||
int width_;
|
||||
int height_;
|
||||
bool premultiplied_alpha_;
|
||||
QString colorspace_;
|
||||
|
||||
private slots:
|
||||
void ColorConfigChangedSlot();
|
||||
};
|
||||
|
||||
using ImageStreamPtr = std::shared_ptr<ImageStream>;
|
||||
|
||||
@@ -40,6 +40,7 @@ public:
|
||||
|
||||
private:
|
||||
rational frame_rate_;
|
||||
|
||||
};
|
||||
|
||||
using VideoStreamPtr = std::shared_ptr<VideoStream>;
|
||||
|
||||
Reference in New Issue
Block a user