iparamm2.h

Go to the documentation of this file.
00001 /**********************************************************************
00002  *<
00003     FILE: IParamM2.h
00004 
00005     DESCRIPTION:  Parameter Maps, Edition 2 for use with ParamBlock2's
00006 
00007     CREATED BY: Rolf Berteig
00008                 John Wainwright, 2nd edition
00009 
00010     HISTORY: created 10/10/95
00011              2nd Ed. 9/8/98
00012 
00013  *> Copyright (c) 1994, All Rights Reserved.
00014  **********************************************************************/
00015 
00016 /*
00017  *   IParamMap2's are used to map and manage UI dialogs for the parameters
00018  *   in a ParamBlock2.  They work almost identically to IParamMaps except:
00019  *
00020  *    1. they only work with ParamBlock2-hosted parameters; there is no
00021  *       IParamArray equivalent.  Hopefully, the new capabilities of ParamBlock2's
00022  *       cover most of the reasons for using IParamArrays.  If not, install virtual
00023  *       paramters in the ParamBlock2 and supply accessor fns for them.
00024  *
00025  *    2. they derive all UI-related metadata from the ParamBlockDesc2 structure now
00026  *       pointed to by a ParamBlock2; there is no ParamUIDesc equivalent.
00027  *
00028  *    3. some new methods on ClassDesc can be used to automatically construct & open
00029  *       rollouts, so you may not have to create these explicitly yourself.
00030  */
00031 
00032 #pragma once
00033 
00034 #include "maxheap.h"
00035 #include "iparamb2.h"
00036 #include "render.h"
00037 #include "pbbitmap.h"
00038 
00039 // forward declarations
00040 class IParamMap2;
00041 class IRendParams;
00042 class SpecialFX;
00043 
00044 // If custom handling of controls needs to be done, ParameterMap
00045 // client can't implement one of these and set is as the ParameterMap's
00046 // user callback.
00053 #pragma warning(push)
00054 #pragma warning(disable:4100)
00055 class ParamMap2UserDlgProc: public MaxHeapOperators 
00056 {
00057     public:
00059         virtual ~ParamMap2UserDlgProc() { }
00060         virtual INT_PTR DlgProc(TimeValue t, IParamMap2 *map, HWND hWnd, UINT msg, WPARAM wParam, LPARAM lParam)=0;
00063         virtual void DeleteThis()=0;
00074         virtual void SetThing(ReferenceTarget *m) { }
00075         virtual void Update(TimeValue t) { }
00076         virtual void SetParamBlock(IParamBlock2 *pb) { }
00077         // alternative update add to R4, for extra context & influence over pmap validity interval - jbw 9.9.0
00089         virtual void Update(TimeValue t, Interval& valid, IParamMap2* pmap) { this->Update(t); }
00090 };
00091 #pragma warning(pop)
00092 
00103 class IParamMap2 : public InterfaceServer
00104 {
00105     public:
00106         // UI updating.
00109         virtual void Invalidate()=0;    // whole UI
00112         virtual void Validate()=0;      // uninvalidate whole UI
00118         virtual void Invalidate(ParamID id, int tabIndex=0)=0;  // nominated param
00123         virtual void UpdateUI(TimeValue t)=0;  // update UI directly for time t
00137         virtual void RedrawViews(TimeValue t, DWORD flag=REDRAW_NORMAL)=0;  // redraw viewport
00140         virtual Interval& Validity()=0; // access to map's validity interval
00141 
00142         // Swaps the existing parameter block with a new one and updates UI.
00146         virtual void SetParamBlock(IParamBlock2 *pb)=0;
00148         virtual MapID GetMapID()=0;
00149 
00150         // The given proc will be called _after_ default processing is done.
00151         // The callback can then apply constraints to controls.
00152         // Note that if the proc is non-NULL when the ParamMap is deleted
00153         // its DeleteThis() method will be called.
00162         virtual void SetUserDlgProc(ParamMap2UserDlgProc *proc=NULL)=0;
00166         virtual ParamMap2UserDlgProc *GetUserDlgProc()=0;
00167 
00168         // Changes a map entry to refer to a different item in the parameter block.
00173         virtual void ReplaceParam(ParamID curParam, ParamID newParam) { UNUSED_PARAM(curParam); UNUSED_PARAM(newParam); }
00174 
00175         // Access the dialog window.
00177         virtual HWND GetHWnd()=0;
00178         // Access the rollup window containing this rollout dialog
00179         virtual IRollupWindow* GetIRollup() { return NULL; }
00180 
00181         // Access the parameter block
00184         virtual IParamBlock2 *GetParamBlock()=0;
00185 
00186         // Is the dialog proc active
00189         virtual BOOL DlgActive()=0;
00190 
00191         // Access my descriptor
00194         virtual ParamBlockDesc2* GetDesc()=0;
00195 
00196         // sent to indicate dialog is going inactive so, among other things, ColorSwatches can be told
00200         virtual void ActivateDlg(BOOL onOff)=0;
00201 
00202         // sent to a Material Editor map to find the SubTex or SubMtl index corresponding to the control hw 
00208         virtual int FindSubTexFromHWND(HWND hw)=0;
00209         virtual int FindSubMtlFromHWND(HWND hw)=0;
00210 
00211         // Individual enable of param UI controls
00218         virtual void Enable(ParamID id, BOOL onOff, int tabIndex=0)=0;
00219 
00220         // Set text of param UI control
00227         virtual void SetText(ParamID id, MCHAR* txt, int tabIndex=0)=0;
00228 
00230 
00239         virtual void SetTooltip(ParamID id, bool bEnable, const MCHAR* txt, int tabIndex=0)=0;
00240 
00241         // Set range of param UI control (spinner/slider)
00249         virtual void SetRange(ParamID id, float low, float high, int tabIndex=0)=0;
00250 
00251         // show or hide assciated controls
00257         virtual void Show(ParamID id, BOOL showHide, int tabIndex=0)=0;
00258 
00259         // sent by any AutoXXParamDlg as a courtesy when it receives a SetThing()
00263         virtual void SetThing(ReferenceTarget *m)=0;
00264 };
00265 
00266 // Creates a parameter map that will handle a parameter block in a modeless
00267 // dialog where time does not change and the viewport is not redrawn.
00268 // Note that there is no need to destroy it. It executes the dialog and then
00269 // destorys itself. Returns TRUE if the user selected OK, FALSE otherwise.
00275 PB2Export BOOL CreateModalParamMap2(
00276         MapID map_id, 
00277         IParamBlock2 *pb,
00278         TimeValue t,
00279         HINSTANCE hInst,
00280         MCHAR *dlgTemplate,
00281         HWND hParent,
00282         ParamMap2UserDlgProc *proc=NULL);
00305 inline BOOL CreateModalParamMap2(
00306         IParamBlock2 *pb,
00307         TimeValue t,
00308         HINSTANCE hInst,
00309         MCHAR *dlgTemplate,
00310         HWND hParent,
00311         ParamMap2UserDlgProc *proc=NULL) { return CreateModalParamMap2(0, pb, t, hInst, dlgTemplate, hParent, proc); } 
00312 
00313 PB2Export BOOL CreateModalParamMap2(
00314         MapID map_id, 
00315         IParamBlock2 *pb,
00316         TimeValue t,
00317         HINSTANCE hInst,
00318         DLGTEMPLATE *dlgTemplate,
00319         HWND hParent,
00320         ParamMap2UserDlgProc *proc=NULL);
00341 inline BOOL CreateModalParamMap2(
00342         IParamBlock2 *pb,
00343         TimeValue t,
00344         HINSTANCE hInst,
00345         DLGTEMPLATE *dlgTemplate,
00346         HWND hParent,
00347         ParamMap2UserDlgProc *proc=NULL) { return CreateModalParamMap2(0, pb, t, hInst, dlgTemplate, hParent, proc); } 
00348 
00349 // create a child dialog of the given parent parammap (for tabbed dialogs, etc.)
00350 PB2Export IParamMap2* CreateChildModalParamMap2(
00351         MapID map_id, 
00352         IParamBlock2 *pb,
00353         HINSTANCE hInst,
00354         IParamMap2* parent,
00355         MCHAR *dlgTemplate,
00356         MCHAR *title,
00357         ParamMap2UserDlgProc *proc=NULL);
00358 inline IParamMap2* CreateChildModalParamMap2(
00359         IParamBlock2 *pb,
00360         HINSTANCE hInst,
00361         IParamMap2* parent,
00362         MCHAR *dlgTemplate,
00363         MCHAR *title,
00364         ParamMap2UserDlgProc *proc=NULL) { return CreateChildModalParamMap2(0, pb, hInst, parent, dlgTemplate, title, proc); }
00365 
00366 #ifndef NO_MODELESS_PARAMMAP
00367 PB2Export IParamMap2 *CreateModelessParamMap2(
00368         MapID map_id, 
00369         IParamBlock2 *pb,
00370         TimeValue t,
00371         HINSTANCE hInst,
00372         DLGTEMPLATE *dlgTemplate,
00373         HWND hParent,
00374         ParamMap2UserDlgProc *proc=NULL);
00375 inline IParamMap2 *CreateModelessParamMap2(
00376         IParamBlock2 *pb,
00377         TimeValue t,
00378         HINSTANCE hInst,
00379         DLGTEMPLATE *dlgTemplate,
00380         HWND hParent,
00381         ParamMap2UserDlgProc *proc=NULL) { return CreateModelessParamMap2(0, pb, t, hInst, dlgTemplate, hParent, proc); } 
00382 
00383 PB2Export IParamMap2 *CreateModelessParamMap2(
00384         MapID map_id, 
00385         IParamBlock2 *pb,
00386         TimeValue t,
00387         HINSTANCE hInst,
00388         MCHAR *dlgTemplate,
00389         HWND hParent,
00390         ParamMap2UserDlgProc *proc=NULL);
00391 inline IParamMap2 *CreateModelessParamMap2(
00392         IParamBlock2 *pb,
00393         TimeValue t,
00394         HINSTANCE hInst,
00395         MCHAR *dlgTemplate,
00396         HWND hParent,
00397         ParamMap2UserDlgProc *proc=NULL) { return CreateModelessParamMap2(0, pb, t, hInst, dlgTemplate, hParent, proc); } 
00398 
00399 PB2Export void DestroyModelessParamMap2(IParamMap2* m);
00400 #endif //NO_MODELESS_PARAMMAP
00401 
00402 PB2Export IParamMap2* CreateChildModalParamMap2(
00403         MapID map_id, 
00404         IParamBlock2 *pb,
00405         HINSTANCE hInst,
00406         IParamMap2* parent,
00407         DLGTEMPLATE *dlgTemplate,
00408         MCHAR *title,
00409         ParamMap2UserDlgProc *proc=NULL);
00410 inline IParamMap2* CreateChildModalParamMap2(
00411         IParamBlock2 *pb,
00412         HINSTANCE hInst,
00413         IParamMap2* parent,
00414         DLGTEMPLATE *dlgTemplate,
00415         MCHAR *title,
00416         ParamMap2UserDlgProc *proc=NULL) { return CreateChildModalParamMap2(0, pb, hInst, parent, dlgTemplate, title, proc); }
00417 
00423 PB2Export void DestroyChildModalParamMap2(IParamMap2 *m);
00424 
00425 // Creates a parameter map to handle the display of parameters in the command panal.
00426 // This will add a rollup page to the command panel.
00427 // DestroyCPParamMap().
00433 PB2Export IParamMap2 *CreateCPParamMap2(
00434         MapID map_id,
00435         IParamBlock2 *pb,
00436         Interface *ip,
00437         HINSTANCE hInst,
00438         MCHAR *dlgTemplate,
00439         MCHAR *title,
00440         DWORD flags,
00441         ParamMap2UserDlgProc* dlgProc=NULL,
00442         HWND hOldRollup=NULL,
00443         int category = ROLLUP_CAT_STANDARD );
00488 inline IParamMap2 *CreateCPParamMap2(
00489         IParamBlock2 *pb,
00490         Interface *ip,
00491         HINSTANCE hInst,
00492         MCHAR *dlgTemplate,
00493         MCHAR *title,
00494         DWORD flags,
00495         ParamMap2UserDlgProc* dlgProc=NULL,
00496         HWND hOldRollup=NULL,
00497         int category = ROLLUP_CAT_STANDARD ) { return CreateCPParamMap2(0, pb, ip, hInst, dlgTemplate, title, flags, dlgProc, hOldRollup, category); }
00498 
00499 PB2Export IParamMap2 *CreateCPParamMap2(
00500         MapID map_id,
00501         IParamBlock2 *pb,
00502         Interface *ip,
00503         HINSTANCE hInst,
00504         DLGTEMPLATE *dlgTemplate,
00505         MCHAR *title,
00506         DWORD flags,
00507         ParamMap2UserDlgProc* dlgProc=NULL,
00508         HWND hOldRollup=NULL,
00509         int category = ROLLUP_CAT_STANDARD );
00552 inline IParamMap2 *CreateCPParamMap2(
00553         IParamBlock2 *pb,
00554         Interface *ip,
00555         HINSTANCE hInst,
00556         DLGTEMPLATE *dlgTemplate,
00557         MCHAR *title,
00558         DWORD flags,
00559         ParamMap2UserDlgProc* dlgProc=NULL,
00560         HWND hOldRollup=NULL,
00561         int category = ROLLUP_CAT_STANDARD ) { return CreateCPParamMap2(0, pb, ip, hInst, dlgTemplate, title, flags, dlgProc, hOldRollup, category); }
00562 
00569 PB2Export void DestroyCPParamMap2(IParamMap2 *m);
00570 
00571 // create a child dialog of the given parent parammap (for tabbed dialogs, etc.)
00577 PB2Export IParamMap2 *CreateChildCPParamMap2(
00578         MapID map_id,
00579         IParamBlock2 *pb,
00580         Interface *ip,
00581         HINSTANCE hInst,
00582         IParamMap2* parent,
00583         MCHAR *dlgTemplate,
00584         MCHAR *title,
00585         ParamMap2UserDlgProc* dlgProc=NULL);
00612 inline IParamMap2 *CreateChildCPParamMap2(
00613         IParamBlock2 *pb,
00614         Interface *ip,
00615         HINSTANCE hInst,
00616         IParamMap2* parent,
00617         MCHAR *dlgTemplate,
00618         MCHAR *title,
00619         ParamMap2UserDlgProc* dlgProc=NULL) { return CreateChildCPParamMap2(0, pb, ip, hInst, parent, dlgTemplate, title, dlgProc); }
00620 
00621 PB2Export IParamMap2 *CreateChildCPParamMap2(
00622         MapID map_id,
00623         IParamBlock2 *pb,
00624         Interface *ip,
00625         HINSTANCE hInst,
00626         IParamMap2* parent,
00627         DLGTEMPLATE *dlgTemplate,
00628         MCHAR *title,
00629         ParamMap2UserDlgProc* dlgProc=NULL);
00655 inline IParamMap2 *CreateChildCPParamMap2(
00656         IParamBlock2 *pb,
00657         Interface *ip,
00658         HINSTANCE hInst,
00659         IParamMap2* parent,
00660         DLGTEMPLATE *dlgTemplate,
00661         MCHAR *title,
00662         ParamMap2UserDlgProc* dlgProc=NULL) { return CreateChildCPParamMap2(0, pb, ip, hInst, parent, dlgTemplate, title, dlgProc); }
00663 
00669 PB2Export void DestroyChildCPParamMap2(IParamMap2 *m);
00670 
00671 // Creates a parameter map to handle the display of render parameters or
00672 // atmospheric plug-in parameters.
00678 PB2Export IParamMap2 *CreateRParamMap2(
00679         MapID map_id, 
00680         IParamBlock2 *pb,
00681         IRendParams *ip,
00682         HINSTANCE hInst,
00683         MCHAR *dlgTemplate,
00684         MCHAR *title,
00685         DWORD flags,
00686         ParamMap2UserDlgProc* dlgProc=NULL,
00687         int category = ROLLUP_CAT_STANDARD);
00729 inline IParamMap2 *CreateRParamMap2(
00730         IParamBlock2 *pb,
00731         IRendParams *ip,
00732         HINSTANCE hInst,
00733         MCHAR *dlgTemplate,
00734         MCHAR *title,
00735         DWORD flags,
00736         ParamMap2UserDlgProc* dlgProc=NULL,
00737         int category = ROLLUP_CAT_STANDARD) { return CreateRParamMap2(0, pb, ip, hInst, dlgTemplate, title, flags, dlgProc, category); }
00738 
00739 PB2Export IParamMap2 *CreateRParamMap2(
00740         MapID map_id, 
00741         IParamBlock2 *pb,
00742         IRendParams *ip,
00743         HINSTANCE hInst,
00744         DLGTEMPLATE *dlgTemplate,
00745         MCHAR *title,
00746         DWORD flags,
00747         ParamMap2UserDlgProc* dlgProc=NULL,
00748         int category = ROLLUP_CAT_STANDARD);
00788 inline IParamMap2 *CreateRParamMap2(
00789         IParamBlock2 *pb,
00790         IRendParams *ip,
00791         HINSTANCE hInst,
00792         DLGTEMPLATE *dlgTemplate,
00793         MCHAR *title,
00794         DWORD flags,
00795         ParamMap2UserDlgProc* dlgProc=NULL,
00796         int category = ROLLUP_CAT_STANDARD) { return CreateRParamMap2(0, pb, ip, hInst, dlgTemplate, title, flags, dlgProc, category); }
00797 
00803 PB2Export void DestroyRParamMap2(IParamMap2 *m);
00804 
00805 // create a parameter map for render or atmos params in a child dialog window
00806 // of the given parent parammap, used typically to create tab child windows in 
00807 // a tabbed rollout
00813 PB2Export IParamMap2* CreateChildRParamMap2(
00814         MapID map_id, 
00815         IParamBlock2 *pb, 
00816         IRendParams *ip, 
00817         HINSTANCE hInst, 
00818         IParamMap2* parent,
00819         MCHAR *dlgTemplate, 
00820         MCHAR *title, 
00821         ParamMap2UserDlgProc* dlgProc=NULL);
00851 inline IParamMap2* CreateChildRParamMap2(
00852         IParamBlock2 *pb, 
00853         IRendParams *ip, 
00854         HINSTANCE hInst, 
00855         IParamMap2* parent,
00856         MCHAR *dlgTemplate, 
00857         MCHAR *title, 
00858         ParamMap2UserDlgProc* dlgProc=NULL) { return CreateChildRParamMap2(0, pb, ip, hInst, parent, dlgTemplate, title, dlgProc); }
00859 
00860 PB2Export IParamMap2* CreateChildRParamMap2(
00861         MapID map_id, 
00862         IParamBlock2 *pb, 
00863         IRendParams *ip, 
00864         HINSTANCE hInst, 
00865         IParamMap2* parent,
00866         DLGTEMPLATE *dlgTemplate, 
00867         MCHAR *title, 
00868         ParamMap2UserDlgProc* dlgProc=NULL);
00896 inline IParamMap2* CreateChildRParamMap2(
00897         IParamBlock2 *pb, 
00898         IRendParams *ip, 
00899         HINSTANCE hInst, 
00900         IParamMap2* parent,
00901         DLGTEMPLATE *dlgTemplate, 
00902         MCHAR *title, 
00903         ParamMap2UserDlgProc* dlgProc=NULL) { return CreateChildRParamMap2(0, pb, ip, hInst, parent, dlgTemplate, title, dlgProc); }
00904 
00910 PB2Export void DestroyChildRParamMap2(IParamMap2 *m);
00911 
00912 // Creates a parameter map to handle the display of texture map or
00913 // material parameters in the material editor.
00919 PB2Export IParamMap2 *CreateMParamMap2(
00920         MapID map_id, 
00921         IParamBlock2 *pb,
00922         IMtlParams *ip,
00923         HINSTANCE hInst,
00924         HWND hmedit,
00925         TexDADMgr* tdad,
00926         MtlDADMgr* mdad,
00927         MCHAR *dlgTemplate,
00928         MCHAR *title,
00929         DWORD flags,
00930         ParamMap2UserDlgProc* dlgProc=NULL,
00931         HWND hOldRollup=NULL,
00932         int category = ROLLUP_CAT_STANDARD);
00985 inline IParamMap2 *CreateMParamMap2(
00986         IParamBlock2 *pb,
00987         IMtlParams *ip,
00988         HINSTANCE hInst,
00989         HWND hmedit,
00990         TexDADMgr* tdad,
00991         MtlDADMgr* mdad,
00992         MCHAR *dlgTemplate,
00993         MCHAR *title,
00994         DWORD flags,
00995         ParamMap2UserDlgProc* dlgProc=NULL,
00996         HWND hOldRollup=NULL,
00997         int category = ROLLUP_CAT_STANDARD) { return CreateMParamMap2(0, pb, ip, hInst, hmedit, tdad, mdad, dlgTemplate, title, flags, dlgProc, hOldRollup, category); }
00998 
00999 PB2Export IParamMap2 *CreateMParamMap2(
01000         MapID map_id, 
01001         IParamBlock2 *pb,
01002         IMtlParams *ip,
01003         HINSTANCE hInst,
01004         HWND hmedit,
01005         TexDADMgr* tdad,
01006         MtlDADMgr* mdad,
01007         DLGTEMPLATE *dlgTemplate,
01008         MCHAR *title,
01009         DWORD flags,
01010         ParamMap2UserDlgProc* dlgProc=NULL,
01011         HWND hOldRollup=NULL,
01012         int category = ROLLUP_CAT_STANDARD);
01063 inline IParamMap2 *CreateMParamMap2(
01064         IParamBlock2 *pb,
01065         IMtlParams *ip,
01066         HINSTANCE hInst,
01067         HWND hmedit,
01068         TexDADMgr* tdad,
01069         MtlDADMgr* mdad,
01070         DLGTEMPLATE *dlgTemplate,
01071         MCHAR *title,
01072         DWORD flags,
01073         ParamMap2UserDlgProc* dlgProc=NULL,
01074         HWND hOldRollup=NULL,
01075         int category = ROLLUP_CAT_STANDARD) { return CreateMParamMap2(0, pb, ip, hInst, hmedit, tdad, mdad, dlgTemplate, title, flags, dlgProc, hOldRollup, category); }
01076 
01083 PB2Export void DestroyMParamMap2(IParamMap2 *m);
01084 
01085 // create a child dialog of the given parent parammap (for tabbed dialogs, etc.)
01112 PB2Export IParamMap2 *CreateChildMParamMap2(
01113         MapID map_id, 
01114         IParamBlock2 *pb, 
01115         IMtlParams *ip, 
01116         HINSTANCE hInst, 
01117         IParamMap2* parent,
01118         HWND hmedit,
01119         TexDADMgr* tdad,
01120         MtlDADMgr* mdad,
01121         MCHAR *dlgTemplate, 
01122         MCHAR *title, 
01123         ParamMap2UserDlgProc* dlgProc=NULL);
01157 inline IParamMap2 *CreateChildMParamMap2(
01158         IParamBlock2 *pb,
01159         IMtlParams *ip,
01160         HINSTANCE hInst,
01161         IParamMap2* parent,
01162         HWND hmedit,
01163         TexDADMgr* tdad,
01164         MtlDADMgr* mdad,
01165         MCHAR *dlgTemplate,
01166         MCHAR *title,
01167         ParamMap2UserDlgProc* dlgProc=NULL) { return CreateChildMParamMap2(0, pb, ip, hInst, parent, hmedit, tdad, mdad, dlgTemplate, title, dlgProc); }
01168 
01169 PB2Export IParamMap2 *CreateChildMParamMap2(
01170         MapID map_id, 
01171         IParamBlock2 *pb, 
01172         IMtlParams *ip, 
01173         HINSTANCE hInst, 
01174         IParamMap2* parent,
01175         HWND hmedit,
01176         TexDADMgr* tdad,
01177         MtlDADMgr* mdad,
01178         DLGTEMPLATE *dlgTemplate, 
01179         MCHAR *title, 
01180         ParamMap2UserDlgProc* dlgProc=NULL);
01181 inline IParamMap2 *CreateChildMParamMap2(
01182         IParamBlock2 *pb,
01183         IMtlParams *ip,
01184         HINSTANCE hInst,
01185         IParamMap2* parent,
01186         HWND hmedit,
01187         TexDADMgr* tdad,
01188         MtlDADMgr* mdad,
01189         DLGTEMPLATE *dlgTemplate,
01190         MCHAR *title,
01191         ParamMap2UserDlgProc* dlgProc=NULL) { return CreateChildMParamMap2(0, pb, ip, hInst, parent, hmedit, tdad, mdad, dlgTemplate, title, dlgProc); }
01192 
01198 PB2Export void DestroyChildMParamMap2(IParamMap2 *m);
01199 
01200 //--------------------------------------- Bayboro 02-22-02
01201 // Creates a parameter map to handle the display of parameters in a floating rollup window.
01202 // This will add a rollup page to the modal/modeless rollup window.
01203 // DestroyRWParamMap().
01204 PB2Export IParamMap2 *CreateRWParamMap2(
01205         MapID map_id,
01206         IParamBlock2 *pb,
01207         IRollupWindow* rw,
01208         HINSTANCE hInst,
01209         MCHAR *dlgTemplate,
01210         MCHAR *title,
01211         DWORD flags,
01212         ParamMap2UserDlgProc* dlgProc=NULL,
01213         BOOL bindPBlockToMap=TRUE);
01214 inline IParamMap2 *CreateRWParamMap2(
01215         IParamBlock2 *pb,
01216         IRollupWindow* rw,
01217         HINSTANCE hInst,
01218         MCHAR *dlgTemplate,
01219         MCHAR *title,
01220         DWORD flags,
01221         ParamMap2UserDlgProc* dlgProc=NULL,
01222         BOOL bindPBlockToMap=TRUE) { return CreateRWParamMap2(0, pb, rw, hInst, dlgTemplate, title, flags, dlgProc, bindPBlockToMap); }
01223 
01224 PB2Export IParamMap2 *CreateRWParamMap2(
01225         MapID map_id,
01226         IParamBlock2 *pb,
01227         IRollupWindow* rw,
01228         HINSTANCE hInst,
01229         DLGTEMPLATE *dlgTemplate,
01230         MCHAR *title,
01231         DWORD flags,
01232         ParamMap2UserDlgProc* dlgProc=NULL,
01233         BOOL bindPBlockToMap = TRUE);
01234 inline IParamMap2 *CreateRWParamMap2(
01235         IParamBlock2 *pb,
01236         IRollupWindow* rw,
01237         HINSTANCE hInst,
01238         DLGTEMPLATE *dlgTemplate,
01239         MCHAR *title,
01240         DWORD flags,
01241         ParamMap2UserDlgProc* dlgProc=NULL,
01242         BOOL bindPBlockToMap=TRUE) { return CreateRWParamMap2(0, pb, rw, hInst, dlgTemplate, title, flags, dlgProc, bindPBlockToMap); }
01243 
01244 PB2Export void DestroyRWParamMap2(IParamMap2 *m);
01245 //--------------------------------end of Bayboro 02-22-02
01246 
01247 //  Auto ParamDlg class for Material Editor auto-UI, instanced by ClassDesc2::CreateParamDlg()
01248 //  It maintains a table of secondary ParamDlgs for master ParamDlgs (eg, the one returned 
01249 //  from CreateParamDlg()) and will broadcast appropriate method calls to them
01250 //  as the master receives them
01258 class IAutoMParamDlg : public ParamDlg
01259 {
01260     public:
01263         virtual void        InvalidateUI()=0;
01270         virtual void        MtlChanged()=0;
01271         // secondary dialog list management
01273         virtual int         NumDlgs()=0;
01278         virtual void        AddDlg(ParamDlg* dlg)=0;
01283         virtual ParamDlg*   GetDlg(int i)=0;
01290         virtual void        SetDlg(int i, ParamDlg* dlg)=0;
01299         virtual void        DeleteDlg(ParamDlg* dlg)=0;
01300         // access to this dlg's parammap stuff
01303         virtual IParamMap2* GetMap()=0;
01304 };
01305 // create an AutoMParamDlg for material editor
01311 PB2Export IAutoMParamDlg* CreateAutoMParamDlg(MapID map_id, HWND hMedit, IMtlParams *i, ReferenceTarget* obj,
01312                                               IParamBlock2* pb, ClassDesc2* cd, HINSTANCE inst, 
01313                                               MCHAR* dlgTemplate, MCHAR* title, int rollFlags,
01314                                               ParamMap2UserDlgProc* dlgProc=NULL,
01315                                               HWND hOldRollup=NULL,
01316                                               int category = ROLLUP_CAT_STANDARD);
01351 inline IAutoMParamDlg* CreateAutoMParamDlg(HWND hMedit, IMtlParams *i, ReferenceTarget* obj,
01352                                               IParamBlock2* pb, ClassDesc2* cd, HINSTANCE inst, 
01353                                               MCHAR* dlgTemplate, MCHAR* title, int rollFlags,
01354                                               ParamMap2UserDlgProc* dlgProc=NULL,
01355                                               HWND hOldRollup=NULL,
01356                                               int category = ROLLUP_CAT_STANDARD)
01357                                             {
01358                                                 return CreateAutoMParamDlg(0, hMedit, i, obj, pb, cd, inst, dlgTemplate, 
01359                                                                            title, rollFlags, dlgProc, hOldRollup, category); 
01360                                             }
01361 
01362 PB2Export IAutoMParamDlg* CreateAutoMParamDlg(MapID map_id, HWND hMedit, IMtlParams *i, ReferenceTarget* obj,
01363                                               IParamBlock2* pb, ClassDesc2* cd, HINSTANCE inst, 
01364                                               DLGTEMPLATE* dlgTemplate, MCHAR* title, int rollFlags,
01365                                               ParamMap2UserDlgProc* dlgProc=NULL,
01366                                               HWND hOldRollup=NULL,
01367                                               int category = ROLLUP_CAT_STANDARD);
01368 inline IAutoMParamDlg* CreateAutoMParamDlg(HWND hMedit, IMtlParams *i, ReferenceTarget* obj,
01369                                               IParamBlock2* pb, ClassDesc2* cd, HINSTANCE inst, 
01370                                               DLGTEMPLATE* dlgTemplate, MCHAR* title, int rollFlags,
01371                                               ParamMap2UserDlgProc* dlgProc=NULL,
01372                                               HWND hOldRollup=NULL,
01373                                               int category = ROLLUP_CAT_STANDARD)
01374                                             {
01375                                                 return CreateAutoMParamDlg(0, hMedit, i, obj, pb, cd, inst, dlgTemplate, 
01376                                                                            title, rollFlags, dlgProc, hOldRollup, category); 
01377                                             }
01378 
01379 
01380 //  Auto ParamDlg class for SpecialFX auto-UI, instanced by ClassDesc2::CreateParamDialog()
01381 //  It maintains a table of secondary EffectParamDlg for master EffectParamDlg (eg, the one returned 
01382 //  from CreateParamDialog()) and will broadcast appropriate method calls to them
01383 //  as the master receives them
01391 class IAutoEParamDlg : public SFXParamDlg // mjm - 07.06.00
01392 {
01393     public:
01396         virtual void        InvalidateUI()=0;
01397         // secondary dialog list management
01399         virtual int         NumDlgs()=0;
01404         virtual void        AddDlg(SFXParamDlg* dlg)=0;
01409         virtual SFXParamDlg* GetDlg(int i)=0;
01416         virtual void        SetDlg(int i, SFXParamDlg* dlg)=0;
01425         virtual void        DeleteDlg(SFXParamDlg* dlg)=0;
01426         // access to this dlg's parammap stuff
01429         virtual IParamMap2* GetMap()=0;
01430 };
01431 // create an AutoEParamDlg for special effects
01436 PB2Export IAutoEParamDlg* CreateAutoEParamDlg(MapID map_id, IRendParams *i, SpecialFX* e, // mjm - 07.06.00
01437                                               IParamBlock2* pb, ClassDesc2* cd, HINSTANCE inst, 
01438                                               MCHAR* dlgTemplate, MCHAR* title, int rollFlags, 
01439                                               ParamMap2UserDlgProc* dlgProc=NULL,
01440                                               int category = ROLLUP_CAT_STANDARD );
01468 inline IAutoEParamDlg* CreateAutoEParamDlg(IRendParams *i, SpecialFX* e, // mjm - 07.06.00
01469                                               IParamBlock2* pb, ClassDesc2* cd, HINSTANCE inst, 
01470                                               MCHAR* dlgTemplate, MCHAR* title, int rollFlags, 
01471                                               ParamMap2UserDlgProc* dlgProc=NULL,
01472                                               int category = ROLLUP_CAT_STANDARD ) 
01473                                             { 
01474                                                 return CreateAutoEParamDlg(0, i, e, pb, cd, inst, dlgTemplate, title, rollFlags, dlgProc, category);
01475                                             }
01476 
01477 
01478 PB2Export IAutoEParamDlg* CreateAutoEParamDlg(MapID map_id, IRendParams *i, SpecialFX* e, // mjm - 07.06.00
01479                                               IParamBlock2* pb, ClassDesc2* cd, HINSTANCE inst, 
01480                                               DLGTEMPLATE* dlgTemplate, MCHAR* title, int rollFlags, 
01481                                               ParamMap2UserDlgProc* dlgProc=NULL,
01482                                               int category = ROLLUP_CAT_STANDARD );
01483 inline IAutoEParamDlg* CreateAutoEParamDlg(IRendParams *i, SpecialFX* e, // mjm - 07.06.00
01484                                               IParamBlock2* pb, ClassDesc2* cd, HINSTANCE inst, 
01485                                               DLGTEMPLATE* dlgTemplate, MCHAR* title, int rollFlags, 
01486                                               ParamMap2UserDlgProc* dlgProc=NULL,
01487                                               int category = ROLLUP_CAT_STANDARD ) 
01488                                             { 
01489                                                 return CreateAutoEParamDlg(0, i, e, pb, cd, inst, dlgTemplate, title, rollFlags, dlgProc, category);
01490                                             }
01491 
01492 
01493 
01494 
01495