add: add 2 functions.
This commit is contained in:
@@ -115,6 +115,17 @@ void OliveInstance::getProjectExtent(double &xSize, double &ySize) const
|
|||||||
ySize = Current::getInstance().currentVideoParams().height();
|
ySize = Current::getInstance().currentVideoParams().height();
|
||||||
// TODO: Ensure this project does not support this.
|
// TODO: Ensure this project does not support this.
|
||||||
}
|
}
|
||||||
|
double OliveInstance::getProjectPixelAspectRatio() const
|
||||||
|
{
|
||||||
|
return Current::getInstance()
|
||||||
|
.currentVideoParams()
|
||||||
|
.pixel_aspect_ratio()
|
||||||
|
.toDouble();
|
||||||
|
}
|
||||||
|
double OliveInstance::getFrameRate() const
|
||||||
|
{
|
||||||
|
return Current::getInstance().currentVideoParams().frame_rate().toDouble();
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -45,7 +45,7 @@ public:
|
|||||||
{
|
{
|
||||||
}
|
}
|
||||||
~OliveInstance() override = default;
|
~OliveInstance() override = default;
|
||||||
virtual const std::string &getDefaultOutputFielding() const{
|
const std::string &getDefaultOutputFielding() const{
|
||||||
return kOfxImageFieldNone;
|
return kOfxImageFieldNone;
|
||||||
};
|
};
|
||||||
|
|
||||||
@@ -69,7 +69,24 @@ public:
|
|||||||
void getProjectSize(double& xSize, double& ySize) const override;
|
void getProjectSize(double& xSize, double& ySize) const override;
|
||||||
void getProjectOffset(double& xOffset, double& yOffset) const override;
|
void getProjectOffset(double& xOffset, double& yOffset) const override;
|
||||||
void getProjectExtent(double& xSize, double& ySize) const override;
|
void getProjectExtent(double& xSize, double& ySize) const override;
|
||||||
|
// The pixel aspect ratio of the current project
|
||||||
|
double getProjectPixelAspectRatio() const override;
|
||||||
|
|
||||||
|
// The duration of the effect
|
||||||
|
// This contains the duration of the plug-in effect, in frames.
|
||||||
|
double getEffectDuration() const override;
|
||||||
|
|
||||||
|
// For an instance, this is the frame rate of the project the effect is in.
|
||||||
|
double getFrameRate() const override;
|
||||||
|
|
||||||
|
/// This is called whenever a param is changed by the plugin so that
|
||||||
|
/// the recursive instanceChangedAction will be fed the correct frame
|
||||||
|
double getFrameRecursive() const override;
|
||||||
|
|
||||||
|
/// This is called whenever a param is changed by the plugin so that
|
||||||
|
/// the recursive instanceChangedAction will be fed the correct
|
||||||
|
/// renderScale
|
||||||
|
void getRenderScaleRecursive(double &x, double &y) const override;
|
||||||
|
|
||||||
private:
|
private:
|
||||||
QList<PersistentErrors> persistentErrors_;
|
QList<PersistentErrors> persistentErrors_;
|
||||||
|
|||||||
Reference in New Issue
Block a user