#include <mxsPlugin.h>
Public Member Functions |
|
MSPluginEffect () | |
MSPluginEffect (MSPluginClass *pc, BOOL loading) | |
~MSPluginEffect () | |
RefTargetHandle | Clone (RemapDir &remap) |
This method is used by 3ds Max to clone an
object. |
|
EffectParamDlg * | CreateParamDialog (IRendParams *imp) |
DWORD | GBufferChannelsRequired (TimeValue t) |
void | Apply (TimeValue t, Bitmap *bm, RenderGlobalContext *gc, CheckAbortCallback *cb) |
virtual bool | SupportsBitmap (Bitmap &bitmap) |
Returns wether the given bitmap is supported
by the effect. |
|
Effect * | to_effect () |
Static Public Member Functions |
|
static RefTargetHandle | create (MSPluginClass *pc, BOOL loading) |
Public Attributes |
|
MSAutoEParamDlg * | masterFXDlg |
MSPluginEffect | ( | ) | [inline] |
{ }
MSPluginEffect | ( | MSPluginClass * | pc, |
BOOL | loading | ||
) |
~MSPluginEffect | ( | ) | [inline] |
{ DeleteAllRefsFromMe(); }
static RefTargetHandle create | ( | MSPluginClass * | pc, |
BOOL | loading | ||
) | [static] |
RefTargetHandle Clone | ( | RemapDir & | remap | ) | [virtual] |
This method is used by 3ds Max to clone an object.
class MyDerivedPlugin : public MyBasePlugin { const int MY_REFERENCE = 1; ReferenceTarget* Clone(RemapDir& remap) { ReferenceTarget* result = new MyDerivedPlugin(); BaseClone(this, result, remap); return result; } void BaseClone(ReferenceTarget* from, ReferenceTarget* to, RemapDir& remap) { if (!to || !from || from == to) return; MyBasePlugin::BaseClone(from, to, remap); to->ReplaceReference(MY_REFERENCE, remap->CloneRef(from->GetReference(MY_REFERENCE))); } };
This method should not be directly called by plug-ins. Instead, either RemapDir::CloneRef() or CloneRefHierachy() should be used to perform cloning. These methods ensure that the mapping from the original object to the clone is added to the RemapDir used for cloning, which may be used during backpatch operations
remap | - A RemapDir instance used for remapping references during a Clone. |
Reimplemented from ReferenceTarget.
Reimplemented in MSEffectXtnd.
EffectParamDlg* CreateParamDialog | ( | IRendParams * | ip | ) | [virtual] |
Reimplemented from Effect.
Reimplemented in MSEffectXtnd.
DWORD GBufferChannelsRequired | ( | TimeValue | t | ) | [virtual] |
Reimplemented from Effect.
Reimplemented in MSEffectXtnd.
void Apply | ( | TimeValue | t, |
Bitmap * | bm, | ||
RenderGlobalContext * | gc, | ||
CheckAbortCallback * | cb | ||
) | [virtual] |
Implements Effect.
Reimplemented in MSEffectXtnd.
virtual bool SupportsBitmap | ( | Bitmap & | bitmap | ) | [virtual] |
Returns wether the given bitmap is supported by the effect.
The implementation should usualy check the bitmap type (bitmap.Storage()->Type()) to determine whether it supports that type.
Usage example: An effect plugin which uses the BMM_Color_64 version of Bitmap::GetPixels() will work with 32bit floating-point bitmaps, but will clamp the colors and should therefore be considered incompatible. An effect plugin which uses the BMM_Color_fl version of Bitmap::GetPixels() can be considered as compatible with all bitmap types.
To check whether an effect supports a given bitmap, it is advised to call the static method Effect8::SupportsBitmap(Effect&, Bitmap&) instead of this. The static method handles class Effect as well as Effect8 and implements appropriate default behaviour for class Effect.
[in] | bitmap | - The bitmap to be tested for compatibility. |
Implements Effect8.
Effect* to_effect | ( | ) | [inline, virtual] |