|
Shinya Kitaoka |
810553 |
#pragma once
|
|
Toshihiro Shimizu |
890ddd |
|
|
Toshihiro Shimizu |
890ddd |
#ifndef TMACROFX_INCLUDED
|
|
Toshihiro Shimizu |
890ddd |
#define TMACROFX_INCLUDED
|
|
Toshihiro Shimizu |
890ddd |
|
|
Toshihiro Shimizu |
890ddd |
#include "trasterfx.h"
|
|
Toshihiro Shimizu |
890ddd |
|
|
Toshihiro Shimizu |
890ddd |
#undef DVAPI
|
|
Toshihiro Shimizu |
890ddd |
#undef DVVAR
|
|
Toshihiro Shimizu |
890ddd |
#ifdef TFX_EXPORTS
|
|
Toshihiro Shimizu |
890ddd |
#define DVAPI DV_EXPORT_API
|
|
Toshihiro Shimizu |
890ddd |
#define DVVAR DV_EXPORT_VAR
|
|
Toshihiro Shimizu |
890ddd |
#else
|
|
Toshihiro Shimizu |
890ddd |
#define DVAPI DV_IMPORT_API
|
|
Toshihiro Shimizu |
890ddd |
#define DVVAR DV_IMPORT_VAR
|
|
Toshihiro Shimizu |
890ddd |
#endif
|
|
Toshihiro Shimizu |
890ddd |
|
|
|
e280ae |
#ifdef _MSC_VER
|
|
Toshihiro Shimizu |
890ddd |
#pragma warning(disable : 4251)
|
|
Toshihiro Shimizu |
890ddd |
#endif
|
|
Toshihiro Shimizu |
890ddd |
|
|
Toshihiro Shimizu |
890ddd |
//===================================================================
|
|
Toshihiro Shimizu |
890ddd |
|
|
Shinya Kitaoka |
d1f6c4 |
class DVAPI TMacroFx final : public TRasterFx {
|
|
Shinya Kitaoka |
120a6e |
FX_DECLARATION(TMacroFx)
|
|
Toshihiro Shimizu |
890ddd |
|
|
Shinya Kitaoka |
120a6e |
TRasterFxP m_root;
|
|
Shinya Kitaoka |
120a6e |
std::vector<tfxp> m_fxs;</tfxp>
|
|
Shinya Kitaoka |
120a6e |
bool m_isEditing;
|
|
Toshihiro Shimizu |
890ddd |
|
|
Shinya Kitaoka |
120a6e |
bool isaLeaf(TFx *fx) const;
|
|
Toshihiro Shimizu |
890ddd |
|
|
shun-iwasawa |
be2cc7 |
bool m_isLoading = false;
|
|
shun-iwasawa |
be2cc7 |
TMacroFx *m_waitingLinkFx = nullptr;
|
|
shun-iwasawa |
be2cc7 |
|
|
Toshihiro Shimizu |
890ddd |
public:
|
|
Shinya Kitaoka |
120a6e |
static bool analyze(const std::vector<tfxp> &fxs, TFxP &root,</tfxp>
|
|
Shinya Kitaoka |
120a6e |
std::vector<tfxp> &roots, std::vector<tfxp> &leafs);</tfxp></tfxp>
|
|
Toshihiro Shimizu |
890ddd |
|
|
Shinya Kitaoka |
120a6e |
static bool analyze(const std::vector<tfxp> &fxs);</tfxp>
|
|
Toshihiro Shimizu |
890ddd |
|
|
Shinya Kitaoka |
120a6e |
static TMacroFx *create(const std::vector<tfxp> &fxs);</tfxp>
|
|
Toshihiro Shimizu |
890ddd |
|
|
Shinya Kitaoka |
120a6e |
TMacroFx();
|
|
Shinya Kitaoka |
120a6e |
~TMacroFx();
|
|
Toshihiro Shimizu |
890ddd |
|
|
Shinya Kitaoka |
473e70 |
TFx *clone(bool recursive = true) const override;
|
|
Toshihiro Shimizu |
890ddd |
|
|
Shinya Kitaoka |
38fd86 |
bool doGetBBox(double frame, TRectD &bBox,
|
|
Shinya Kitaoka |
38fd86 |
const TRenderSettings &info) override;
|
|
Shinya Kitaoka |
38fd86 |
void doDryCompute(TRectD &rect, double frame,
|
|
Shinya Kitaoka |
38fd86 |
const TRenderSettings &info) override;
|
|
Shinya Kitaoka |
473e70 |
void doCompute(TTile &tile, double frame, const TRenderSettings &ri) override;
|
|
Toshihiro Shimizu |
890ddd |
|
|
Shinya Kitaoka |
473e70 |
TFxTimeRegion getTimeRegion() const override;
|
|
Toshihiro Shimizu |
890ddd |
|
|
Shinya Kitaoka |
473e70 |
std::string getPluginId() const override;
|
|
Toshihiro Shimizu |
890ddd |
|
|
Shinya Kitaoka |
120a6e |
void setRoot(TFx *root);
|
|
Shinya Kitaoka |
120a6e |
TFx *getRoot() const;
|
|
Shinya Kitaoka |
120a6e |
//! Returns the Fx identified by \b id.
|
|
Shinya Kitaoka |
120a6e |
//! Returns 0 if the macro does not contains an Fx with fxId equals ti \b id.
|
|
Shinya Kitaoka |
120a6e |
TFx *getFxById(const std::wstring &id) const;
|
|
Toshihiro Shimizu |
890ddd |
|
|
Shinya Kitaoka |
120a6e |
// restituisce un riferimento al vettore contenente gli effetti contenuti nel
|
|
Shinya Kitaoka |
120a6e |
// macroFx
|
|
Shinya Kitaoka |
120a6e |
const std::vector<tfxp> &getFxs() const;</tfxp>
|
|
Toshihiro Shimizu |
890ddd |
|
|
Shinya Kitaoka |
120a6e |
std::string getMacroFxType() const;
|
|
Toshihiro Shimizu |
890ddd |
|
|
Shinya Kitaoka |
473e70 |
bool canHandle(const TRenderSettings &info, double frame) override;
|
|
Toshihiro Shimizu |
890ddd |
|
|
Shinya Kitaoka |
38fd86 |
std::string getAlias(double frame,
|
|
Shinya Kitaoka |
38fd86 |
const TRenderSettings &info) const override;
|
|
Toshihiro Shimizu |
890ddd |
|
|
Shinya Kitaoka |
473e70 |
void loadData(TIStream &is) override;
|
|
Shinya Kitaoka |
473e70 |
void saveData(TOStream &os) override;
|
|
Shinya Kitaoka |
120a6e |
bool isEditing() { return m_isEditing; }
|
|
Shinya Kitaoka |
120a6e |
void editMacro(bool edit) { m_isEditing = edit; }
|
|
Toshihiro Shimizu |
890ddd |
|
|
Shinya Kitaoka |
120a6e |
void compatibilityTranslatePort(int majorVersion, int minorVersion,
|
|
Shinya Kitaoka |
473e70 |
std::string &portName) override;
|
|
Toshihiro Shimizu |
890ddd |
|
|
shun-iwasawa |
be2cc7 |
void linkParams(TFx *src) override;
|
|
shun-iwasawa |
be2cc7 |
bool isLoading() { return m_isLoading; }
|
|
shun-iwasawa |
be2cc7 |
void setWaitingLinkFx(TMacroFx *linkFx) { m_waitingLinkFx = linkFx; }
|
|
shun-iwasawa |
be2cc7 |
|
|
Toshihiro Shimizu |
890ddd |
private:
|
|
Shinya Kitaoka |
120a6e |
// non implementati
|
|
Shinya Kitaoka |
120a6e |
TMacroFx(const TMacroFx &);
|
|
Shinya Kitaoka |
120a6e |
void operator=(const TMacroFx &);
|
|
Toshihiro Shimizu |
890ddd |
};
|
|
Toshihiro Shimizu |
890ddd |
|
|
Toshihiro Shimizu |
890ddd |
//-------------------------------------------------------------------
|
|
Toshihiro Shimizu |
890ddd |
|
|
Toshihiro Shimizu |
890ddd |
#endif
|