home *** CD-ROM | disk | FTP | other *** search
/ Chip 2003 November / Chip_2003-11_cd2.bin / 3d / bodypaint / BodyPaint_3D_Demo.exe / resource / _api / OperatingSystem.h < prev    next >
C/C++ Source or Header  |  2003-07-19  |  101KB  |  2,094 lines

  1. /////////////////////////////////////////////////////////////
  2. // CINEMA SDK : CINEMA OPERATING SYSTEM                                 //
  3. /////////////////////////////////////////////////////////////
  4. // VERSION    : CINEMA 4D V8                                                       //
  5. /////////////////////////////////////////////////////////////
  6. // (c) 1989-2002 MAXON Computer GmbH, all rights reserved     //
  7. /////////////////////////////////////////////////////////////
  8.  
  9. // interface functions
  10.  
  11. #ifndef __OPERATINGSYSTEM_H
  12. #define __OPERATINGSYSTEM_H
  13.  
  14. #include "ge_math.h"
  15. #include "ge_vector.h"
  16. #include "ge_prepass.h"
  17. #include "c4d_basetime.h"
  18.  
  19. class  Atom;
  20. class  AtomArray;
  21. class  NodeData;
  22. class  GeListNode;
  23. class  GeListHead;
  24. class  RootTextureString;
  25. class  AliasTrans;
  26. class  Registry;
  27. class  CDialog;
  28. class  CUserArea;
  29. class  _GeListView;
  30. class  _SimpleListView;
  31. class  BaseTag;
  32. class  MPBaseThread;
  33. class  Semaphore;
  34. class  VariableTag;
  35. class  BaseTime;
  36. class     BaseChannel;
  37. class     BaseContainer;
  38. class     BaseDocument;
  39. class     BaseSelect;
  40. class  HyperFile;
  41. class  BaseList2D;
  42. class  BaseList4D;
  43. class  BaseObject;
  44. class  SplineObject;
  45. class  PluginShader;
  46. class  PointObject;
  47. class  PolygonObject;
  48. class  LineObject;
  49. class  PluginObject;
  50. class  BaseDraw;
  51. class  BaseDrawHelp;
  52. class  BaseView;
  53. class  BaseTrack;
  54. class  BaseLink;
  55. class  String;
  56. class  BaseBitmap;
  57. class  MemoryPool;
  58. class  BaseMaterial;
  59. class  Material;
  60. class  PluginMaterial;
  61. class  PluginVideoPost;
  62. class     RenderData;
  63. class  Render;
  64. class     TextureTag;
  65. class  MovieSaver;
  66. class  BrowseFiles;
  67. class  Parser;
  68. class  BaseFile;
  69. class  SelectionTag;
  70. class  PluginTag;
  71. class  LassoSelection;
  72. class  UVWTag;
  73. class  ObjectSafety;
  74. class  ParticleObject;
  75. class  PluginObject;
  76. class  PluginSceneHook;
  77. class  ParticleTag;
  78. class  StickTextureTag;
  79. class  Particle;
  80. class  LocalResource;
  81. class  HierarchyHelp;
  82. class  BaseKey;
  83. class  BaseSequence;
  84. class  BaseTrack;
  85. class  PLAKey;
  86. class  FolderSequence;
  87. class  SoundSequence;
  88. class  BaseSound;
  89. class     BaseThread;
  90. class  EnumerateEdges;
  91. class  PaintTexture;
  92. class  UVClass;
  93. class  EditorWindow;
  94. class  VPBuffer;
  95. class  PluginKey;
  96. class  PluginSequence;
  97. class  PluginTrack;
  98. class  GeData;
  99. class  Description;
  100. class  DescID;
  101. class  DynamicDescription;
  102. class  Description;
  103. class  DescID;
  104. class  _TextureGroup;
  105. class  BaseContainer;
  106. class  Filename;
  107. class  VideoPostData;
  108. class  BasePlugin;
  109. class  PriorityList;
  110. class  LensGlowStruct;
  111. class  CBaseFrame;
  112. class  RayFilter;
  113. struct CustomDataType;
  114. struct C4D_Painter;
  115. struct C4D_BitmapFilter;
  116. struct ParticleDetails;
  117. struct PolyInfo;
  118. struct SData;
  119. struct VolumeData;
  120. struct Ray;
  121. struct Tangent;
  122. struct UVWStruct;
  123. struct Segment;
  124. struct Polygon;
  125. struct TimingStruct;
  126. struct LVector;
  127. struct LMatrix;
  128. struct InitRenderStruct;
  129. struct RayObject;
  130. struct RayLight;
  131. struct PolyVector;
  132. struct TexData;
  133. struct VideoPostStruct;
  134. struct SurfaceData;
  135. struct PMStruct;
  136. struct VIDEOPOST;
  137. struct CHANNELSHADER;
  138. struct VOLUMESHADER;
  139. struct VP_DATA;
  140. struct MouseDownInfo;
  141. struct DrawInfo;
  142. struct RayLightCache;
  143. struct IconData;
  144. struct C4D_GraphView;
  145. struct NODEPLUGIN;
  146. struct VPFragment;
  147. struct BranchInfo;
  148. struct AnimValue;
  149. struct ObjectColorProperties;
  150. struct PixelFragment;
  151. struct ChannelData;
  152. struct CUSTOMDATATYPEPLUGIN;
  153. struct RESOURCEDATATYPEPLUGIN;
  154. struct TempUVHandle;
  155.  
  156. #define API_VERSION    8200
  157.  
  158. #define C4DPL_SHADER                         2
  159. #define C4DPL_MATERIAL                     3
  160. #define C4DPL_COFFEEMESSAGE             4
  161. #define C4DPL_COMMAND                         7
  162. #define C4DPL_OBJECT                         8
  163. #define C4DPL_TAG                                10
  164. #define C4DPL_BITMAPFILTER            12
  165. #define C4DPL_VIDEOPOST                    13
  166. #define C4DPL_TOOL                            14
  167. #define C4DPL_SCENEHOOK                    15
  168. #define C4DPL_NODE                            16
  169. #define C4DPL_LIBRARY                        18
  170. #define C4DPL_KEY                                19
  171. #define C4DPL_SEQUENCE                    20
  172. #define C4DPL_TRACK                            21
  173. #define C4DPL_BITMAPLOADER            22
  174. #define C4DPL_BITMAPSAVER                23
  175. #define C4DPL_SCENELOADER                24
  176. #define C4DPL_SCENESAVER                25
  177. #define C4DPL_COREMESSAGE                26
  178. #define C4DPL_CUSTOMGUI                    27
  179. #define C4DPL_CUSTOMDATATYPE        28
  180. #define C4DPL_RESOURCEDATATYPE    29
  181.  
  182. enum
  183. {
  184.     DIALOG_PIN = 1,                        // LONG flags
  185.     DIALOG_CHECKBOX,                    // LONG id, LONG flags, String *name
  186.     DIALOG_STATICTEXT,                // LONG id, LONG flags, String *name, LONG borderstyle
  187.     DIALOG_BUTTON,                        // LONG id, LONG flags, String *name
  188.     DIALOG_ARROWBUTTON,                // LONG id, LONG flags, LONG arrowtype
  189.     DIALOG_EDITTEXT,                    // LONG id, LONG flags
  190.     DIALOG_EDITNUMBER,                // LONG id, LONG flags
  191.     DIALOG_EDITNUMBERUD,            // LONG id, LONG flags
  192.     DIALOG_EDITSLIDER,                // LONG id, LONG flags
  193.     DIALOG_SLIDER,                        // LONG id, LONG flags
  194.     DIALOG_COLORFIELD,                // LONG id, LONG flags
  195.     DIALOG_COLORCHOOSER,            // LONG id, LONG flags
  196.     DIALOG_USERAREA,                    // LONG id, LONG flags
  197.     DIALOG_RADIOGROUP,                // LONG id, LONG flags
  198.     DIALOG_COMBOBOX,                    // LONG id, LONG flags
  199.     DIALOG_POPUPBUTTON,                // LONG id, LONG flags
  200.     DIALOG_CHILD,                            // LONG id, LONG subid, String *child);
  201.     DIALOG_FREECHILDS,                // LONG id
  202.     DIALOG_DLGGROUP,                    // LONG flags
  203.     DIALOG_SETTITLE,                    // String *name
  204.     DIALOG_GROUPSPACE,                // spacex,spacey
  205.     DIALOG_GROUPBORDER,                // borderstyle
  206.     DIALOG_GROUPBORDERSIZE,      // left, top, right, bottom
  207.     DIALOG_SETIDS,                        // left, top, right, bottom
  208.     DIALOG_LAYOUTCHANGED,            // relayout dialog
  209.     DIALOG_ACTIVATE,                    // activate gadget
  210.     DIALOG_ADDSUBMENU,                // add submenu, text
  211.     DIALOG_ENDSUBMENU,                // add submenu, text
  212.     DIALOG_ADDMENUCMD,                // add menutext, text, cmdid
  213.     DIALOG_FLUSHMENU,                    // delete all menu entries
  214.     DIALOG_INIT,                            // create new layout
  215.     DIALOG_CHECKNUMBERS,            // range check of all dialog elements
  216.     DIALOG_SETGROUP,                    // set group as insert group
  217.     DIALOG_FLUSHGROUP,                // flush all elements of this group and set insert point to this group
  218.     DIALOG_SETMENU,                        // set and display menu in manager
  219.     DIALOG_SCREEN2LOCALX,            // Screen2Local coordinates
  220.     DIALOG_SCREEN2LOCALY,            // Screen2Local coordinates
  221.     DIALOG_ADDMENUSTR,                // add menutext, text, id
  222.     DIALOG_RADIOBUTTON,                // LONG id, LONG flags, String *name
  223.     DIALOG_ADDMENUSEP,                // add menu separator
  224.     DIALOG_SEPARATOR,                    // add separator
  225.     DIALOG_MULTILINEEDITTEXT, // add multiline editfield
  226.     DIALOG_INITMENUSTR,                // enable/disable/check/uncheck menustrings
  227.     DIALOG_RADIOTEXT,
  228.     DIALOG_MENURESOURCE,            // private for painter
  229.     DIALOG_LISTVIEW,                    // LONG id, LONG flags
  230.     DIALOG_SUBDIALOG,                    // LONG id, LONG flags
  231.     DIALOG_CHECKCLOSE,                // CheckCloseMessage for dialog
  232.     DIALOG_GETTRISTATE,                // get TriState-flag of the specified gadget
  233.     DIALOG_SDK,                                // LONG id, LONG flags, String *name
  234.     DIALOG_SCROLLGROUP,                // create ScrollGroup
  235.     DIALOG_ISOPEN,                        // returns TRUE if the dialog is open
  236.     DIALOG_REMOVEGADGET,            // removes an element from the layout
  237.  
  238.     DIALOG_
  239. };
  240.  
  241. enum
  242. {
  243.     LV_GETLINECOUNT    = 1,  // request the number of lines of the listview
  244.     LV_GETCOLUMNCOUNT  = 2,  // request the number of columns of listview
  245.     LV_GETLINEHEIGHT   = 3,  // ask for the line height of the specific 'line'
  246.     LV_GETCOLUMNWIDTH  = 4,  // ask for the width of the specific 'column' in 'line'
  247.     LV_GETCOLUMTYPE    = 5,  // ask for the type of the column in 'line',
  248.         LV_COLUMN_TEXT     = 'txt',
  249.         LV_COLUMN_EDITTEXT = 'edt',
  250.         LV_COLUMN_BMP      = 'bmp',
  251.         LV_COLUMN_CHECKBOX = 'chk',
  252.         LV_COLUMN_BUTTON   = 'btn',
  253.         LV_COLUMN_USERDRAW = 'usr',
  254.         LV_COLUMN_COLORVIEW= 'clv',
  255.  
  256.     LV_GETCOLUMDATA    = 6,  // ask for the data of the column in 'line',
  257.     LV_GETLINESELECTED = 7,  // ask if the line is selected
  258.     LV_GETCOLSPACE     = 8,  // ask for space in pixels between two columns
  259.     LV_GETLINESPACE    = 9,  // ask for space in pixels between two lines
  260.     LV_GETFIXEDLAYOUT  = 10, // ask for fixed layout: FALSE...indiv. layout, TRUE...fixed layout
  261.     LV_DESTROYLISTVIEW = 11, // destroy listview and all data
  262.     LV_INITCACHE       = 12, // (internal) before call the listview
  263.  
  264.     LV_LMOUSEDOWN       = 50, // mouse down at line, col,
  265.     LV_ACTION                        = 51, // gadget command, col, data1 = msg,
  266.     LV_USERDRAW                    = 52,
  267.     LV_REDRAW                        = 53, // redraw the listview (supermessage)
  268.     LV_DATACHANGED          = 54, // layout data has changed
  269.     LV_SHOWLINE                    = 55, // scroll line into the visible area
  270.     LV_DRAGRECEIVE            = 56,    // drag receive
  271.  
  272.     LV_SIMPLE_SELECTIONCHANGED = 100, // simplelistview: selection changed
  273.     LV_SIMPLE_CHECKBOXCHANGED  = 101, // simplelistview: checkbox changed
  274.     LV_SIMPLE_FOCUSITEM        = 102, // simplelistview: set focus to item
  275.     LV_SIMPLE_BUTTONCLICK      = 103, // simplelistview: button click
  276.         LV_SIMPLE_ITEM_ID    = 1,
  277.         LV_SIMPLE_COL_ID    = 2,
  278.         LV_SIMPLE_DATA    = 3,
  279.     LV_SIMPLE_DOUBLECLICK      = 104, // doubleclick occured
  280.  
  281.     // result types
  282.     LV_RES_LONG        = 'long',
  283.     LV_RES_BITMAP      = 'bmp',
  284.     LV_RES_STRING      = 'strg',
  285.     LV_RES_VECTOR      = 'vec',
  286.     LV_RES_NIL         = 'nil',
  287.  
  288.     LV__
  289. };
  290.  
  291. // predefined calling points for tags and scenehooks
  292. #define    EXECUTION_INITIAL                            1000
  293. #define EXECUTION_ANIMATION                        2000
  294. #define EXECUTION_EXPRESSION                  3000
  295. #define EXECUTION_DYNAMICS                        4000
  296. #define EXECUTION_GENERATOR                      5000
  297.  
  298. #define EXECUTION_RESULT_OK                        0
  299. #define EXECUTION_RESULT_USERBREAK        1
  300. #define EXECUTION_RESULT_MEMORYERROR    2
  301.  
  302. enum
  303. {
  304.     DLG_OK     = 1,
  305.     DLG_CANCEL = 2,
  306.     DLG_HELP   = 4,
  307.     DLG_
  308. };
  309.  
  310. enum StringEncoding
  311. {
  312.     StXbit        = 0,
  313.     St8bit        = 1,
  314.     St7bit        = 2,
  315.     St7bithex    = 3
  316. };
  317.  
  318. #define MODELINGCOMMANDFLAG_CREATEUNDO    (1<<0)
  319.  
  320. struct ModelingCommandData
  321. {    
  322.     ModelingCommandData() { doc=NULL; op=NULL; bc=NULL; mode=0; flags=0; result1=NULL; result2=NULL; }
  323.  
  324.     BaseDocument*        doc;
  325.     BaseObject*            op;
  326.     BaseContainer*    bc;
  327.     LONG                        mode;
  328.     LONG                        flags;
  329.  
  330.     BaseObject*            result1;
  331.     void*                        result2;
  332. };
  333.  
  334. #define SETTINGS_GENERAL                            0
  335. #define SETTINGS_MODELER                            1
  336. #define SETTINGS_DOCUMENT                            2
  337. #define SETTINGS_OBJECTMANAGER                3
  338. #define SETTINGS_MATERIALMANAGER            4
  339. #define SETTINGS_COORDINATEMANAGER        5
  340. #define SETTINGS_STRUCTUREMANAGER            6
  341. #define SETTINGS_TIMELINE                            7
  342.  
  343. // GeGetSerialInfo
  344. #define SERIAL_CINEMA4D        0
  345. #define SERIAL_BODYPAINT    1
  346.  
  347. // GeGetVersionType
  348. #define VERSION_CINEMA4D    (1<<0)
  349. #define VERSION_BODYPAINT    (1<<1)
  350. #define VERSION_NET                (1<<2)
  351. #define VERSION_SERVER        (1<<3)
  352. #define VERSION_DEMO            (1<<4)
  353. #define VERSION_BENCHMARK (1<<6)
  354.  
  355. // file selector type
  356. #define FSTYPE_ANYTHING                                0
  357. #define FSTYPE_IMAGES                                    1
  358. #define FSTYPE_SCENES                                    2
  359. #define FSTYPE_COFFEE                                    3
  360.  
  361. // document IDs
  362. #define DOCUMENT_TIME                                        1000 // BASETIME
  363. #define DOCUMENT_FPS                                        1001 // LONG
  364. #define DOCUMENT_MINTIME                                1002 // BASETIME
  365. #define DOCUMENT_MAXTIME                                1003 // BASETIME
  366. #define DOCUMENT_LOOPMINTIME                        1004 // BASETIME
  367. #define DOCUMENT_LOOPMAXTIME                        1005 // BASETIME
  368. #define DOCUMENT_LOD                                        1006 // REAL
  369. #define DOCUMENT_RENDERLOD                            1007 // BOOL
  370. #define DOCUMENT_USEANIMATION                        1008 // BOOL
  371. #define DOCUMENT_USEEXPRESSIONS                    1009 // BOOL
  372. #define DOCUMENT_USEGENERATORS                    1010 // BOOL
  373. #define DOCUMENT_USEDEFORMERS                        1011 // BOOL
  374. #define DOCUMENT_PATH                                        1012 // FILENAME
  375. #define DOCUMENT_NAME                                        1013 // FILENAME
  376. #define DOCUMENT_STATEX                                    1014 // BOOL
  377. #define DOCUMENT_STATEY                                    1015 // BOOL
  378. #define DOCUMENT_STATEZ                                    1016 // BOOL
  379. #define DOCUMENT_STATEW                                    1017 // BOOL
  380. #define DOCUMENT_CHANGED                                1018 // BOOL
  381. #define DOCUMENT_MODE                                        1019 // LONG
  382. #define DOCUMENT_ACTION                                    1020 // LONG
  383.  
  384. #define DOCUMENT_KEYFRAMESELECTIONOBJECT        50004 // LINK
  385. #define DOCUMENT_MULTISELECTIONWORLD                50005 // LINK
  386. #define DOCUMENT_SELECTIONFILTER                        50006 // LONG
  387. #define DOCUMENT_DISPLAYFILTER                            50007 // LONG
  388. #define DOCUMENT_RESTRICTEDITORSELECTION        50008 // BOOL
  389. #define DOCUMENT_RESTRICTKEYFRAMERECORDING    50009 // BOOL
  390.  
  391. #define DOCUMENT_SENDBACKTO                                    50010 // LONG
  392. #define DOCUMENT_TGAFORCE                                        50011 // BOOL
  393.  
  394. #define    SELECTIONFILTERBIT_NULL                (1<<0)
  395. #define    SELECTIONFILTERBIT_POLYGON        (1<<1)
  396. #define    SELECTIONFILTERBIT_SPLINE            (1<<2)
  397. #define    SELECTIONFILTERBIT_GENERATOR    (1<<3)
  398. #define    SELECTIONFILTERBIT_HYPERNURBS (1<<4)
  399. #define    SELECTIONFILTERBIT_BONE                (1<<5)
  400. #define    SELECTIONFILTERBIT_DEFORMER        (1<<6)
  401. #define    SELECTIONFILTERBIT_CAMERA            (1<<7)
  402. #define    SELECTIONFILTERBIT_LIGHT            (1<<8)
  403. #define    SELECTIONFILTERBIT_SCENE            (1<<9)
  404. #define    SELECTIONFILTERBIT_PARTICLE        (1<<10)
  405. #define    SELECTIONFILTERBIT_OTHER            (1<<11)
  406.  
  407. // get/set mode flags
  408. #define MODE_EDITOR    0
  409. #define MODE_RENDER    1
  410. #define MODE_DEFORM    2
  411.  
  412. // maximum number of texture paths
  413. #define MAX_GLOBAL_TEXTURE_PATHS    10
  414.  
  415. // basedraw data
  416. #define BASEDRAW_DISABLETEXTURES                1000 // BOOL
  417. #define BASEDRAW_DISABLEBACKCULL                1001 // BOOL
  418. #define BASEDRAW_SHOWSAFEFRAME                    1002 // BOOL
  419. #define BASEDRAW_DISPLAYACTIVE                    1003 // LONG
  420. #define BASEDRAW_DISPLAYINACTIVE                1004 // LONG
  421. #define BASEDRAW_USEPROPERTIESACTIVE        1005 // BOOL
  422. #define BASEDRAW_USEPROPERTIESINACTIVE    1006 // BOOL
  423. #define BASEDRAW_SHOWNORMALS                        1007 // BOOL
  424. #define BASEDRAW_SHOWPATH                                1008 // BOOL
  425. #define BASEDRAW_SHOWPICTURE                        1009 // BOOL
  426. #define BASEDRAW_XRAY                                        1010 // BOOL
  427. #define BASEDRAW_PICTURE                                1011 // FILENAME
  428. #define BASEDRAW_OFFSETX                                1012 // REAL
  429. #define BASEDRAW_OFFSETY                                1013 // REAL
  430. #define BASEDRAW_SIZEX                                    1014 // REAL
  431. #define BASEDRAW_SIZEY                                    1015 // REAL
  432. #define BASEDRAW_LIGHTVECTOR                        1016 // VECTOR
  433.  
  434. // identify thread
  435. #define THREADTYPE_EDITORREDRAW        (1<<0)
  436. #define THREADTYPE_RENDEREDITOR        (1<<1)
  437. #define THREADTYPE_RENDEREXTERNAL    (1<<2)
  438.  
  439. typedef LONG CDialogMessage(CDialog *cd, CUserArea *cu, BaseContainer *msg);
  440. typedef void ListViewCallBack(LONG &res_type,void *&result,void *userdata,void *secret,LONG cmd,LONG line,LONG col,void *data1);
  441. typedef void IlluminationModel(VolumeData *sd, RayLightCache *rlc, void *dat);
  442.  
  443. typedef void ThreadMain(void *data);
  444. typedef Bool ThreadTest(void *data);
  445. typedef void ProgressHook(Real p, void *private_data);
  446.  
  447. typedef void *HierarchyAlloc(void *main);
  448. typedef void HierarchyFree(void *main, void *data);
  449. typedef void HierarchyCopyTo(void *main, void *src, void *dst);
  450. typedef Bool HierarchyDo(void *main, void *data, BaseObject *op, const Matrix &mg, Bool controlobject);
  451.  
  452. #define VPGETINFO_XRESOLUTION    0
  453. #define VPGETINFO_YRESOLUTION    1
  454. #define VPGETINFO_BITDEPTH        2
  455. #define VPGETINFO_CPP                    3
  456. #define VPGETINFO_VISIBLE            4
  457. #define VPGETINFO_LINEOFFSET    5 // offset of component in line
  458.  
  459. #define DRAWPOLYOBJECT_FORCELINES        (1<<0)
  460. #define DRAWPOLYOBJECT_NOBACKCULL        (1<<1)
  461. #define DRAWPOLYOBJECT_LOCALMATRIX    (1<<2)
  462. #define DRAWPOLYOBJECT_EDITMODE            (1<<3)
  463.  
  464. #define MSG_EMULATIONLAYER    112007
  465.  
  466. #define RENDERFLAG_EXTERNAL                    (1<<0)
  467. #define RENDERFLAG_NODOCUMENTCLONE    (1<<1)
  468. #define RENDERFLAG_SHOWERRORS                (1<<2)
  469.  
  470. #define SOUNDCOMMAND_START                0
  471. #define SOUNDCOMMAND_DRAGSTART        1
  472. #define SOUNDCOMMAND_DRAGCONTINUE    2
  473.  
  474. // CheckIsRunning
  475. #define CHECKISRUNNING_ANIMATIONRUNNING                0
  476. #define CHECKISRUNNING_VIEWDRAWING                        1
  477. #define CHECKISRUNNING_EDITORRENDERING                2    
  478. #define CHECKISRUNNING_EXTERNALRENDERING            3
  479. #define CHECKISRUNNING_PAINTERUPDATING                4
  480. #define CHECKISRUNNING_MATERIALPREVIEWRUNNING    5
  481.  
  482. struct C4D_Shader
  483. {
  484.     Real                        (*SNoise                            )(Vector p);
  485.     Real                        (*SNoiseT                            )(Vector p, Real t);
  486.     Real                        (*Noise                                )(Vector p);
  487.     Real                        (*NoiseT                            )(Vector p, Real t);
  488.     Real                        (*PNoise                            )(Vector p, Vector d);
  489.     Real                        (*PNoiseT                            )(Vector p, Real t, Vector d, Real dt);
  490.     Real                        (*Turbulence                    )(Vector p, Real oct, Bool abs);
  491.     Real                        (*TurbulenceT                    )(Vector p, Real t, Real oct, Bool abs);
  492.     Real                        (*WavyTurbulence            )(Vector p, Real t, Real oct, Real start);
  493.     void                        (*InitFbm                            )(Real *table, LONG max_octaves, Real lacunarity, Real h);
  494.     Real                        (*Fbm                                    )(Real *table, Vector p, Real oct);
  495.     Real                        (*FbmT                                )(Real *table, Vector p, Real t, Real oct);
  496.     Real                        (*RidgedMultifractal    )(Real *table, Vector p, Real oct, Real offset, Real gain);
  497.     Real                        (*CalcSpline                    )(Real x, Real *knot, LONG nknots);
  498.     Vector                    (*CalcSplineV                    )(Real x, Vector *knot, LONG nknots);
  499.  
  500.     void                        (*Illuminance1                )(VolumeData *sd, Vector *diffuse, Vector *specular, Real exponent);
  501.     void                        (*Illuminance2                )(VolumeData *sd, Vector *diffuse, Vector *specular, Real exponent, Vector *p, Vector *n, Vector *bumpn, Vector *rayv, LONG calc_shadow);
  502.     Vector                    (*Illuminance3                )(VolumeData *sd, Vector *p, LONG calc_shadow);
  503.     Bool                        (*IlluminateEx        )(VolumeData *sd, RayLight *rl, Vector *color, Vector *light_vector, const Vector &p, const Vector &n, LONG calc_shadow, LONG lhit);
  504.     void                        (*LightCalcSpecial    )(VolumeData *sd, RayLight *rl, const Vector &col, Real exponent, const Vector &rayv, Real cosc, const Vector &p, const Vector &bumpn, Vector *diffuse, Vector *specular);
  505.  
  506.     LONG                        (*GetCurrentCPU                )(VolumeData *sd);
  507.     LONG                        (*GetCPUCount                    )(VolumeData *sd);
  508.     void*                        (*GetRayData                    )(VolumeData *sd, LONG i);
  509.     Vector                    (*TraceColor                    )(VolumeData *sd, Ray *ray, Real maxdist, LONG lhit, Vector *p, Vector *n, LONG *hit);
  510.     void                      (*TraceGeometry                )(VolumeData *sd, Ray *ray, Real maxdist, LONG lhit, Vector *p, Vector *n, LONG *hit);
  511.  
  512.     RayObject*            (*GetObj                            )(VolumeData *sd, LONG i);
  513.     LONG                        (*GetObjCount                    )(VolumeData *sd);
  514.  
  515.     RayLight*                (*GetLight                        )(VolumeData *sd, LONG i);
  516.     LONG                        (*GetLightCount                )(VolumeData *sd);
  517.  
  518.     RayObject*            (*ID_to_Obj                        )(VolumeData *sd, LONG id, LONG *vind);
  519.     LONG                        (*Obj_to_ID                        )(VolumeData *sd, RayObject *op);
  520.  
  521.     void                        (*GetUVW                            )(VolumeData *sd, RayObject *op, LONG uvwind, LONG i, PolyVector *uvw);
  522.     Vector                    (*GetPointUVW                    )(VolumeData *sd, TexData *tdp, LONG lhit, const Vector &p);
  523.     void                        (*GetNormals                    )(VolumeData *sd, RayObject *op, LONG i, PolyVector *norm);
  524.     TexData*                (*GetTexData                    )(VolumeData *sd, RayObject *op, LONG i);
  525.     Vector                    (*GetNormal                        )(VolumeData *sd, RayObject *op, LONG i);
  526.     Vector                    (*GetSmoothedNormal        )(VolumeData *sd, LONG id, const Vector &p);
  527.     Bool                        (*GetRS                                )(VolumeData *sd, LONG id, const Vector &p, Real *r, Real *s);
  528.  
  529.     void                        (*GetRay                            )(VolumeData *sd, Real x, Real y, Ray *ray);
  530.     Vector                    (*ScreenToCamera            )(VolumeData *sd, const Vector &p);
  531.     Vector                    (*CameraToScreen            )(VolumeData *sd, const Vector &p);
  532.     Bool                        (*ProjectPoint                )(VolumeData *sd, TexData *tdp, LONG lhit, const Vector &p, const Vector &n, Vector *uv);
  533.  
  534.     Vector                    (*CalcHardShadow            )(VolumeData *sd, const Vector &p1, const Vector &p2, Bool transparency, LONG lhit);
  535.     Vector                    (*CalcShadow                    )(VolumeData *sd, RayLight *l, const Vector &p, const Vector &n, Bool transparency, LONG lhit);
  536.  
  537.     VolumeData*            (*AllocVolumeData            )(void);
  538.     void                        (*FreeVolumeData            )(VolumeData *sd);
  539.  
  540.     Bool                        (*Illuminate                    )(VolumeData *sd, RayLight *rl, Vector *color, Vector *light_vector, const Vector &p, const Vector &n, LONG calc_shadow, LONG lhit, Vector *xshadow);
  541.  
  542.     void                        (*StatusSetText                )(VolumeData *sd, const String *str);
  543.     void                        (*StatusSetBar                )(VolumeData *sd, Real percentage);
  544.  
  545.     TexData*                (*AllocTexData                )(void);
  546.     void                        (*FreeTexData                    )(TexData *td);
  547.     void                        (*InitTexData                    )(TexData *td);
  548.  
  549.     Vector                    (*CalcVisibleLight        )(VolumeData *sd, Ray *ray, Real maxdist, Vector *trans);
  550.     void                        (*GetDUDV                            )(VolumeData *vd, TexData *tex, const Vector &p, const Vector &n, Vector *ddu, Vector *ddv);
  551.     void                        (*GetXY                                )(VolumeData *sd, LONG *x, LONG *y, LONG *scale);
  552.  
  553.     LONG                        (*Obj_to_Num                    )(VolumeData *sd, RayObject *obj);
  554.     LONG                        (*Light_to_Num                )(VolumeData *sd, RayLight *light);
  555.  
  556.     Bool                        (*GetVideopostEx            )(VolumeData *sd, LONG i, LONG *id, VIDEOPOST **vp, VP_DATA **data);
  557.     LONG                        (*GetVideopostCountEx    )(VolumeData *sd);
  558.  
  559.     void                        (*CopyVolumeData            )(VolumeData *src, VolumeData *dst);
  560.     Vector                    (*TraceColorDirect        )(VolumeData *sd, Ray *ray, Real maxdist, LONG raydepth, LONG raybits, LONG lhit, LVector *p, LVector *n, LONG *hit);
  561.  
  562.     Bool                        (*VPAllocateBuffer        )(Render *render, LONG id, LONG subid, LONG bitdepth, Bool visible);
  563.     VPBuffer*                (*VPGetBuffer                    )(Render *render, LONG id, LONG subid);
  564.     LONG                        (*VPGetInfo                        )(VPBuffer *buf, LONG type);
  565.     Bool                        (*VPGetLine                        )(VPBuffer *buf, LONG x, LONG y, LONG cnt, void *data, LONG bitdepth, Bool dithering);
  566.     Bool                        (*VPSetLine                        )(VPBuffer *buf, LONG x, LONG y, LONG cnt, void *data, LONG bitdepth, Bool dithering);
  567.     LONG                        (*VPSaveEx                        )(VPBuffer *buf, const Filename *name, LONG format, BaseContainer *data, LONG savebits);
  568.  
  569.     void                        (*OutOfMemory                    )(VolumeData *sd);
  570.     void                      (*GetSurfaceData            )(VolumeData *sd, SurfaceData *cd, Bool calc_illum, Bool calc_shadow, Bool calc_refl, Bool calc_trans, Ray *ray, const Vector &p, const Vector &n, LONG lhit);
  571.     Real                        (*GetLightFalloff            )(LONG falloff, Real inner, Real outer, Real dist);
  572.  
  573.     Bool                        (*TestBreak                        )(VolumeData *sd);
  574.  
  575.     void                        (*VPRegisterBufferEx    )(Render *render, LONG id, LONG bitdepth, LONG cpp, const String *name);
  576.     void                        (*VPUpdateLineEx            )(Render *render, LONG line);
  577.     void                        (*VPUpdateScreenEx        )(Render *render);
  578.     void                        (*VPGetRenderData            )(Render *render, BaseContainer *bc);
  579.     void                        (*VPSetRenderData            )(Render *render, const BaseContainer *bc);
  580.  
  581.     void                        (*Illuminance                    )(VolumeData *sd, Vector *diffuse, Vector *specular, IlluminationModel *model, void *data);
  582.  
  583.     PluginVideoPost*(*FindVideoPost                )(VolumeData *sd, LONG i, Bool index);
  584.     VPFragment**        (*VPGetFragments            )(VolumeData *sd, LONG x, LONG y, LONG cnt, LONG flags);
  585.     Bool                        (*AddLensGlow                    )(VolumeData *sd, LensGlowStruct *lgs, Vector *lgs_pos, LONG lgs_cnt, Real intensity);
  586.     
  587.     void                        (*VPUpdateScreen            )(Render *render);
  588.  
  589.     RayLight*                (*AllocRayLight                )(BaseObject *op);
  590.     void                        (*FreeRayLight                )(RayLight *lgt);
  591.  
  592.     RayFilter*            (*RfAllocRayFilter        )(LONG xres, LONG yres, LONG components, LONG left, LONG right, LONG type, Real softness, Bool dithering);
  593.     void                        (*RfFreeRayFilter            )(RayFilter *filter);
  594.     void                        (*RfAddLine                        )(RayFilter *filter, Real *line, LONG y);
  595.     void                        (*RfEvaluateLine            )(RayFilter *filter, Bool display, LONG y, LONG xcnt, BaseBitmap *bmp, LONG alpha);
  596.     LONG                        (*RfGetYRadius                )(RayFilter *filter);
  597.     void                        (*RfSetRange                    )(RayFilter *filter, LONG t_top, LONG t_bottom);
  598.     
  599.     UWORD*                    (*GetFragmentMask            )(VolumeData *sd);
  600.     LONG                        (*TranslateObjIndex        )(VolumeData *sd, LONG index, Bool old_to_new);
  601.     Bool                        (*TranslatePolygon        )(VolumeData *sd, RayObject *op, LONG local_index, Vector *previous_points);
  602.     Bool                        (*SampleLensFX                )(VolumeData *sd, VPBuffer *rgba, VPBuffer *fx, BaseThread *bt);
  603.     LONG                        (*VPAllocateBufferFX    )(Render *render, LONG id, const String &name, LONG bitdepth, Bool visible);
  604.  
  605.     VolumeData*            (*VPGetInitialVolumeData)(Render *render, LONG cpu);
  606.     Bool                        (*SetRayTolerance            )(VolumeData *sd, Real value);
  607. };
  608.  
  609. struct C4D_HyperFile
  610. {
  611.     Bool                        (*WriteChar                        )(HyperFile *hf, CHAR  v);
  612.     Bool                        (*WriteUChar                    )(HyperFile *hf, UCHAR v);
  613.     Bool                        (*WriteWord                        )(HyperFile *hf, WORD  v);
  614.     Bool                        (*WriteUWord                    )(HyperFile *hf, UWORD v);
  615.     Bool                        (*WriteLong                        )(HyperFile *hf, LONG  v);
  616.     Bool                        (*WriteULong                    )(HyperFile *hf, ULONG v);
  617.     Bool                        (*WriteReal                        )(HyperFile *hf, Real  v);
  618.     Bool                        (*WriteLReal                    )(HyperFile *hf, LReal v);
  619.     Bool                        (*WriteBool                        )(HyperFile *hf, Bool  v);
  620.     Bool                        (*WriteTime                        )(HyperFile *hf, const BaseTime &v);
  621.     Bool                        (*WriteVector                    )(HyperFile *hf, const Vector &v);
  622.     Bool                        (*WriteLVector                )(HyperFile *hf, const LVector &v);
  623.     Bool                        (*WriteMatrix                    )(HyperFile *hf, const Matrix &v);
  624.     Bool                        (*WriteLMatrix                )(HyperFile *hf, const LMatrix &v);
  625.     Bool                        (*WriteString                    )(HyperFile *hf, const String *v);
  626.     Bool                        (*WriteFilename                )(HyperFile *hf, const Filename *v);
  627.     Bool                        (*WriteImage                    )(HyperFile *hf, BaseBitmap *v, LONG format, const BaseContainer *data);
  628.     Bool                        (*WriteContainer            )(HyperFile *hf, const BaseContainer *v);
  629.     Bool                        (*WriteMemory                    )(HyperFile *hf, void *data, LONG count);
  630.  
  631.     Bool                        (*ReadChar                        )(HyperFile *hf, CHAR          *v);
  632.     Bool                        (*ReadUChar                        )(HyperFile *hf, UCHAR         *v);
  633.     Bool                        (*ReadWord                        )(HyperFile *hf, WORD          *v);
  634.     Bool                        (*ReadUWord                      )(HyperFile *hf, UWORD         *v);
  635.     Bool                        (*ReadLong                      )(HyperFile *hf, LONG          *v);
  636.     Bool                        (*ReadULong                      )(HyperFile *hf, ULONG         *v);
  637.     Bool                        (*ReadReal                      )(HyperFile *hf, Real          *v);
  638.     Bool                        (*ReadLReal                      )(HyperFile *hf, LReal         *v);
  639.     Bool                        (*ReadBool                      )(HyperFile *hf, Bool          *v);
  640.     Bool                        (*ReadTime                        )(HyperFile *hf, BaseTime      *v);
  641.     Bool                        (*ReadVector                    )(HyperFile *hf, Vector        *v);
  642.     Bool                        (*ReadLVector                    )(HyperFile *hf, LVector       *v);
  643.     Bool                        (*ReadMatrix                    )(HyperFile *hf, Matrix        *v);
  644.     Bool                        (*ReadLMatrix                    )(HyperFile *hf, LMatrix       *v);
  645.     Bool                        (*ReadString                    )(HyperFile *hf, String       *v);
  646.     Bool                        (*ReadFilename                )(HyperFile *hf, Filename     *v);
  647.     Bool                        (*ReadImage                        )(HyperFile *hf, BaseBitmap   *v);
  648.     Bool                        (*ReadContainer                )(HyperFile *hf, BaseContainer *v, Bool flush);
  649.     Bool                        (*ReadMemory                    )(HyperFile *hf, void **data, LONG *size);
  650.  
  651.     LONG                        (*GetError                        )(HyperFile *hf);
  652.     void                        (*SetError                        )(HyperFile *hf, LONG err);
  653.     Bool                        (*ReadValueHeader            )(HyperFile *hf, UCHAR *h);
  654.     Bool                        (*SkipValue                        )(HyperFile *hf, UCHAR h);
  655.     Bool                        (*WriteChunkStart            )(HyperFile *hf, LONG id, LONG level);
  656.     Bool                        (*WriteChunkEnd                )(HyperFile *hf);
  657.     Bool                        (*ReadChunkStart            )(HyperFile *hf, LONG *id, LONG *level);
  658.     Bool                        (*ReadChunkEnd                )(HyperFile *hf);
  659.     Bool                        (*SkipToEndChunk            )(HyperFile *hf);
  660.     BaseDocument*        (*GetDocument                    )(HyperFile *hf);
  661.  
  662.     LONG                        (*ReadFile                        )(BaseDocument *doc, GeListNode *node, const Filename &filename, LONG ident, String *warning_string);
  663.     LONG                        (*WriteFile                        )(BaseDocument *doc, GeListNode *node, const Filename &filename, LONG ident);
  664.  
  665.     LONG                        (*GetFileVersion            )(HyperFile *hf);
  666. };
  667.  
  668. struct C4D_BaseContainer
  669. {
  670.     BaseContainer        *Default;
  671.  
  672.     // container
  673.     BaseContainer*    (*Alloc                                )(LONG id);
  674.     void                        (*Free                                )(BaseContainer *killme);
  675.  
  676.     BaseContainer*    (*GetClone                        )(const BaseContainer *bc);
  677.     void                        (*FlushAll                        )(BaseContainer *bc);
  678.     LONG                        (*GetId                                )(const BaseContainer *bc);
  679.     void                        (*SetId                                )(BaseContainer *bc, LONG newid);
  680.     Bool                        (*Compare                            )(const BaseContainer *bc1,const BaseContainer *bc2);
  681.  
  682.     Bool                        (*SetReal                            )(BaseContainer *bc, LONG id, Real v);
  683.     Bool                        (*SetBool                            )(BaseContainer *bc, LONG id, Bool v);
  684.     Bool                        (*SetLong                            )(BaseContainer *bc, LONG id, LONG v);
  685.     Bool                        (*SetString                        )(BaseContainer *bc, LONG id, const String *v);
  686.     Bool                        (*SetFilename                    )(BaseContainer *bc, LONG id, const Filename *v);
  687.     Bool                        (*SetBaseTime                    )(BaseContainer *bc, LONG id, const BaseTime &v);
  688.     Bool                        (*SetContainer                )(BaseContainer *bc, LONG id, const BaseContainer *v);
  689.     Bool                        (*SetVector                        )(BaseContainer *bc, LONG id, const Vector &v);
  690.     Bool                        (*SetMatrix                        )(BaseContainer *bc, LONG id, const Matrix &v);
  691.  
  692.     Real                        (*GetReal                            )(const BaseContainer *bc, LONG id);
  693.     Bool                        (*GetBool                            )(const BaseContainer *bc, LONG id);
  694.     LONG                        (*GetLong                            )(const BaseContainer *bc, LONG id);
  695.     String*                    (*GetString                        )(const BaseContainer *bc, LONG id);
  696.     Filename*                (*GetFilename                    )(const BaseContainer *bc, LONG id);
  697.     BaseTime                (*GetBaseTime                    )(const BaseContainer *bc, LONG id);
  698.     BaseContainer*    (*GetContainer              )(const BaseContainer *bc, LONG id);
  699.     Vector                    (*GetVector                        )(const BaseContainer *bc, LONG id);
  700.     Matrix                    (*GetMatrix                      )(const BaseContainer *bc, LONG id);
  701.     Bool                        (*RemoveData                    )(BaseContainer *bc, LONG id);
  702.     LONG                        (*FindIndex                        )(const BaseContainer *bc, LONG id);
  703.     LONG                        (*GetIndexId                    )(const BaseContainer *bc, LONG index);
  704.     Bool                        (*RemoveIndex                    )(BaseContainer *bc, LONG index);
  705.     Bool                        (*CopyToEx                        )(const BaseContainer *bc, BaseContainer *dest);
  706.     LONG                        (*GetIndexType                )(const BaseContainer *bc, LONG index);
  707.  
  708.     GeData*                    (*GetIndexData                )(const BaseContainer *bc, LONG index);
  709.     Bool                        (*InsData                            )(BaseContainer *bc, LONG id, const GeData *n);
  710.     Bool                        (*SetData                            )(BaseContainer *bc, LONG id, const GeData *n);
  711.  
  712.     BaseList2D*            (*GetLink                            )(const BaseContainer *bc, LONG id, BaseDocument *doc, LONG instanceof);
  713.     Bool                        (*SetLink                            )(BaseContainer *bc, LONG id, BaseList2D *link);
  714.  
  715.     void                        (*Init                                )(BaseContainer *bc, LONG id);
  716.  
  717.     void*                        (*BrowseContainer            )(const BaseContainer *bc, LONG *id, GeData **data, void *handle);
  718.     void                        (*MergeContainer            )(BaseContainer *dst, const BaseContainer &src);
  719.  
  720.     const GeData&        (*GetData                            )(const BaseContainer *bc, LONG id);
  721.     Bool                        (*GetParameter                )(BaseContainer *dst, const DescID &id, GeData &t_data);
  722.     Bool                        (*SetParameter                )(BaseContainer *dst, const DescID &id, const GeData &t_data);
  723.     Bool                        (*CopyTo                            )(const BaseContainer *bc, BaseContainer *dest,AliasTrans *trans);
  724. };
  725.  
  726. struct C4D_GeData
  727. {
  728.     void            (*Free                )(GeData *data);
  729.     Bool            (*IsEqual             )(const GeData *data,const GeData *data2);
  730.     LONG                        (*GetType                            )(const GeData *data);
  731.     void            (*CopyData                        )(GeData *dest,const GeData *src,AliasTrans *aliastrans);
  732.  
  733.     Bool                        (*SetNil              )(GeData *data);
  734.     Bool                        (*SetLong             )(GeData *data,LONG n);
  735.     Bool                        (*SetReal             )(GeData *data,Real n);
  736.     Bool                        (*SetVector           )(GeData *data,const Vector &n);
  737.     Bool                        (*SetMatrix           )(GeData *data,const Matrix &n);
  738.     Bool                        (*SetString           )(GeData *data,const String *n);
  739.     Bool            (*SetFilename         )(GeData *data,const Filename *n);
  740.     Bool            (*SetBaseTime         )(GeData *data,const BaseTime &n);
  741.     Bool            (*SetBaseContainer    )(GeData *data,const BaseContainer *n);
  742.     Bool            (*SetLink             )(GeData *data,const BaseLink &n);
  743.  
  744.     LONG                        (*GetLong                            )(const GeData *data);
  745.     Real                        (*GetReal                            )(const GeData *data);
  746.     const Vector&        (*GetVector                        )(const GeData *data);
  747.     const Matrix&        (*GetMatrix                        )(const GeData *data);
  748.     const String&        (*GetString                        )(const GeData *data);
  749.     const Filename&    (*GetFilename                    )(const GeData *data);
  750.     const BaseTime&    (*GetTime                            )(const GeData *data);
  751.     BaseContainer*    (*GetContainer                )(const GeData *data);
  752.     BaseLink*                (*GetLink             )(const GeData *data);
  753.  
  754.     Bool            (*SetCustomData                )(GeData *data,LONG type,const CustomDataType &n);
  755.     CustomDataType* (*GetCustomData                )(const GeData *data,LONG type);
  756.     Bool            (*InitCustomData            )(GeData *data,LONG type);
  757. };
  758.  
  759. struct C4D_String
  760. {
  761.     // safety value
  762.     String                    *Default;
  763.  
  764.     // strings
  765.     String*                    (*Alloc                                )(void);
  766.     String*                    (*AllocCString                )(CHAR *txt, LONG count, StringEncoding type);
  767.     String*                    (*AllocArray                    )(LONG count, UWORD fillchr);
  768.     void                        (*Free                                )(String *str);
  769.      String*                    (*GetClone                        )(const String *src);
  770.     LONG                        (*GetLength                        )(const String *str);
  771.     Bool                        (*Add                                    )(String *dst,const String *src);
  772.  
  773.     LONG                        (*Compare                            )(const String *str1, const String *str2,LONG flag);
  774.     Bool                        (*FindFirst                        )(const String *str, const String *find, LONG *pos, LONG start);
  775.     Bool                        (*FindLast                        )(const String *str, const String *find, LONG *pos, LONG start);
  776.   Bool                        (*Delete                            )(String *str,LONG pos,LONG count);
  777.     void                        (*Insert                            )(String *str,LONG pos, const String *ins);
  778.     String*                    (*SubStr                            )(const String *str,LONG start, LONG count);
  779.  
  780.     Real                        (*ToReal                            )(const String *str,LONG *error, LONG einheit, LONG winkelart, LONG basis);
  781.     LONG                        (*ToLong                            )(const String *str, LONG *error);
  782.  
  783.     String*                    (*RealToString                )(Real v, LONG vk, LONG nk, Bool e, UWORD xchar);
  784.     String*                    (*LongToString                )(LONG l);
  785.  
  786.     String*                    (*ToUpper                            )(const String *str);
  787.     String*                    (*ToLower                            )(const String *str);
  788.  
  789.     LONG                        (*GetCStringLen                )(const String *str,StringEncoding type);
  790.     LONG                        (*GetCString                    )(const String *str,CHAR *cstr, LONG max, StringEncoding type);
  791.  
  792.     UWORD                        (*GetChr                            )(const String *str,LONG pos);
  793.     void                        (*SetChr                            )(String *str,LONG pos,UWORD chr);
  794.  
  795.     void                        (*Init                                )(String *str);
  796.     void                        (*InitCString                    )(String *str, const CHAR *txt, LONG count, StringEncoding type);
  797.     void                        (*InitArray                        )(String *str, LONG count, UWORD fillchr);
  798.     void                        (*Flush                                )(String *str);
  799.     void                        (*CopyTo                            )(const String *src, String *dst);
  800. };
  801.  
  802. struct C4D_Bitmap
  803. {
  804.     BaseBitmap*            (*Alloc                                )(void);
  805.     void                        (*Free                                )(BaseBitmap *bm);
  806.     BaseBitmap*            (*GetClone                        )(BaseBitmap *src);
  807.     LONG                        (*GetBw                                )(BaseBitmap *bm);
  808.     LONG                        (*GetBh                                )(BaseBitmap *bm);
  809.     LONG                        (*GetBt                                )(BaseBitmap *bm);
  810.     LONG                        (*GetBpz                            )(BaseBitmap *bm);
  811.     LONG                        (*Init1                                )(BaseBitmap *bm, LONG x, LONG y, LONG depth);
  812.     LONG                      (*Init2                                )(BaseBitmap *bm, const Filename *name, LONG frame, Bool *ismovie);
  813.     void                      (*FlushAll                        )(BaseBitmap *bm);
  814.     LONG                    (*Save                                )(BaseBitmap *bm, const Filename *name, LONG format, const BaseContainer *data, LONG savebits);
  815.     void                        (*GetLine                            )(BaseBitmap *bm, LONG y, void *data);
  816.     void                        (*SetLine                            )(BaseBitmap *bm, LONG y, void *data, LONG depth);
  817.     void                        (*GetAlphaLine                )(BaseBitmap *bm, LONG y, void *data, LONG channel);
  818.     void                        (*SetAlphaLine                )(BaseBitmap *bm, LONG y, void *data, LONG channel);
  819.     void                        (*SetCMAP                            )(BaseBitmap *bm, LONG i, LONG r, LONG g, LONG b);
  820.     void                        (*ScaleIt                            )(BaseBitmap *src, BaseBitmap *dst, LONG intens, Bool sample, Bool nprop);
  821.     void                        (*SetPen                            )(BaseBitmap *bm, LONG r, LONG g, LONG b);
  822.     void                        (*Clear                                )(BaseBitmap *bm, LONG x1, LONG y1, LONG x2, LONG y2, LONG r, LONG g, LONG b);
  823.     void                        (*Line                                )(BaseBitmap *bm, LONG x1, LONG y1, LONG x2, LONG y2);
  824.     void                        (*SetPixel                        )(BaseBitmap *bm, LONG x, LONG y, LONG r, LONG g, LONG b);
  825.     void                        (*GetPixel                        )(BaseBitmap *bm, LONG x, LONG y, UWORD *r, UWORD *g, UWORD *b);
  826.     LONG                        (*AddChannel                    )(BaseBitmap *bm, Bool internal, Bool straight);
  827.     void                        (*RemoveChannel                )(BaseBitmap *bm, LONG channel);
  828.     void                        (*GetAlphaPixel                )(BaseBitmap *bm, LONG channel, LONG x, LONG y, UWORD *val);
  829.     void                        (*SetAlphaPixel                )(BaseBitmap *bm, LONG channel, LONG x, LONG y, LONG val);
  830.     LONG                        (*SaveChannel                    )(BaseBitmap *bm, LONG channel, const Filename *name);
  831.     LONG                        (*GetInternalChannel    )(BaseBitmap *bm);
  832.     LONG                        (*GetChannelCount            )(BaseBitmap *bm);
  833.     LONG                        (*GetChannelNum                )(BaseBitmap *bm, LONG num);
  834.     BaseBitmap*            (*GetClonePart                )(BaseBitmap *src, LONG x, LONG y, LONG w, LONG h);
  835.     void                        (*SetPixelCnt                    )(BaseBitmap *bm, LONG x, LONG y, LONG cnt, UCHAR *buffer, LONG inc);
  836.     void                        (*GetPixelCnt                    )(BaseBitmap *bm, LONG x, LONG y, LONG cnt, UCHAR *buffer, LONG inc);
  837.     Bool                        (*CopyTo                            )(BaseBitmap *src, BaseBitmap *dst);
  838. };
  839.  
  840. struct C4D_MovieSaver
  841. {
  842.     MovieSaver*            (*Alloc                                )(void);
  843.     void                        (*Free                                )(MovieSaver *ms);
  844.     LONG                        (*Open                                )(MovieSaver *ms, const Filename *name, BaseBitmap *bm, LONG fps, LONG id, const BaseContainer *data, LONG savebits);
  845.     LONG                        (*Write                                )(MovieSaver *ms, BaseBitmap *bm);
  846.     void                        (*Close                                )(MovieSaver *ms);
  847.     Bool                        (*Choose                            )(MovieSaver *ms, LONG id, BaseContainer *bc);
  848. };
  849.  
  850. struct C4D_BaseChannel
  851. {
  852.     // channels
  853.     BaseChannel*        (*Alloc                                )(void);
  854.     BaseChannel*        (*GetCloneEx                    )(BaseChannel *bc);
  855.     void                        (*Free                                )(BaseChannel *bc);
  856.     Bool                        (*Compare                            )(BaseChannel *bc1,BaseChannel *bc2);
  857.     LONG                        (*InitTexture                    )(BaseChannel *bc, InitRenderStruct *irs);
  858.     void                        (*FreeTexture                    )(BaseChannel *bc);
  859.     Vector                    (*SampleEx                        )(BaseChannel *bc, VolumeData *vd, Vector *p, Vector *delta, Vector *n, Real t, LONG tflag, Real off, Real scale);
  860.     BaseBitmap*            (*GetBitmap                        )(BaseChannel *bc);
  861.     void                        (*GetData                            )(BaseChannel *bc, BaseContainer *ct);
  862.     void                        (*SetData                            )(BaseChannel *bc, const BaseContainer *ct);
  863.     Bool                        (*ReadData                        )(HyperFile *hf, BaseChannel *bc);
  864.     Bool                        (*WriteData                        )(HyperFile *hf, BaseChannel *bc);
  865.  
  866.     _TextureGroup*    (*DlgAlloc                        )(BaseChannel *bc, CDialog *cd, CUserArea *cupreview, LONG idimage, LONG idname, LONG idbluroff, LONG idblurstr, LONG idint, LONG idinfo, LONG idpreview, LONG idedit, LONG idpopup);
  867.     void                        (*DlgFree                            )(_TextureGroup *tg);
  868.     Bool                        (*DlgMessage                    )(_TextureGroup *th, const BaseContainer *msg, Bool preview);
  869.  
  870.     Bool                        (*MessageEx           )(BaseChannel *bc, LONG id, void *data);
  871.     void*                        (*GetPluginDataEx            )(BaseChannel *bc);
  872.     LONG                        (*GetPluginID                    )(BaseChannel *bc);
  873.  
  874.     CHANNELSHADER*    (*GetShaderEx                    )(BaseChannel *bc);
  875.     PluginShader*        (*GetPluginShader            )(BaseChannel *bc);
  876.  
  877.     Bool                        (*Attach                            )(BaseChannel *bc, GeListNode *element);
  878. };
  879.  
  880. struct C4D_Filename
  881. {
  882.     // safety value
  883.     Filename                *Default;
  884.  
  885.     Filename*                (*Alloc                                )(void);
  886.     Filename*                (*GetClone                        )(const Filename *fn);
  887.     void                        (*Free                                )(Filename *fn);
  888.     Bool                        (*FileSelect                    )(Filename *fn,LONG type, LONG flags, const String *title);
  889.     Bool                        (*Content                            )(const Filename *fn);
  890.     String*                    (*GetString                        )(const Filename *fn);
  891.     void                        (*SetString                        )(Filename *fn, const String *str);
  892.     Filename*                (*GetDirectory                )(const Filename *fn);
  893.     Filename*                (*GetFile                            )(const Filename *fn);
  894.     void                        (*ClearSuffix                    )(Filename *fn);
  895.     void                        (*SetSuffix                        )(Filename *fn, const String *str);
  896.     Bool                        (*CheckSuffix                    )(const Filename *fn, const String *str);
  897.     void                        (*SetDirectory                )(Filename *fn, const Filename *str);
  898.     void                        (*SetFile                            )(Filename *fn, const Filename *str);
  899.     Bool                        (*Compare                            )(const Filename *fn1, const Filename *fn2);
  900.     void                        (*Add                                    )(Filename *dst, const Filename *src);
  901.  
  902.     void                        (*Init                                )(Filename *fn);
  903.     void                        (*Flush                                )(Filename *fn);
  904.     void                        (*CopyTo                            )(const Filename *src, Filename *dst);
  905. };
  906.  
  907. struct C4D_BrowseFiles
  908. {
  909.     BrowseFiles*        (*Alloc                                )(const Filename *dir, Bool calcsize);
  910.     void                        (*Free                                )(BrowseFiles *bf);
  911.     Bool                        (*GetNext                            )(BrowseFiles *bf);
  912.     LONG                        (*GetSize                            )(BrowseFiles *bf);
  913.     Bool                        (*IsDir                                )(BrowseFiles *bf);
  914.     Filename*                (*GetFilename                    )(BrowseFiles *bf);
  915.     void                        (*Init                                )(BrowseFiles *bf, const Filename *dir, Bool calcsize);
  916. };
  917.  
  918. struct C4D_File
  919. {
  920.     BaseFile*                (*Alloc                                )(void);
  921.     void                        (*Free                                )(BaseFile *fl);
  922.     Bool                        (*Open                                )(BaseFile *fl, const Filename *name, LONG mode, LONG error_dialog, LONG order, LONG type, LONG creator);
  923.     Bool                        (*Close                                )(BaseFile *fl);
  924.     void                        (*SetOrder                        )(BaseFile *fl, LONG order);
  925.     LONG                        (*ReadBytes                        )(BaseFile *fl, void *data, LONG len, Bool just_try_it);
  926.     LONG                        (*WriteBytes                    )(BaseFile *fl, void *data, LONG len);
  927.     Bool                        (*Seek                                )(BaseFile *fl, LONG pos, LONG mode);
  928.     LONG                        (*GetPosition                    )(BaseFile *fl);
  929.     LONG                        (*GetLength                        )(BaseFile *fl);
  930.     LONG                        (*GetError                        )(BaseFile *fl);
  931.     void                        (*SetError                        )(BaseFile *fl, LONG error);
  932.     Bool                        (*WriteChar                        )(BaseFile *fl, CHAR  v);
  933.     Bool                        (*WriteUChar                    )(BaseFile *fl, UCHAR v);
  934.     Bool                        (*WriteWord                        )(BaseFile *fl, WORD  v);
  935.     Bool                        (*WriteUWord                    )(BaseFile *fl, UWORD v);
  936.     Bool                        (*WriteLong                        )(BaseFile *fl, LONG  v);
  937.     Bool                        (*WriteULong                    )(BaseFile *fl, ULONG v);
  938.     Bool                        (*WriteReal                        )(BaseFile *fl, Real  v);
  939.     Bool                        (*WriteLReal                    )(BaseFile *fl, LReal v);
  940.     Bool                        (*ReadChar                        )(BaseFile *fl, CHAR  *v);
  941.     Bool                        (*ReadUChar                        )(BaseFile *fl, UCHAR *v);
  942.     Bool                        (*ReadWord                        )(BaseFile *fl, WORD  *v);
  943.     Bool                        (*ReadUWord                        )(BaseFile *fl, UWORD *v);
  944.     Bool                        (*ReadLong                        )(BaseFile *fl, LONG  *v);
  945.     Bool                        (*ReadULong                        )(BaseFile *fl, ULONG *v);
  946.     Bool                        (*ReadReal                        )(BaseFile *fl, Real  *v);
  947.     Bool                        (*ReadLReal                        )(BaseFile *fl, LReal *v);
  948. };
  949.  
  950. struct C4D_Dialog
  951. {
  952.     CDialog*                (*Alloc                                    )(CDialogMessage *dlgfunc,void *userdata);
  953.     void                        (*Free                                    )(CDialog *cd);
  954.     void*                        (*GetUserData                        )(CDialog *cd);
  955.     CUserArea*            (*AttachUserAreaEx            )(CDialog *cd, LONG id,void *userdata);
  956.     Bool                        (*OpenEx                                )(CDialog *cd, Bool async, CDialog *parent, LONG xpos, LONG ypos);
  957.     Bool                        (*Close                                    )(CDialog *cd);
  958.     Bool                        (*SendUserAreaMessage        )(CDialog *cd, LONG id, BaseContainer *msg,void *gadptr);
  959.     Bool                        (*Enable                                )(CDialog *cd, LONG id, Bool enabled,void *gadptr);
  960.     void                        (*SetTimer                            )(CDialog *cd, LONG timer);
  961.     Bool                        (*SetLong                                )(CDialog *cd, LONG id, LONG value,LONG min,LONG max,LONG step,void *gadptr);
  962.     Bool                        (*SetReal                                )(CDialog *cd, LONG id, Real value,Real min,Real max,Real step,LONG format,void *gadptr);
  963.     Bool                        (*SetVector                            )(CDialog *cd, LONG id, const Vector &value,void *gadptr);
  964.     Bool                        (*SetString                            )(CDialog *cd, LONG id, const String *text,void *gadptr);
  965.     Bool                        (*SetColorField                    )(CDialog *cd, LONG id, const Vector &color, Real brightness,Real maxbrightness,LONG flags,void *gadptr);
  966.     Bool                        (*GetLong                                )(CDialog *cd, LONG id, LONG &value,void *gadptr);
  967.     Bool                        (*GetReal                                )(CDialog *cd, LONG id, Real &value,void *gadptr);
  968.     Bool                        (*GetVector                            )(CDialog *cd, LONG id, Vector &value,void *gadptr);
  969.     Bool                        (*GetString                            )(CDialog *cd, LONG id, String *&text,void *gadptr);
  970.     Bool                        (*GetColorField                    )(CDialog *cd, LONG id, Vector &color, Real &brightness,void *gadptr);
  971.     Bool                        (*AddGadgetEx                        )(CDialog *cd, LONG type, LONG id, const String *name,LONG par1,LONG par2, LONG par3, LONG par4);
  972.     Bool                        (*LoadDialogResource        )(CDialog *cd, LONG id, LocalResource *lr, LONG flags);
  973.     Bool                        (*TabGroupBegin                    )(CDialog *cd, LONG id, LONG flags,LONG tabtype);
  974.     Bool                        (*GroupBegin                        )(CDialog *cd, LONG id, LONG flags,LONG cols,LONG rows,const String *title,LONG groupflags);
  975.     Bool                        (*GroupSpace                        )(CDialog *cd, LONG spacex,LONG spacey);
  976.     Bool                        (*GroupBorder                        )(CDialog *cd, LONG borderstyle);
  977.     Bool                        (*GroupBorderSize                )(CDialog *cd, LONG left, LONG top,LONG right,LONG bottom);
  978.     Bool                        (*GroupEnd                            )(CDialog *cd);
  979.     Bool                        (*SetPopup                            )(CDialog *cd, LONG id, const BaseContainer *bc,void *gadptr);
  980.     Bool                        (*Screen2Local                    )(CDialog *cd, LONG *x, LONG *y);
  981.     Bool                        (*SetVisibleArea                )(CDialog *cd, LONG scrollgroupid, LONG x1, LONG y1,LONG x2,LONG y2);
  982.     Bool                        (*GetItemDim                        )(CDialog *cd, LONG id, LONG *x, LONG *y, LONG *w, LONG *h,void *gadptr);
  983.     Bool                        (*ScrollGroupBeginEx        )(CDialog *cd, LONG id, LONG flags,LONG scrollflags);
  984.     Bool                        (*SendRedrawThread            )(CDialog *cd, LONG id);
  985.     Bool            (*GetVisibleArea                )(CDialog *cd, LONG id, LONG *x1,LONG *y1,LONG *x2,LONG *y2);
  986.     Bool                        (*RestoreLayout                    )(CDialog *cd, void *secret);
  987.     Bool                        (*SetMessageResult            )(CDialog *cd, const BaseContainer *result);
  988.     Bool            (*GetDragObjectEx                )(CDialog *cd, const BaseContainer *msg,LONG *type,void **object);
  989.  
  990.     Bool            (*SetDragDestination        )(CDialog *cd, LONG cursor);
  991.     Bool                        (*AttachSubDialog                )(CDialog *parentcd,LONG id,CDialog *cd);
  992.     LONG                        (*GetID                                    )(CDialog *cu);
  993.     void*                        (*FindCustomGui                    )(CDialog *cd,LONG id);
  994.     Bool                        (*AddGadget                            )(CDialog *cd, LONG type, LONG id, const String *name,LONG par1,LONG par2, LONG par3, LONG par4,const BaseContainer *customdata,void **resptr);
  995.     Bool                        (*ReleaseLink                        )(CDialog *cd);
  996.     Bool                        (*SendParentMessage            )(CDialog *cd,const BaseContainer *msg);
  997.     Bool                        (*Open                                    )(CDialog *cd, Bool async, CDialog *parent, LONG xpos, LONG ypos,LONG defaultw,LONG defaulth);
  998.     CUserArea*            (*AttachUserArea                )(CDialog *cd, LONG id,void *userdata,LONG userareaflags,void *gadptr);
  999.     Bool            (*GetDragObject                    )(CDialog *cd, const BaseContainer *msg,LONG *type,void **object);
  1000.  
  1001.     LassoSelection*    (*LSAlloc                                )(void);
  1002.     void                        (*LSFree                                )(LassoSelection *ls);
  1003.     LONG                        (*LSGetMode                            )(LassoSelection *ls);
  1004.     Bool                        (*LSTest                                )(LassoSelection *ls, LONG x, LONG y);
  1005.     Bool                        (*LSCheckSingleClick        )(LassoSelection *ls);
  1006.     Bool                        (*LSStart                                )(LassoSelection *ls, CBaseFrame *cd, LONG mode, LONG start_x, LONG start_y, LONG start_button,LONG sx1, LONG sy1, LONG sx2, LONG sy2);
  1007.     Bool                        (*LSTestPolygon                    )(LassoSelection *ls, const Vector &pa, const Vector &pb, const Vector &pc, const Vector &pd);
  1008.  
  1009.     CBaseFrame*            (*CBF_FindBaseFrame            )(CDialog *cd,LONG id);
  1010.     Bool                        (*CBF_SetDragDestination)(CBaseFrame *cbf,LONG cursor);
  1011.     void*                        (*CBF_GetWindowHandle        )(CBaseFrame *cbf);
  1012. };
  1013.  
  1014. struct C4D_UserArea
  1015. {
  1016.     void                        (*Free                )(CUserArea* cu);
  1017.     void*                        (*GetUserData         )(CUserArea *cu);
  1018.     LONG                        (*GetWidth            )(CUserArea *cu);
  1019.     LONG                        (*GetHeight           )(CUserArea *cu);
  1020.     LONG                        (*GetID               )(CUserArea *cu);
  1021.     void                        (*SetMinSize          )(CUserArea *cu, LONG w,LONG h);
  1022.     void                        (*DrawLine            )(CUserArea *cu, LONG x1,LONG y1,LONG x2,LONG y2);
  1023.     void                        (*DrawRectangle       )(CUserArea *cu, LONG x1,LONG y1,LONG x2,LONG y2);
  1024.     void                        (*DrawSetPenV         )(CUserArea *cu, const Vector &color);
  1025.     void                        (*DrawSetPenI         )(CUserArea *cu, LONG id);
  1026.     void                        (*SetTimer            )(CUserArea *cu, LONG timer);
  1027.     Bool                        (*GetInputState       )(CBaseFrame *cu, LONG askdevice,LONG askchannel,BaseContainer *res);
  1028.     Bool                        (*GetInputEvent       )(CBaseFrame *cu, LONG askdevice,BaseContainer *res);
  1029.     void                        (*KillEvents          )(CBaseFrame *cu);
  1030.     void                        (*DrawSetFont         )(CUserArea *cu, LONG fontid);
  1031.     LONG                        (*DrawGetTextWidth    )(CUserArea *cu, const String *text);
  1032.     LONG                        (*DrawGetFontHeight   )(CUserArea *cu);
  1033.     void                        (*DrawSetTextColII    )(CUserArea *cu, LONG fg,LONG bg);
  1034.     void                        (*DrawSetTextColVI    )(CUserArea *cu, const Vector &fg,LONG bg);
  1035.     void                        (*DrawSetTextColIV    )(CUserArea *cu, LONG fg,const Vector &bg);
  1036.     void                        (*DrawSetTextColVV    )(CUserArea *cu, const Vector &fg,const Vector &bg);
  1037.     void                        (*DrawText            )(CUserArea *cu, const String *txt,LONG x,LONG y);
  1038.     void                        (*DrawBitmap          )(CUserArea *cu, BaseBitmap *bmp,LONG wx,LONG wy,LONG ww,LONG wh,LONG x,LONG y,LONG w,LONG h,LONG mode);
  1039.     void                        (*SetClippingRegion   )(CUserArea *cu, LONG x,LONG y,LONG w,LONG h);
  1040.     void                        (*ScrollArea          )(CUserArea *cu, LONG xdiff,LONG ydiff,LONG x,LONG y,LONG w,LONG h);
  1041.     void                        (*ClearClippingRegion )(CUserArea *cu);
  1042.     Bool                        (*OffScreenOn         )(CUserArea *cu);
  1043.  
  1044.     Bool                        (*Global2Local        )(CBaseFrame *cu, LONG *x,LONG *y);
  1045.     Bool                        (*SendParentMessage   )(CUserArea *cu, const BaseContainer *msg);
  1046.  
  1047.     Bool                        (*Screen2Local        )(CBaseFrame *cu, LONG *x, LONG *y);
  1048.     Bool            (*SetDragDestination  )(CUserArea *cu, LONG cursor);
  1049.     Bool            (*HandleMouseDrag     )(CUserArea *cu, const BaseContainer *msg,LONG type,void *data,Bool privateframe);
  1050.     Bool                        (*IsEnabled           )(CUserArea *cu);
  1051.  
  1052.     void                        (*GetBorderSize       )(CUserArea *cu,LONG type,LONG *l,LONG *t,LONG *r,LONG *b);
  1053.     void            (*DrawBorder          )(CUserArea *cu,LONG type,LONG x1,LONG y1,LONG x2,LONG y2);
  1054.  
  1055.     _GeListView*        (*GeListView_Alloc            )(void);
  1056.     void                        (*GeListView_Free             )(_GeListView *lv);
  1057.     Bool            (*GeListView_Attach           )(_GeListView *lv,CDialog *cd,LONG id,ListViewCallBack *callback,void *userdata);
  1058.     void            (*GeListView_LvSuperCall      )(_GeListView *lv,LONG &res_type,void *&result,void *secret,LONG cmd,LONG line,LONG col);
  1059.     void            (*GeListView_Redraw           )(_GeListView *lv);
  1060.     void            (*GeListView_DataChanged      )(_GeListView *lv);
  1061.     Bool            (*GeListView_ExtractMouseInfo )(_GeListView *lv,void *secret,MouseDownInfo &info,LONG size);
  1062.     Bool            (*GeListView_ExtractDrawInfo  )(_GeListView *lv,void *secret,DrawInfo &info,LONG size);
  1063.     Bool            (*GeListView_SendParentMessage)(_GeListView *lv,const BaseContainer *msg);
  1064.     LONG                        (*GeListView_GetId            )(_GeListView *lv);
  1065.  
  1066.     _SimpleListView* (*SimpleListView_Alloc       )(void);
  1067.     void            (*SimpleListView_Free         )(_SimpleListView *lv);
  1068.     Bool            (*SimpleListView_SetLayout    )(_SimpleListView *lv,LONG columns,const BaseContainer &data);
  1069.     Bool            (*SimpleListView_SetItem      )(_SimpleListView *lv,LONG id,const BaseContainer &data);
  1070.     Bool            (*SimpleListView_GetItem      )(_SimpleListView *lv,LONG id,BaseContainer *data);
  1071.     LONG            (*SimpleListView_GetItemCount )(_SimpleListView *lv);
  1072.     Bool            (*SimpleListView_GetItemLine  )(_SimpleListView *lv,LONG num,LONG *id,BaseContainer *data);
  1073.     Bool            (*SimpleListView_RemoveItem   )(_SimpleListView *lv,LONG id);
  1074.     LONG            (*SimpleListView_GetSelection )(_SimpleListView *lv,BaseSelect *selection);
  1075.     Bool            (*SimpleListView_SetSelection )(_SimpleListView *lv,BaseSelect *selection);
  1076.  
  1077.     LONG            (*SimpleListView_GetProperty  )(_SimpleListView *lv,LONG id);
  1078.     Bool            (*SimpleListView_SetProperty  )(_SimpleListView *lv,LONG id,LONG val);
  1079.  
  1080.     Bool                        (*IsHotkeyDown                )(CUserArea *cu, LONG id);
  1081.     Bool                        (*HasFocus                                        )(CUserArea *cu);
  1082.  
  1083.     void                        (*MouseDragStart                            )(CUserArea *cu,LONG Button,Real mx,Real my,LONG flag);
  1084.     LONG                        (*MouseDrag                                        )(CUserArea *cu,Real *mx,Real *my,BaseContainer *channels);
  1085.     LONG                        (*MouseDragEnd                                )(CUserArea *cu);
  1086. };
  1087.  
  1088. struct C4D_Parser
  1089. {
  1090.     Parser*                    (*Alloc                                )(void);
  1091.     void                        (*Free                                )(Parser *pr);
  1092.     Bool                        (*AddVar                            )(Parser *pr, const String *str, Real *value);
  1093.     Bool                        (*Eval                                )(Parser *pr, const String *str, LONG *error,Real *res,LONG unit,LONG angletype,LONG basis);
  1094. };
  1095.  
  1096. struct C4D_Resource
  1097. {
  1098.     LocalResource*    (*Alloc                                )(const Filename *path);
  1099.     void                        (*Free                )(LocalResource *lr);
  1100.     String*                    (*LoadStringEx        )(LocalResource *lr,LONG id);
  1101.     LocalResource*  (*GetCinemaResource   )(void);
  1102.     const String&        (*LoadString          )(LocalResource *lr,LONG id);
  1103. };
  1104.  
  1105. struct C4D_Atom
  1106. {
  1107.     Atom*                        (Atom::*GetClone                            )(LONG flags, AliasTrans *trn);
  1108.     Bool                        (Atom::*CopyTo                                )(Atom *dst, LONG flags, AliasTrans *trn);
  1109.     LONG                        (Atom::*GetType                                )(void);
  1110.     Bool                        (Atom::*IsInstanceOf                    )(LONG id);
  1111.     Bool                        (Atom::*Message                                )(LONG type, void *data);
  1112.     Bool                        (Atom::*MultiMessage                    )(LONG flags, LONG type, void *data);
  1113.     Bool            (Atom::*GetDescription                )(Description &res,LONG flags);
  1114.     Bool            (Atom::*GetParameter                    )(const DescID &id,GeData &t_data,LONG flags);
  1115.     Bool            (Atom::*SetParameter                    )(const DescID &id,const GeData &t_data,LONG flags);
  1116.     DynamicDescription*        (Atom::*GetDynamicDescription)();
  1117.  
  1118.     GeListNode*            (GeListNode::*GetNext                    )(void) const;
  1119.     GeListNode*            (GeListNode::*GetPred                    )(void) const;
  1120.     GeListNode*            (GeListNode::*GetUp                        )(void) const;
  1121.     GeListNode*            (GeListNode::*GetDown                    )(void) const;
  1122.     GeListNode*            (GeListNode::*GetDownLast            )(void) const;
  1123.     void                        (GeListNode::*InsertBefore        )(GeListNode *bl);
  1124.     void                        (GeListNode::*InsertAfter            )(GeListNode *bl);
  1125.     void                        (GeListNode::*InsertUnder            )(GeListNode *bl);
  1126.     void                        (GeListNode::*InsertUnderLast    )(GeListNode *bl);
  1127.     void                        (GeListNode::*Remove                    )(void);
  1128.     GeListHead*            (GeListNode::*GetListHead            )(void);
  1129.     BaseDocument*        (GeListNode::*GetDocument            )(void) const;
  1130.  
  1131.     GeListNode*            (GeListHead::*GetFirst                )(void) const;
  1132.     GeListNode*            (GeListHead::*GetLast                    )(void) const;
  1133.     void                        (GeListHead::*FlushAll                )(void);
  1134.     void                        (GeListHead::*InsertFirst            )(GeListNode *bn);
  1135.     void                        (GeListHead::*InsertLast            )(GeListNode *bn);
  1136.     void                        (GeListHead::*SetParent                )(GeListNode *parent);
  1137.     GeListNode*            (GeListHead::*GetParent                )(void) const;
  1138.  
  1139.     BaseList2D*            (BaseList2D::*GetMain                    )(void) const;
  1140.     const String&   (BaseList2D::*GetName                    )(void);
  1141.     void                        (BaseList2D::*SetName                    )(const String &str);
  1142.     Bool                        (BaseList2D::*TransferGoal        )(BaseList2D *dst);
  1143.     Bool                        (BaseList2D::*SetAnimatedParameter)(const DescID &id,const GeData &t_data1,const GeData &t_data2,Real mix,LONG flags);
  1144.     Bool                        (BaseList2D::*GetAnimatedParameter)(const DescID &id,GeData &t_data1,GeData &t_data2,Real &mix,LONG flags);
  1145.  
  1146.     // AtomArray
  1147.     AtomArray*            (*AtomArrayAlloc                            )();
  1148.     void                        (*AtomArrayFree                                )(AtomArray *&obj);
  1149.     LONG                        (AtomArray::*GetCount                    )() const;
  1150.     Atom *                    (AtomArray::*GetIndex                    )(LONG idx) const;
  1151.     Bool                        (AtomArray::*Append                        )(Atom *obj);
  1152.     void                        (AtomArray::*Flush                        )();
  1153.     Bool                        (AtomArray::*AACopyTo                    )(AtomArray *dest) const;
  1154.  
  1155.     LONG                        (AtomArray::*AAGetUserID            )() const;
  1156.     void                        (AtomArray::*AASetUserID            )(LONG t_userid);
  1157.  
  1158.     void*                        (AtomArray::*AAGetUserData        )() const;
  1159.     void                        (AtomArray::*AASetUserData        )(void *t_userdata);
  1160.  
  1161.     LONG                        (GeListNode::*GetBranchInfo        )(BranchInfo *info, LONG max);
  1162.  
  1163.     Atom*                        (AtomArray::*AAGetPreferred        )() const;
  1164.     void                        (AtomArray::*AASetPreferred        )(Atom *t_preferred);
  1165. };
  1166.  
  1167. class Coffee;
  1168. class VALUE;
  1169. class GeData;
  1170.  
  1171. typedef GeData CoffeeEditorCallback(BaseList2D *obj, const BaseContainer &msg);
  1172. #define COFFEEEDITOR_GETSTRING    'gets'
  1173. #define COFFEEEDITOR_SETSTRING    'sets'
  1174. #define COFFEEEDITOR_COMPILE        'comp'
  1175.     #define COFFEEEDITOR_GETERROR_RES            'resr'
  1176.     #define COFFEEEDITOR_GETERROR_STRING    'ress'
  1177.     #define COFFEEEDITOR_GETERROR_LINE        'resl'
  1178.     #define COFFEEEDITOR_GETERROR_POS            'resp'
  1179. #define COFFEEEDITOR_EXECUTE        'exec'
  1180.  
  1181. struct C4D_Coffee
  1182. {
  1183.     Coffee*                    (*GeCoffeeAlloc                                )();
  1184.     void                        (*GeCoffeeFree                                )(Coffee* &cof);
  1185.     Bool                        (*GeCoffeeCompileString                )(Coffee* cof, const String& src);
  1186.     Bool                        (*GeCoffeeCompileFile                    )(Coffee* cof, const Filename& file);
  1187.     VALUE*                    (*GeCoffeeAddGlobalSymbol            )(Coffee* cof, const String& name);
  1188.     VALUE*                    (*GeCoffeeFindGlobalSymbol        )(Coffee* cof, const String& name);
  1189.     Bool                        (*GeCoffeeExecute                            )(Coffee* cof, VALUE* func, GeData* retval, GeData* arg1, GeData* arg2, GeData* arg3);
  1190.     Bool                        (*GeCoffeeGeData2Value                )(Coffee* cof, const GeData& src, VALUE* dest);
  1191.     Bool                        (*GeCoffeeValue2GeData                )(Coffee* cof, VALUE *src, GeData* dest);
  1192.     Bool                        (*GeCoffeeGetLastError                )(Coffee* cof, String *err_string, LONG *err_line, LONG *err_pos);
  1193.     Bool                        (*CoffeeEditor_Open                        )(BaseList2D *obj,CoffeeEditorCallback *callback);
  1194. };
  1195.  
  1196. struct C4D_BaseList
  1197. {
  1198.     LONG                        (*GetTypeEx                        )(Atom *at);
  1199.     LONG                        (*GetDiskType                    )(Atom *at);
  1200.     void                        (*GetMarkerEx                    )(BaseList2D *bl, ULONG *l1, ULONG *l2);
  1201.     GeListNode*            (*NextEx                            )(GeListNode *bl);
  1202.     GeListNode*            (*PredEx                            )(GeListNode *bl);
  1203.     void                        (*InsertBeforeEx            )(GeListNode *element, GeListNode *bl);
  1204.     void                        (*InsertAfterEx                )(GeListNode *element, GeListNode *bl);
  1205.     void                        (*RemoveEx                        )(GeListNode *bl);
  1206.     void                        (*SetAllBits                    )(BaseList2D *bl, LONG mask);
  1207.     LONG                        (*GetAllBits                    )(BaseList2D *bl);
  1208.     void                        (*SetColor                        )(BaseList2D *bl, LONG mask);
  1209.     LONG                        (*GetColor                        )(BaseList2D *bl);
  1210.     Bool                        (*MessageEx                        )(Atom *at, LONG type, void *data);
  1211.     GeListNode*            (*UpEx                                )(GeListNode *bl);
  1212.     GeListNode*            (*DownEx                            )(GeListNode *bl);
  1213.     GeListNode*            (*DownLastEx                    )(GeListNode *bl);
  1214.     void                        (*InsertUnderEx                )(GeListNode *element, GeListNode *bl);
  1215.     void                        (*InsertUnderLastEx        )(GeListNode *element, GeListNode *bl);
  1216.     void                        (*Free                                )(Atom *at);
  1217.     void*                        (*GetMainEx                        )(BaseList2D *bl);
  1218.     Bool                        (*Read                                )(Atom *at, HyperFile *hf, LONG id, LONG level);
  1219.     Bool                        (*Write                                )(Atom *at, HyperFile *hf);
  1220.     Bool                        (*ReadObject                    )(Atom *bn, HyperFile *hf, Bool readheader);
  1221.     Bool                        (*WriteObject                    )(Atom *bn, HyperFile *hf);
  1222.     void                        (*GetData                            )(BaseList2D *bl, BaseContainer *ct);
  1223.     void                        (*SetData                            )(BaseList2D *bl, const BaseContainer *ct, Bool add);
  1224.     BaseContainer*    (*GetDataInstance            )(BaseList2D *bl);
  1225.  
  1226.     GeListHead*            (*AllocListHead                )(void);
  1227.     GeListNode*            (*AllocListNode                )(LONG bits, LONG *id_array, LONG id_cnt);
  1228.  
  1229.     NodeData*                (*GetNodeData                    )(GeListNode *bn, LONG index);
  1230.     LONG                        (*GetNodeID                        )(GeListNode *bn, LONG index);
  1231.     NODEPLUGIN*            (*RetrieveTable                )(GeListNode *node, LONG index);
  1232.     NODEPLUGIN*            (*RetrieveTableX            )(NodeData *node, LONG index);
  1233.  
  1234.     GeListNode*            (*GetCustomData                )(GeListNode *bn);
  1235.     void                        (*SetCustomData                )(GeListNode *bn, GeListNode *custom);
  1236.     String                    (*GetBubbleHelp                )(BaseList2D *bl);
  1237. };
  1238.  
  1239. struct C4D_Tag
  1240. {
  1241.     BaseTag*                (*Alloc                                )(LONG type, LONG subtype, LONG count);
  1242.     BaseTag*                (*GetCloneEx                    )(BaseTag *bt, LONG flags);
  1243.     Bool                        (*CopyToEx                        )(BaseTag *bt, BaseTag *dest, LONG flags);
  1244.     LONG                        (*GetTagInfoEx                )(BaseTag *bt);
  1245.     Bool                        (*EditEx                            )(BaseTag *bt);
  1246.     LONG                        (*GetDataCount                )(VariableTag *bt);
  1247.     LONG                        (*GetDataSize                    )(VariableTag *bt);
  1248.     void*                        (*GetDataAddress            )(VariableTag *bt);
  1249.     void                        (*SetDataEx                        )(BaseTag *tag, BaseContainer *bc);
  1250.     void                        (*GetDataEx                        )(BaseTag *tag, BaseContainer *bc);
  1251.     BaseSelect*            (*GetBaseSelect                )(SelectionTag *tag);
  1252.     Bool                        (*Record                            )(StickTextureTag *stt, BaseObject *op, Bool always);
  1253.     LONG                        (*GetPluginIDEx                )(PluginTag *tag);
  1254.     void*                        (*GetPluginDataEx            )(PluginTag *tag);
  1255.     void                        (*SetPluginDataEx            )(PluginTag *tag,void *mem);
  1256.  
  1257.     // UVWs
  1258.     void                        (*UvGet                                )(UVWTag *tag, LONG i, UVWStruct *s);
  1259.     void                        (*UvSet                                )(UVWTag *tag, LONG i, UVWStruct *s);
  1260.     void                        (*UvCpy                                )(UVWTag *tag, LONG dst, UVWTag *srctag, LONG src);
  1261.  
  1262.     void                        (*GetIconEx                        )(BaseTag *tag, IconData *dat);
  1263. };
  1264.  
  1265. struct C4D_Object
  1266. {
  1267.     BaseObject*            (*Alloc                                )(LONG type, LONG subtype);
  1268.     SplineObject*        (*AllocSplineObject        )(LONG pcnt, LONG type);
  1269.     PluginObject*        (*AllocPluginObjectEx    )(LONG plug_id);
  1270.     LONG                        (*GetSubTypeEx                )(BaseObject *op);
  1271.     LONG                        (*GetLayerTypeEx            )(BaseObject *op);
  1272.     BaseContainer*    (*GetDataEx                        )(BaseObject *op);
  1273.     void                        (*GetParameterEx            )(BaseObject *op, BaseContainer *data);
  1274.     void                        (*SetParameterEx            )(BaseObject *op, const BaseContainer *data);
  1275.     Real                        (*GetVisibility                )(BaseObject *op, Real parent);
  1276.     void                        (*SetVisibilityEx            )(BaseObject *op, Real p);
  1277.     Vector                    (*GetPos                            )(BaseObject *op);
  1278.     void                        (*SetPos                            )(BaseObject *op, const Vector &v);
  1279.     Vector                    (*GetScale                        )(BaseObject *op);
  1280.     void                        (*SetScale                        )(BaseObject *op, const Vector &v);
  1281.     Vector                    (*GetRot                            )(BaseObject *op);
  1282.     void                        (*SetRot                            )(BaseObject *op, const Vector &v);
  1283.     Matrix                    (*GetMl                                )(BaseObject *op);
  1284.     void                        (*SetMlEx                            )(BaseObject *op, const Matrix &m);
  1285.     Matrix                    (*GetMg                                )(BaseObject *op);
  1286.     void                        (*SetMgEx                            )(BaseObject *op, const Matrix &m);
  1287.     Matrix                    (*GetMln                            )(BaseObject *op);
  1288.     Matrix                    (*GetMgn                            )(BaseObject *op);
  1289.     Matrix                    (*GetUpMg                            )(BaseObject *op);
  1290.     Vector                    (*GetMp                                )(BaseObject *op);
  1291.     Vector                    (*GetRad                            )(BaseObject *op);
  1292.     LONG                        (*GetMode                            )(BaseObject *op, LONG mode);
  1293.     void                        (*SetMode                            )(BaseObject *op, LONG mode, LONG val);
  1294.     void                        (*GetNameEx                        )(BaseObject *op, String *name);
  1295.     void                        (*SetNameEx                        )(BaseObject *op, const String *name);
  1296.     BaseTag*                (*GetFirstTag                    )(BaseObject *op);
  1297.     BaseTag*                (*GetTag                            )(BaseObject *op, LONG type, LONG nr);
  1298.     void*                        (*GetTagData                    )(BaseObject *op, LONG type, LONG nr);
  1299.     LONG                        (*GetTagDataCount            )(BaseObject *op, LONG type);
  1300.     void                        (*InsertTag                        )(BaseObject *op, BaseTag *tp, BaseTag *pred);
  1301.     void                        (*KillTag                            )(BaseObject *op, LONG type, LONG nr);
  1302.     BaseTrack*            (*GetFirstTrack                )(BaseList2D *op);
  1303.     BaseTrack*            (*GetTrack                        )(BaseList2D *op, LONG type);
  1304.     void                        (*KillAllTracks                )(BaseList2D *op);
  1305.     void                        (*InsertTrack                    )(BaseList2D *op, BaseTrack *track, BaseTrack *pred);
  1306.     LONG                        (*GetInfo                            )(BaseList2D *op);
  1307.     Bool                        (*Edit                                )(BaseList2D *op);
  1308.     BaseObject*            (*GetCache                        )(BaseObject *op, HierarchyHelp *hh);
  1309.     BaseObject*            (*GetDeformCache            )(BaseObject *op);
  1310.     LineObject*            (*GetIsoparm                    )(BaseObject *op);
  1311.     Bool                        (*CopyToEx                        )(BaseObject *op, BaseObject *dest, LONG flags);
  1312.     Bool                        (*CopyTagsToEx                )(BaseObject *op, BaseObject *dest, LONG visible, LONG variable, LONG hierarchical);
  1313.     BaseObject*            (*GetCloneEx                    )(BaseObject *op, LONG flags);
  1314.     Bool                        (*IsDirty                            )(BaseObject *op, LONG flags);
  1315.     void                        (*SetDirty                        )(BaseObject *op, LONG flags);
  1316.     Bool                        (*CheckCache                    )(BaseObject *op, HierarchyHelp *hh);
  1317.     void                        (*SetIsoparm                    )(BaseObject *op, LineObject *l);
  1318.     BaseObject*            (*GenPrimitive                )(BaseDocument *doc, LONG type, const BaseContainer *bc, Real lod, Bool isoparm, BaseThread *bt);
  1319.     BaseObject*            (*GenSplinePrimitive    )(BaseDocument *doc, LONG type, const BaseContainer *bc, Real lod, BaseThread *bt);
  1320.     LONG                        (*GetPluginIDEx                )(PluginObject *op);
  1321.     void*                        (*GetPluginDataEx            )(PluginObject *op);
  1322.     void                        (*SetPluginDataEx            )(PluginObject *op,void *mem);
  1323.     Bool                        (*IsAddictedEx                )(BaseObject *op,BaseDocument *doc);
  1324.     Bool                        (*GetActiveDependenceEx)(BaseObject *op);
  1325.     void                        (*SetActiveDependenceEx)(BaseObject *op, Bool on);
  1326.     void                        (*NewDependenceList        )(PluginObject *op);
  1327.     Bool                        (*CmpDependenceList        )(PluginObject *op);
  1328.     void                        (*TouchDependenceList    )(PluginObject *op);
  1329.     void                        (*AddDependence                )(PluginObject *op,HierarchyHelp *hh, BaseObject *pp);
  1330.     Bool                        (*AddTexture                    )(PluginObject *op, const Filename *fn, RootTextureString *priv);
  1331.     BaseObject*            (*GetHierarchyCloneEx    )(PluginObject *op,HierarchyHelp *hh, BaseObject *pp, LONG flags, Bool *dirty);
  1332.     BaseObject*            (*GetVirtualLineObject)(BaseObject *op, HierarchyHelp *hh, const Matrix &mloc, Bool keep_spline, Bool recurse, Matrix *mres, Bool *dirty);
  1333.     void                        (*Touch                                )(BaseObject *op);
  1334.  
  1335.     // point object
  1336.     BaseSelect*            (*PoGetPointS                    )(PointObject *op);
  1337.     BaseSelect*            (*PoGetPointH                    )(PointObject *op);
  1338.     Bool                        (*PoResizeObject            )(PointObject *op, LONG pcnt);
  1339.     Real*                        (*PoCalcVertexMap            )(PointObject *op, BaseObject *modifier);
  1340.  
  1341.     // line object
  1342.     Bool                        (*LoResizeObject            )(LineObject *op, LONG pcnt, LONG scnt);
  1343.  
  1344.     // polygon object
  1345.     BaseSelect*            (*PyGetPolygonS                )(PolygonObject *op);
  1346.     BaseSelect*            (*PyGetPolygonH                )(PolygonObject *op);
  1347.     Bool                        (*PyResizeObject            )(PolygonObject *op, LONG pcnt, LONG vcnt);
  1348.  
  1349.     // spline object
  1350.     Vector                    (*SpGetSplinePoint        )(SplineObject *op, Real t, LONG segment, Vector *padr);
  1351.     Vector                    (*SpGetSplineTangent    )(SplineObject *op, Real t, LONG segment, Vector *padr);
  1352.     Bool                        (*SpInitLength                )(SplineObject *op, LONG segment, Vector *padr);
  1353.     void                        (*SpFreeLength                )(SplineObject *op);
  1354.     Real                        (*SpUniformToNatural    )(SplineObject *op, Real t);
  1355.     Real                        (*SpGetLength                    )(SplineObject *op);
  1356.     Real                        (*SpGetSegmentLength    )(SplineObject *op, LONG a, LONG b);
  1357.     LineObject*            (*SpGetLineObject            )(SplineObject *op, BaseDocument *doc, Real lod, BaseThread *thread);
  1358.     SplineObject*        (*SpGetRealSpline            )(BaseObject *op);
  1359.     Bool                        (*SpResizeObject            )(SplineObject *op, LONG pcnt, LONG scnt);
  1360.  
  1361.     // particle object
  1362.     LONG                        (*PrGetCount                    )(ParticleObject *op);
  1363.     Real                        (*PrGetLifetime                )(ParticleObject *op);
  1364.     Particle*                (*PrGetParticle                )(ParticleObject *op, ParticleTag *pt, LONG i);
  1365.     Bool                        (*PrIsMatrixAvailable    )(ParticleObject *op);
  1366.     ParticleDetails*(*PrGetParticleDetails)(BaseDocument *doc, ParticleObject *op);
  1367.  
  1368.     // camera object
  1369.     LONG                        (*CoGetProjection            )(BaseObject *op);
  1370.     Real                        (*CoGetFocus                    )(BaseObject *op);
  1371.     Real                        (*CoGetZoom                        )(BaseObject *op);
  1372.     Vector                    (*CoGetOffset                    )(BaseObject *op);
  1373.     Real                        (*CoGetAperture                )(BaseObject *op);
  1374.     Bool                        (*CoSetProjection            )(BaseObject *op, LONG projection);
  1375.     Bool                        (*CoSetFocus                    )(BaseObject *op, Real v);
  1376.     Bool                        (*CoSetZoom                        )(BaseObject *op, Real v);
  1377.     Bool                        (*CoSetOffset                    )(BaseObject *op, const Vector &offset);
  1378.     Bool                        (*CoSetAperture                )(BaseObject *op, Real v);
  1379.  
  1380.     // object safety
  1381.     ObjectSafety*        (*OsAlloc                            )(BaseObject *op);
  1382.     void                        (*OsFree                            )(ObjectSafety *os, Bool restore);
  1383.  
  1384.     // triangulation
  1385.     Bool                        (*Triangulate                    )(Vector *padr, LONG pcnt, Polygon **vadr, LONG *vcnt);
  1386.     PolygonObject*    (*TriangulateLine            )(LineObject *op, Real regular, BaseThread *bt);
  1387.     SplineObject*        (*FitCurve                        )(Vector *padr, LONG pcnt, Real error, BaseThread *bt);
  1388.  
  1389.     // uv stuff
  1390.     UVWTag*                    (*GenerateUVW                    )(BaseObject *op, const Matrix &opmg, TextureTag *tp, const Matrix &texopmg, BaseView *view);
  1391.  
  1392.     void                        (*GetIcon                            )(BaseList2D *op, IconData *dat);
  1393.  
  1394.     ULONG                        (*GetDirty                        )(BaseObject *op, LONG flags);
  1395.  
  1396.     Bool                        (*TriangulateStandard )(Vector *padr, LONG pcnt, LONG *list, LONG lcnt, Polygon *&vadr, LONG &vcnt, BaseThread *thread);
  1397.     Bool                        (*TriangulateRegular    )(Vector *pinp, LONG pinp_cnt, LONG *list, LONG lcnt, Vector *&padr, LONG &pcnt, Polygon *&vadr, LONG &vcnt, Real regular_width, BaseThread *thread);
  1398.  
  1399.     Bool                        (*SpSetDefaultCoeff        )(SplineObject *op);
  1400.     BaseObject*            (*GenerateText                )(BaseContainer *cp, BaseThread *bt, Bool separate);
  1401.  
  1402.     BaseSelect*            (*PyGetEdgeS                    )(PolygonObject *op);
  1403.     BaseSelect*            (*PyGetEdgeH                    )(PolygonObject *op);
  1404.     void                        (*GetColorProperties    )(BaseObject *op, ObjectColorProperties *co);
  1405.     void                        (*SetColorProperties    )(BaseObject *op, ObjectColorProperties *co);
  1406.  
  1407.     void                        (*InsertTrackLast            )(BaseList2D *op, BaseTrack *track);
  1408.     BaseTrack*            (*FindTrack                        )(BaseList2D *op, const DescID &id);
  1409.     Bool                        (*CopyTagsTo                    )(BaseObject *op, BaseObject *dest, LONG visible, LONG variable, LONG hierarchical, AliasTrans *trans);
  1410.     BaseObject*            (*GetHierarchyClone        )(PluginObject *op,HierarchyHelp *hh, BaseObject *pp, LONG flags, Bool *dirty, AliasTrans *trans);
  1411.  
  1412.     BaseObject*            (*GetCacheParent            )(BaseObject *op);
  1413.     Bool                        (*CheckDisplayFilter    )(BaseObject *op, LONG flags);
  1414.  
  1415.     void                        (*SetMl                                )(BaseObject *op, const Matrix &m, Bool force);
  1416.     void                        (*SetMg                                )(BaseObject *op, const Matrix &m, Bool force);
  1417.     BaseSelect*            (*PyGetPhongBreak            )(PolygonObject *op);
  1418.  
  1419.     LONG                        (*GetUniqueIP                    )(BaseObject *op);
  1420.     void                        (*SetUniqueIP                    )(BaseObject *op, LONG ip);
  1421. };
  1422.  
  1423. struct C4D_Document
  1424. {
  1425.     // render data
  1426.     RenderData*            (*RdAlloc                            )(void);
  1427.     void                        (*RdGetDataEx                    )(RenderData *rd, BaseContainer *bc);
  1428.     void                        (*RdSetDataEx                    )(RenderData *rd, BaseContainer *bc);
  1429.  
  1430.     // document
  1431.     BaseDocument*        (*Alloc                                )(void);
  1432.     Bool                        (*CopyToEx                        )(BaseDocument *src, BaseDocument *dst, LONG flags);
  1433.     void                        (*FlushAll                        )(BaseDocument *doc);
  1434.     void                        (*GetData                            )(BaseDocument *doc, LONG type, BaseContainer *bc);
  1435.     void                        (*SetData                            )(BaseDocument *doc, LONG type, const BaseContainer *bc);
  1436.     BaseObject*            (*GetFirstObject            )(BaseDocument *doc);
  1437.     BaseMaterial*        (*GetFirstMaterial        )(BaseDocument *doc);
  1438.     RenderData*            (*GetFirstRenderData    )(BaseDocument *doc);
  1439.     void                        (*InsertRenderData        )(BaseDocument *doc, RenderData *rd, RenderData *pred);
  1440.     void                        (*InsertMaterial            )(BaseDocument *doc, BaseMaterial *mat, BaseMaterial *pred, Bool checknames);
  1441.     void                        (*InsertObject                )(BaseDocument *doc, BaseObject *op, BaseObject *parent, BaseObject *pred, Bool checknames);
  1442.     RenderData*            (*GetActiveRenderData    )(BaseDocument *doc);
  1443.     BaseObject*            (*GetActiveObject            )(BaseDocument *doc);
  1444.     BaseMaterial*        (*GetActiveMaterial        )(BaseDocument *doc);
  1445.     BaseTag*                (*GetActiveTag                )(BaseDocument *doc, BaseObject *active);
  1446.     void                        (*SetActiveObjectEx        )(BaseDocument *doc, BaseObject *op);
  1447.     void                        (*SetActiveTagEx            )(BaseDocument *doc, BaseObject *op, BaseTag *ta);
  1448.     void                        (*SetActiveMaterialEx    )(BaseDocument *doc, BaseMaterial    *mp);
  1449.     void                        (*SetActiveRenderData    )(BaseDocument *doc, RenderData *rd);
  1450.     BaseObject*            (*GetHighest                    )(BaseDocument *doc, LONG type, Bool editor);
  1451.     BaseMaterial*        (*SearchMaterial            )(BaseDocument *doc, const String *str, Bool inc);
  1452.     BaseObject*            (*SearchObject                )(BaseDocument *doc, const String *str, Bool inc);
  1453.     Bool                        (*StartUndo                        )(BaseDocument *doc);
  1454.     Bool                        (*EndUndo                            )(BaseDocument *doc);
  1455.     Bool                        (*AddUndo                            )(BaseDocument *doc, LONG type, void *data);
  1456.     Bool                        (*DoUndo                            )(BaseDocument *doc);
  1457.     Bool                        (*DoRedo                            )(BaseDocument *doc);
  1458.     void                        (*AnimateDocumentEx        )(BaseDocument *doc, LONG flags);
  1459.     void                        (*AnimateObject                )(BaseDocument *doc, BaseList2D *op, const BaseTime &time, LONG flags);
  1460.     BaseDraw*                (*GetActiveBaseDraw        )(BaseDocument *doc);
  1461.     BaseDraw*                (*GetRenderBaseDraw        )(BaseDocument *doc);
  1462.     BaseDraw*                (*GetBaseDraw                    )(BaseDocument *doc, LONG num);
  1463.     LONG                        (*GetSplinePlane            )(BaseDocument *doc);
  1464.  
  1465.     // hierarchy help
  1466.     Real                        (*HhGetLOD                        )(HierarchyHelp *hh);
  1467.     LONG                        (*HhGetVFlags                    )(HierarchyHelp *hh);
  1468.     BaseThread*            (*HhGetThread                    )(HierarchyHelp *hh);
  1469.     BaseDocument*        (*HhGetDocument                )(HierarchyHelp *hh);
  1470.     Matrix                    (*HhGetMg                            )(HierarchyHelp *hh);
  1471.     void                        (*HhAddVFlags                    )(HierarchyHelp *hh, LONG mask);
  1472.  
  1473.     // hierarchy
  1474.     Bool                        (*RunHierarchy                )(void *main, BaseDocument *doc, Bool spheres, Real lod, LONG flags, void *startdata, BaseThread *bt, HierarchyAlloc *ha, HierarchyFree *hf, HierarchyCopyTo *hc, HierarchyDo *hd);
  1475.  
  1476.     Bool                        (*AnimateDocument     )(BaseDocument *doc,BaseThread *bt,Bool doexpressions,Bool doanim);
  1477.     PluginSceneHook*(*FindSceneHook                )(BaseDocument *doc,LONG id);
  1478.  
  1479.     void                        (BaseDocument::*SetActiveObject        )(BaseObject *op,LONG mode);
  1480.     void                        (BaseDocument::*GetActiveObjects    )(AtomArray &selection,Bool childs) const;
  1481.     void                        (BaseDocument::*GetActiveTags            )(AtomArray &selection) const;
  1482.  
  1483.     void                        (*PrAdd                                )(PriorityList *list, GeListNode *node, LONG priority, LONG flags);
  1484.     BaseObject*            (*GetHelperAxis                )(BaseDocument *doc);
  1485.     PluginVideoPost*(*RdGetFirstVideoPost    )(RenderData *rd);
  1486.     void                        (*RdInsertVideoPost        )(RenderData *rd, PluginVideoPost *pvp, PluginVideoPost *pred);
  1487.     void                        (BaseDocument::*GetActiveMaterials)(AtomArray &selection) const;
  1488.  
  1489.     Bool                        (*SoundCommand                )(BaseDocument *doc, LONG command);
  1490.     void                        (*SetRewind                        )(BaseDocument *doc, LONG flags);
  1491.  
  1492.     void                        (BaseDocument::*SetActiveTag            )(BaseTag *op,LONG mode);
  1493.     void                        (BaseDocument::*SetActiveMaterial    )(BaseMaterial *mat,LONG mode);
  1494.  
  1495.     PluginVideoPost*(*VpAlloc                            )(LONG type);
  1496.  
  1497.     LONG                        (*MgGetCount                        )(BaseDocument *doc);
  1498.     BaseContainer*    (*MgAdd                                    )(BaseDocument *doc,const BaseContainer &g);
  1499.     Bool                        (*MgRemove                            )(BaseDocument *doc,LONG id);
  1500.     BaseContainer*    (*MgGetIndex                        )(BaseDocument *doc,LONG i);
  1501.     BaseContainer*    (*MgGetID                                )(BaseDocument *doc,LONG id);
  1502.     Bool                        (*MgIsVisible                        )(BaseDocument *doc,BaseMaterial *mat);
  1503. };
  1504.  
  1505. #ifndef __GE_SPINLOCK
  1506. #define __GE_SPINLOCK
  1507.  
  1508.     typedef volatile LONG    GE_SPINLOCK;
  1509.  
  1510.     struct GE_RWSPINLOCK
  1511.     {
  1512.         GE_RWSPINLOCK()    {lock = 0; count = 0;}
  1513.  
  1514.         GE_SPINLOCK            lock;
  1515.         volatile LONG        count;
  1516.     };
  1517.  
  1518. #endif
  1519.  
  1520. struct C4D_Thread
  1521. {
  1522.     BaseThread*            (*Alloc                                )(ThreadMain *tm, ThreadTest *tt, void *data);
  1523.     void                        (*Free                                )(BaseThread *bt);
  1524.     Bool                        (*TestBreak                        )(BaseThread *bt);
  1525.     Bool                        (*TestBaseBreak                )(BaseThread *bt);
  1526.     Bool                        (*IsRunning                        )(BaseThread *bt);
  1527.     Bool                        (*Start                                )(BaseThread *bt, Bool back, Bool pri);
  1528.     void                        (*End                                    )(BaseThread *bt);
  1529.     void                        (*ThreadLock                    )(void);
  1530.     void                        (*ThreadUnLock                )(void);
  1531.     LONG                        (*GetCPUCount                    )(void);
  1532.     MPBaseThread*        (*MPAlloc                            )(BaseThread *parent, LONG count, ThreadMain *tm, ThreadTest *tt, void **data);
  1533.     void                        (*MPFree                            )(MPBaseThread *mp);
  1534.     BaseThread*            (*MPGetThread                    )(MPBaseThread *mp, LONG i);
  1535.     void*                        (*MPWaitForNextFree        )(MPBaseThread *mp);
  1536.     void                        (*MPWait                            )(MPBaseThread *mp);
  1537.     void                        (*MPEnd                                )(MPBaseThread *mp);
  1538.     Semaphore*            (*SMAlloc                            )(void);
  1539.     void                        (*SMFree                            )(Semaphore *sm);
  1540.     Bool                        (*SMLock                            )(Semaphore *sm);
  1541.     Bool                        (*SMLockAndWait                )(Semaphore *sm, BaseThread *bt);
  1542.     void                        (*SMUnLock                        )(Semaphore *sm);
  1543.     void                        (*Wait                                )(BaseThread *bt, Bool checkevents);
  1544.  
  1545.     BaseThread            *NoThread;
  1546.  
  1547.     void                        (*SpinLock                        )(GE_SPINLOCK *lock);
  1548.     void                        (*SpinUnlock                    )(GE_SPINLOCK *lock);
  1549.     void                        (*SpinReadLock                )(GE_RWSPINLOCK *rwlock);
  1550.     void                        (*SpinReadUnlock            )(GE_RWSPINLOCK *rwlock);
  1551.     void                        (*SpinWriteLock                )(GE_RWSPINLOCK *rwlock);
  1552.     void                        (*SpinWriteUnlock            )(GE_RWSPINLOCK *rwlock);
  1553.  
  1554.     LONG                        (*Identify                        )(BaseThread *bt);
  1555. };
  1556.  
  1557. struct C4D_Material
  1558. {
  1559.     BaseMaterial*        (*Alloc                                )(LONG type, LONG shader_id);
  1560.     LONG                        (*GetPluginIDEx                )(PluginMaterial *mat);
  1561.     void*                        (*GetPluginDataEx            )(PluginMaterial *mat);
  1562.     void                        (*GetNameEx                        )(BaseMaterial *mat, String *name);
  1563.     void                        (*SetNameEx                        )(BaseMaterial *mat, const String *name);
  1564.  
  1565.     void                        (*Update                            )(BaseMaterial *mat, LONG preview, Bool rttm);
  1566.     BaseMaterial*        (*GetCloneEx                    )(BaseMaterial *bm, LONG flags);
  1567.     Bool                        (*CopyToEx                        )(BaseMaterial *bm, BaseMaterial *dest, LONG flags);
  1568.     Bool                        (*EditEx                            )(BaseMaterial *bm);
  1569.     void                        (*SetDataEx                        )(BaseMaterial *bm, BaseContainer *bc);
  1570.     void                        (*GetDataEx                        )(BaseMaterial *bm, BaseContainer *bc);
  1571.     BaseChannel*        (*GetChannel                    )(BaseMaterial *bm, LONG id);
  1572.     Bool                        (*GetChannelState            )(Material *mat, LONG channel);
  1573.     void                        (*SetChannelState            )(Material *mat, LONG channel, Bool state);
  1574.     Bool                        (*Compare                            )(BaseMaterial *m1, BaseMaterial *m2);
  1575.  
  1576.     VOLUMESHADER*        (*GetShaderEx                    )(PluginMaterial *mat);
  1577.     BaseBitmap*            (*GetPreview                    )(BaseMaterial *bm, LONG flags);
  1578. };
  1579.  
  1580. struct C4D_Texture
  1581. {
  1582.     Vector                    (*GetPos                            )(BaseList2D *tag);
  1583.     Vector                    (*GetScale                        )(BaseList2D *tag);
  1584.     Vector                    (*GetRot                            )(BaseList2D *tag);
  1585.     Matrix                    (*GetMl                                )(BaseList2D *tag);
  1586.     Matrix                    (*GetMln                            )(BaseList2D *tag);
  1587.     void                        (*SetPos                            )(BaseList2D *tag, const Vector &v);
  1588.     void                        (*SetScale                        )(BaseList2D *tag, const Vector &v);
  1589.     void                        (*SetRot                            )(BaseList2D *tag, const Vector &v);
  1590.     void                        (*SetMl                                )(BaseList2D *tag, const Matrix &m);
  1591.  
  1592.     BaseMaterial*        (*GetMaterial                    )(BaseList2D *tag);
  1593.     void                        (*SetMaterial                    )(BaseList2D *tag, BaseMaterial *mat);
  1594.  
  1595.     BaseMaterial*        (*GetSecondMaterialEx    )(TextureTag *tag, Real *fade);
  1596.     void                        (*SetSecondMaterialEx    )(TextureTag *tag, BaseMaterial *mat, Real fade);
  1597.  
  1598.     BaseMaterial*   (*GetInterpolatedMaterialEx)(BaseDocument *doc, TextureTag *tag);
  1599. };
  1600.  
  1601. struct C4D_BaseSelect
  1602. {
  1603.     BaseSelect*            (*Alloc                                )(void);
  1604.     void                        (*Free                                )(BaseSelect *bs);
  1605.     void                        (*FlushAll                        )(BaseSelect *bs);
  1606.     LONG                        (*GetCount                        )(BaseSelect *bs);
  1607.     LONG                        (*GetSegments                    )(BaseSelect *bs);
  1608.     Bool                        (*Select                            )(BaseSelect *bs, LONG num);
  1609.     Bool                        (*SelectAll                        )(BaseSelect *bs, LONG min, LONG max);
  1610.     Bool                        (*Deselect                        )(BaseSelect *bs, LONG num);
  1611.     Bool                        (*DeselectAll                    )(BaseSelect *bs);
  1612.     Bool                        (*Toggle                            )(BaseSelect *bs, LONG num);
  1613.     Bool                        (*ToggleAll                        )(BaseSelect *bs, LONG min, LONG max);
  1614.     Bool                        (*GetRange                        )(BaseSelect *bs, LONG seg, LONG *a, LONG *b);
  1615.     Bool                        (*IsSelected                    )(BaseSelect *bs, LONG num);
  1616.     Bool                        (*CopyTo                            )(BaseSelect *bs, BaseSelect *dest);
  1617.     BaseSelect*            (*GetClone                        )(BaseSelect *bs);
  1618.     Bool                        (*FromArray                        )(BaseSelect *bs, UCHAR *selection, LONG count);
  1619.     UCHAR*                    (*ToArray                            )(BaseSelect *bs, LONG count);
  1620. };
  1621.  
  1622. struct C4D_Key
  1623. {
  1624.     BaseKey*                (*Alloc                                )(LONG type, LONG plugid);
  1625.     BaseKey*                (*GetCloneEx                    )(BaseKey *bk, LONG flags);
  1626.     Bool                        (*CopyToEx                        )(BaseKey *bk, BaseKey *dest, LONG flags);
  1627.     Bool                        (*EditEx                            )(BaseKey *bk);
  1628.     BaseTime                (*GetTime                            )(BaseKey *bk);
  1629.     void                        (*SetTime                            )(BaseKey *bk, const BaseTime &time);
  1630.     void                        (*GetDataEx                        )(BaseKey *bk, BaseContainer *ct);
  1631.     void                        (*SetDataEx                        )(BaseKey *bk, const BaseContainer *ct);
  1632.     void                        (*SetPEx                        )(BaseKey *bk, const Vector &v);
  1633.     void                        (*SetVLEx                        )(BaseKey *bk, const Vector &v);
  1634.     void                        (*SetVREx                        )(BaseKey *bk, const Vector &v);
  1635.     Vector                    (*GetPEx                        )(BaseKey *bk);
  1636.     Vector                    (*GetVLEx                        )(BaseKey *bk);
  1637.     Vector                    (*GetVREx                        )(BaseKey *bk);
  1638.     void                        (*SoftTangentsEx            )(BaseKey *bk, BaseDocument *doc, LONG component);
  1639.     VariableTag*        (*GetPointTag                    )(PLAKey *bk);
  1640.     VariableTag*        (*GetHermiteTag                )(PLAKey *bk);
  1641.     LONG                        (*GetPluginIDEx                )(PluginKey *op);
  1642.     void*                        (*GetPluginDataEx            )(PluginKey *op);
  1643.     void                        (*SetPluginDataEx            )(PluginKey *op,void *mem);
  1644.     Bool                        (*FillKey             )(BaseKey *bk);
  1645.     AnimValue*      (*GetKeyValue         )(BaseKey *bk);
  1646. };
  1647.  
  1648. struct C4D_Sequence
  1649. {
  1650.     BaseSequence*        (*Alloc                                )(LONG type, LONG plugid);
  1651.     BaseSequence*        (*GetCloneEx                    )(BaseSequence *bs, LONG flags);
  1652.     Bool                        (*CopyToEx                        )(BaseSequence *bs, BaseSequence *dest, LONG flags);
  1653.     Bool                        (*EditEx                            )(BaseSequence *bs);
  1654.     BaseTime                (*GetT1                                )(BaseSequence *bs);
  1655.     void                        (*SetT1                                )(BaseSequence *bs, const BaseTime &time);
  1656.     BaseTime                (*GetT2                                )(BaseSequence *bs);
  1657.     void                        (*SetT2                                )(BaseSequence *bs, const BaseTime &time);
  1658.     BaseTime                (*GetT3                                )(BaseSequence *bs);
  1659.     void                        (*SetT3                                )(BaseSequence *bs, const BaseTime &time);
  1660.     Bool                        (*GetSoft                            )(BaseSequence *bs);
  1661.     void                        (*SetSoft                            )(BaseSequence *bs, Bool b);
  1662.     void                        (*FlushAllKeys                )(BaseSequence *bs);
  1663.     void                        (*FlushAllTimeKeysEx    )(BaseSequence *bs);
  1664.     LONG                        (*GetKeyCount                    )(BaseSequence *bs);
  1665.     LONG                        (*GetTimeKeyCountEx        )(BaseSequence *bs);
  1666.     BaseKey*                (*FindKey                            )(BaseSequence *bs, const BaseTime &time);
  1667.     BaseTime                (*GetLeft                            )(BaseSequence *bs);
  1668.     BaseTime                (*GetRight                        )(BaseSequence *bs);
  1669.     LONG                        (*GetTimeModeEx                )(BaseSequence *bs);
  1670.     void                        (*SetTimeModeEx                )(BaseSequence *bs, LONG l);
  1671.     Bool                        (*GetLeftInfluence        )(BaseSequence *bs);
  1672.     void                        (*SetLeftInfluence        )(BaseSequence *bs, Bool b);
  1673.     Bool                        (*GetRightInfluence        )(BaseSequence *bs);
  1674.     void                        (*SetRightInfluence        )(BaseSequence *bs, Bool b);
  1675.     Real                        (*GetV0Ex                            )(BaseSequence *bs);
  1676.     void                        (*SetV0Ex                            )(BaseSequence *bs, Real v0);
  1677.     Real                        (*GetS0Ex                            )(BaseSequence *bs);
  1678.     void                        (*SetS0Ex                            )(BaseSequence *bs, Real s0);
  1679.     BaseKey*                (*GetFirstKey                    )(BaseSequence *bs);
  1680.     BaseKey*                (*GetFirstTimeKeyEx        )(BaseSequence *bs);
  1681.     Bool                        (*InsertKey                        )(BaseSequence *bs, BaseKey *bk);
  1682.     Bool                        (*InsertTimeKeyEx            )(BaseSequence *bs, BaseKey *bk);
  1683.     void                        (*GetNameEx                        )(BaseSequence *bk, String *ct);
  1684.     void                        (*SetNameEx                        )(BaseSequence *bk, const String *ct);
  1685.     BaseObject*            (*GetFirstObjectEx        )(BaseSequence *bk);
  1686.     void                        (*InsertObjectEx            )(BaseSequence *bk, BaseObject *op, BaseObject *parent, BaseObject *prev);
  1687.     BaseSound*            (*GetSound                        )(SoundSequence *ss);
  1688.     void                        (*SetSound                        )(SoundSequence *ss, BaseSound *bs);
  1689.     LONG                        (*GetPluginIDEx                )(PluginSequence *op);
  1690.     void*                        (*GetPluginDataEx            )(PluginSequence *op);
  1691.     void                        (*SetPluginDataEx            )(PluginSequence *op,void *mem);
  1692.     void                        (*GetDataEx                        )(BaseSequence *bk, BaseContainer *ct);
  1693.     void                        (*SetDataEx                        )(BaseSequence *bk, const BaseContainer *ct);
  1694. };
  1695.  
  1696. struct C4D_Track
  1697. {
  1698.     BaseTrack*            (*Alloc                                )(LONG type, LONG plugid);
  1699.     BaseTrack*            (*GetCloneEx                    )(BaseTrack *bt, LONG flags);
  1700.     Bool                        (*CopyToEx                        )(BaseTrack *bt, BaseTrack *dest, LONG flags);
  1701.     void                        (*GetNameEx                        )(BaseTrack *bt, String *st);
  1702.     BaseSequence*        (*GetFirstSequence        )(BaseTrack *bt);
  1703.     Bool                        (*InsertSequence            )(BaseTrack *bt, BaseSequence *bs, Bool check);
  1704.     Bool                        (*AnimateObject                )(BaseTrack *bt, BaseDocument *doc, BaseList2D *op, const BaseTime &time, LONG flags, void *data);
  1705.     BaseSequence*        (*FindSequence                )(BaseTrack *bt, const BaseTime &time);
  1706.     LONG                        (*GetPluginIDEx                )(PluginTrack *op);
  1707.     void*                        (*GetPluginDataEx            )(PluginTrack *op);
  1708.     void                        (*SetPluginDataEx            )(PluginTrack *op,void *mem);
  1709.     void                        (*GetDataEx                        )(BaseTrack *bk, BaseContainer *ct);
  1710.     void                        (*SetDataEx                        )(BaseTrack *bk, const BaseContainer *ct);
  1711.     BaseTrack*          (*AllocValueTrack     )(Atom *op, const DescID &id);
  1712.     BaseTrack*          (*AllocDataTrack      )(Atom *op, const DescID &id);
  1713.     BaseTrack*          (*AllocTimeTrack      )();
  1714.     const DescID&     (*GetDescriptionID    )(BaseTrack *bt);
  1715.     BaseSequence*        (*AutoAddSequence            )(BaseTrack *bt, BaseDocument *doc, const BaseTime &time);
  1716. };
  1717.  
  1718. struct C4D_BaseSound
  1719. {
  1720.     BaseSound*            (*Alloc                                )(void);
  1721.     void                        (*Free                                )(BaseSound *bs);
  1722.     BaseSound*            (*GetClone                        )(BaseSound *bs);
  1723.     Bool                        (*CopyTo                            )(BaseSound *bs, BaseSound *dest);
  1724.     Bool                        (*Init                                )(BaseSound *bs, LONG samples, LONG fmode, Bool stereo, Bool b16);
  1725.     void                        (*FlushAll                        )(BaseSound *bs);
  1726.     Bool                        (*Load                                )(BaseSound *bs, const Filename *fn);
  1727.     Bool                        (*Save                                )(BaseSound *bs, const Filename *fn);
  1728.     void                        (*GetSoundInfo                )(BaseSound *bs, Bool *stereo, Bool *b16, LONG *frequency, LONG *samples, BaseTime *length);
  1729.     void                        (*GetSample                        )(BaseSound *bs, LONG i, SData *data);
  1730.     void                        (*SetSample                        )(BaseSound *bs, LONG i, SData *data);
  1731.     BaseBitmap*            (*GetBitmap                        )(BaseSound *bs, LONG width, LONG height, const BaseTime &start, const BaseTime &stop);
  1732.     BaseKey*                (*GetFirstMarker            )(BaseSound *bs);
  1733.     Bool                        (*InsertMarker                )(BaseSound *bs, BaseKey *mk, BaseKey *pred);
  1734.     CHAR*                        (*GetRAW                            )(BaseSound *bs);
  1735. };
  1736.  
  1737. struct C4D_BaseDraw
  1738. {
  1739.     // basedraw
  1740.     Bool                        (*HasCameraLink                )(BaseDraw *bd);
  1741.     void                        (*SetSceneCamera            )(BaseDraw *bd, BaseObject *op);
  1742.     BaseObject*            (*GetSceneCameraEx        )(BaseDraw *bd);
  1743.     BaseObject*            (*GetEditorCamera            )(BaseDraw *bd);
  1744.     Vector                    (*GetObjectColorEx        )(BaseDraw *bd, BaseObject *op);
  1745.     Vector                    (*CheckColor                    )(BaseDraw *bd, const Vector &col);
  1746.     Bool                        (*ZBufAvailable                )(BaseDraw *bd);
  1747.     BaseBitmap*            (*GetBitmapEx                    )(BaseDraw *bd);
  1748.     void                        (*SetTransparency            )(BaseDraw *bd, LONG trans);
  1749.     LONG                        (*GetTransparency            )(BaseDraw *bd);
  1750.     Bool                        (*PointInRange                )(BaseDraw *bd, const Vector &p, LONG x, LONG y);
  1751.     void                        (*SetPen                            )(BaseDraw *bd, const Vector &col);
  1752.     Real                        (*SimpleShade                    )(BaseDraw *bd, const Vector &p, const Vector &n);
  1753.     void                        (*Begin2DEx                        )(BaseDraw *bd);
  1754.     void                        (*End2DEx                            )(BaseDraw *bd);
  1755.     void                        (*Point2D                            )(BaseDraw *bd, const Vector &p);
  1756.     void                        (*Line2D                            )(BaseDraw *bd, const Vector &p1, const Vector &p2); // draw line with 2D clipping
  1757.     void                        (*Handle2D                        )(BaseDraw *bd, const Vector &p, LONG type);
  1758.     void                        (*Circle2D                        )(BaseDraw *bd, LONG mx, LONG my, Real rad);
  1759.     void                        (*LineCSEx                        )(BaseDraw *bd, const Vector &p1, const Vector &p2, Bool clip2d, Bool clipz);
  1760.     void                        (*Point3D                            )(BaseDraw *bd, const Vector &p);
  1761.     void                        (*Line3D                            )(BaseDraw *bd, const Vector &p1, const Vector &p2);
  1762.     void                        (*Handle3D                        )(BaseDraw *bd, const Vector &p, LONG type);
  1763.     void                        (*Circle3D                        )(BaseDraw *bd, const Matrix &m);
  1764.     void                        (*Box3D                                )(BaseDraw *bd, const Matrix &m, Real size, const Vector &col);
  1765.     void                        (*Polygon3D                        )(BaseDraw *bd, Vector *p, Vector *f, Bool quad);
  1766.     void                        (*PolygonObject                )(BaseDraw *bd, BaseDrawHelp *bh, PolygonObject *op, LONG drawpolyflags);
  1767.     void                        (*GetDataEx                        )(BaseDraw *bd, BaseContainer *bc);
  1768.  
  1769.     // basedraw help
  1770.     BaseDocument*        (*BbGetDocument                )(BaseDrawHelp *bb);
  1771.     BaseTag*                (*BbGetActiveTag            )(BaseDrawHelp *bb);
  1772.     Matrix                    (*BbGetMg                            )(BaseDrawHelp *bb);
  1773.     void                        (*BbGetDisplay                )(BaseDrawHelp *bb, BaseContainer *bc);
  1774.  
  1775.     BaseObject*            (*GetSceneCamera            )(BaseDraw *bd, BaseDocument *doc);
  1776.     void                        (*LineCS                            )(BaseDraw *bd, const Vector &p1, const Vector &p2, Bool clip2d, Bool clipz,Bool offset);
  1777.     Vector                    (*GetObjectColor            )(BaseDraw *bd, BaseObject *op, BaseDrawHelp *bh);
  1778. };
  1779.  
  1780. struct C4D_BaseView
  1781. {
  1782.     void                        (*GetFrame                        )(BaseView *bv, LONG *cl, LONG *ct, LONG *cr, LONG *cb);
  1783.     void                        (*GetSafeFrame                )(BaseView *bv, LONG *from, LONG *to, LONG *horizontal);
  1784.     void                        (*GetParameter                )(BaseView *bv, Vector *offset, Vector *scale, Vector *scale_z);
  1785.     Matrix                    (*GetMg                                )(BaseView *bv);
  1786.     Matrix                    (*GetMi                                )(BaseView *bv);
  1787.     LONG                        (*GetProjection                )(BaseView *bv);
  1788.     Bool                        (*TestPoint                        )(BaseView *bv, Real x, Real y);
  1789.     Bool                        (*TestPointZ                    )(BaseView *bv, const Vector &p);
  1790.     Bool                        (*TestClipping3D            )(BaseView *bv, const Vector &mp, const Vector &rad, const Matrix &mg, Bool *clip2d, Bool *clipz);
  1791.     Bool                        (*ClipLine2D                    )(BaseView *bv, Vector *p1, Vector *p2);
  1792.     Bool                        (*ClipLineZ                        )(BaseView *bv, Vector *p1, Vector *p2);
  1793.     Vector                    (*WS                                    )(BaseView *bv, const Vector &p);
  1794.     Vector                    (*SW                                    )(BaseView *bv, const Vector &p);
  1795.     Vector                    (*SW_R                                )(BaseView *bv, Real x, Real y, const Vector &wp);
  1796.     Vector                    (*WC                                    )(BaseView *bv, const Vector &p);
  1797.     Vector                    (*CW                                    )(BaseView *bv, const Vector &p);
  1798.     Vector                    (*SC                                    )(BaseView *bv, const Vector &p);
  1799.     Vector                    (*CS                                    )(BaseView *bv, const Vector &p, Bool z_inverse);
  1800.     Vector                    (*WC_V                                )(BaseView *bv, const Vector &v);
  1801.     Vector                    (*CW_V                                )(BaseView *bv, const Vector &v);
  1802.     Bool                        (*BackfaceCulling            )(BaseView *bv, const Vector &n, const Vector &p);
  1803.     Bool                        (*ZSensitive                    )(BaseView *bv);
  1804. };
  1805.  
  1806. struct C4D_Pool
  1807. {
  1808.     MemoryPool*            (*Alloc                                )(LONG block_size);
  1809.     void                        (*Free                                )(MemoryPool *pool);
  1810.     void*                        (*AllocElement                )(MemoryPool *pool, LONG size, Bool clear);
  1811.     void                        (*FreeElement                    )(MemoryPool *pool, void *mem, LONG size);
  1812.     void*                        (*AllocElementS                )(MemoryPool *pool, LONG size, Bool clear);
  1813.     void                        (*FreeElementS                )(MemoryPool *pool, void *mem);
  1814. };
  1815.  
  1816. struct C4D_General
  1817. {
  1818.     void*                        (*AllocEx                            )(LONG size);
  1819.     void                        (*Free                                )(void *data);
  1820.     void                        (*Print                                )(const String *str);
  1821.  
  1822.     Bool                        (*FExist                            )(const Filename *name, Bool isdir);
  1823.     Bool                        (*SearchFile                    )(const Filename *directory, const Filename *name, Filename *found);
  1824.     Bool                        (*FKill                                )(const Filename *name, Bool isdir);
  1825.     Bool                        (*FCopyFile                        )(const Filename *source, const Filename *dest, Bool overwrite);
  1826.     Bool                        (*FRename                            )(const Filename *source, const Filename *dest);
  1827.     Bool                        (*FCreateDir                    )(const Filename *name);
  1828.     Bool                        (*ExecuteFile                    )(const Filename *path);
  1829.     Filename*                (*GetStartupPath            )(void);
  1830.     Bool                        (*ExecuteProgram      )(const Filename *program, const Filename *file);
  1831.  
  1832.     void                        (*ShowMouse                        )(LONG v);
  1833.     void                        (*GetSysTime                    )(LONG *year, LONG *month, LONG *day, LONG *hour, LONG *minute, LONG *second);
  1834.     LONG                        (*GetTimer                        )(void);
  1835.     void                        (*GetLineEnd                    )(String *str);
  1836.     LONG                        (*GetDefaultFPS                )(void);
  1837.     LONG                        (*OutString                        )(const String *str, LONG flags);
  1838.     LONG                        (*GetCurrentOS                )(void);
  1839.     LONG                        (*GetByteOrder                )(void);
  1840.     void                        (*GetGray                            )(LONG *r, LONG *g, LONG *b);
  1841.     Bool                        (*ChooseColor                    )(Vector *col);
  1842.     void                        (*GetSerialInfoEx            )(String *s1, String *s2, String *s3, String *s4, String *s5, String *s6);
  1843.     Bool                        (*RegisterPluginEx        )(LONG api_version, LONG type, LONG id,String *str,void *data);
  1844.     void                        (*GetNewMarkerEx            )(ULONG *l1, ULONG *l2);
  1845.     void                        (*SetMousePointer            )(LONG l);
  1846.     Bool                        (*ShowBitmap1                    )(const Filename *fn);
  1847.     Bool                        (*ShowBitmap2                    )(BaseBitmap *bm);
  1848.     void                        (*StopAllThreads            )(void);
  1849.     void                        (*StatusClear                    )(void);
  1850.     void                        (*StatusSetSpin                )(void);
  1851.     void                        (*StatusSetBar                )(LONG p);
  1852.     void                        (*StatusSetText                )(const String *str);
  1853.     void                        (*SpecialEventAdd            )(LONG type, ULONG p1, ULONG p2);
  1854.     Bool                        (*DrawViews                        )(LONG flags);
  1855.     void*                        (*SendModelingCommandEx)(LONG command, BaseDocument *doc, BaseObject *op, const BaseContainer *bc, LONG mode);
  1856.     void                        (*GetGlobalTexturePath)(LONG i, Filename *fn);
  1857.     void                        (*SetGlobalTexturePath)(LONG i, const Filename *fn);
  1858.     Bool                        (*GenerateTexturePathEx)(const Filename *docpath, const Filename *srcname, Filename *dstname);
  1859.     void                        (*FlushTextureEx            )(const String *name);
  1860.     void                        (*FlushUnusedTextures    )(void);
  1861.     void                        (*GetWorldContainer        )(BaseContainer *bc);
  1862.     void                        (*ErrorStringDialog   )(LONG type, Real x, Real y, LONG is);
  1863.  
  1864.     void                        (*lSwap                                )(void *adr, LONG cnt);
  1865.     void                        (*wSwap                                )(void *adr, LONG cnt);
  1866.     void                        (*lIntel                            )(void *adr, LONG cnt);
  1867.     void                        (*wIntel                            )(void *adr, LONG cnt);
  1868.     void                        (*lMotor                            )(void *adr, LONG cnt);
  1869.     void                        (*wMotor                            )(void *adr, LONG cnt);
  1870.  
  1871.     void                        (*InsertBaseDocument    )(BaseDocument *doc);
  1872.     void                        (*SetActiveDocument        )(BaseDocument *doc);
  1873.     BaseDocument*        (*GetActiveDocument        )(void);
  1874.     BaseDocument*        (*GetFirstDocument        )(void);
  1875.     void                        (*KillDocument                )(BaseDocument *doc);
  1876.     Bool                        (*LoadFile                        )(const Filename *name);
  1877.     Bool                        (*LoadDocument                )(BaseDocument *doc, const Filename *name, Bool show_error);
  1878.     Bool                        (*SaveDocument                )(BaseDocument *doc, const Filename *name, Bool show_error, LONG format);
  1879.     LONG                        (*RenderDocument            )(BaseDocument *doc, ProgressHook *pr, void *private_data, BaseBitmap *bmp, const BaseContainer *rdata, LONG renderflags, Bool dummy, BaseThread *th, LONG v_left, LONG v_top, LONG v_right, LONG v_bottom);
  1880.     Vector                    (*GetColor                        )(LONG i);
  1881.     Bool                        (*RegisterPlugin            )(LONG api_version, LONG type, LONG id, const String *str,void *data,LONG datasize);
  1882.     void                        (*GetSerialInfo                )(LONG type, String *s1, String *s2, String *s3, String *s4, String *s5, String *s6);
  1883.     LONG                        (*GetVersionType            )(void);
  1884.     void                        (*FlushTexture                )(const Filename *docpath, const String *name);
  1885.     Bool                        (*ReadPluginInfo            )(LONG pluginid, CHAR *buffer, LONG size);
  1886.     Bool                        (*WritePluginInfo            )(LONG pluginid, CHAR *buffer, LONG size);
  1887.  
  1888.     void                        (*EwDrawXORLine                )(EditorWindow *win, LONG x1,LONG y1,LONG x2,LONG y2);
  1889.     void                        (*EwMouseDragStart        )(EditorWindow *win, LONG button,Real mx,Real my,LONG flag);
  1890.     LONG                        (*EwMouseDrag                    )(EditorWindow *win, Real *mx,Real *my,BaseContainer *channels);
  1891.     LONG                        (*EwMouseDragEnd            )(EditorWindow *win);
  1892.     Bool                        (*EwBfGetInputState        )(EditorWindow *win, LONG askdevice,LONG askchannel,BaseContainer *res);
  1893.     Bool                        (*EwBfGetInputEvent        )(EditorWindow *win, LONG askdevice,BaseContainer *res);
  1894.  
  1895.     Bool                        (*GetMovieInfo                )(const Filename *name, LONG *frames, LONG *fps);
  1896.     LONG                        (*ShowPopupMenu       )(CDialog *parent,LONG screenx,LONG screeny,const BaseContainer *bc,LONG flags);
  1897.  
  1898.     Bool                        (*RegistryAdd         )(LONG sub_id, LONG main_id, void *data);
  1899.     Bool                        (*RegistryRemove      )(LONG sub_id, LONG main_id);
  1900.     Registry*                (*RegistryFind                )(LONG sub_id, LONG main_id);
  1901.     Registry*                (*RegistryFindLast        )(LONG main_id);
  1902.     Registry*                (*RegistryFindFirst        )(LONG main_id);
  1903.     Registry*                (*RegistryFindPrev        )(Registry *last);
  1904.     Registry*                (*RegistryFindNext        )(Registry *last);
  1905.     Bool                        (*RegistryGetAutoID        )(LONG *id);
  1906.     Bool                        (*RegistryGetData            )(Registry *reg, LONG *main_id, LONG *sub_id, void **data);
  1907.  
  1908.     void*                        (*Alloc                                )(LONG size,LONG line,const CHAR *file);
  1909.     void                        (*Boom                                )(void);
  1910.     BaseContainer*    (*GetWorldPluginData  )(LONG id);
  1911.     Bool                        (*SetWorldPluginData  )(LONG id, const BaseContainer *bc, Bool add);
  1912.     Bool            (*SyncMessage         )(LONG message, LONG core_id, LONG par1, LONG par2);
  1913.     void                        (*SetWorldContainer        )(const BaseContainer *bc);
  1914.     Bool                        (*PluginMessage                )(LONG id, void *data);
  1915.  
  1916.     BasePlugin*            (*FindPlugin                                        )(LONG id, LONG type);
  1917.     BasePlugin*            (*GetFirstPlugin                                )(void);
  1918.     void*                        (BasePlugin::*GetPluginStructure)();
  1919.     Filename                (BasePlugin::*GetFilename                )(void);
  1920.     LONG                        (BasePlugin::*GetID                            )(void);
  1921.     LONG                        (BasePlugin::*GetInfo                        )(void);
  1922.  
  1923.     Bool                        (*ChooseFont                    )(BaseContainer *col);
  1924.  
  1925.     void                        (*GeDebugBreak                )(LONG line, const CHAR *file);
  1926.     void                        (*GeDebugOut                    )(const CHAR* s,...);
  1927.     Bool                        (*RenameDialog                )(String *str);
  1928.     Bool                        (*OpenHTML                        )(const String &webaddress);
  1929.     Bool                        (*SendModelingCommand )(LONG command, ModelingCommandData &data);
  1930.  
  1931.     void                        (*EventAdd                        )(LONG flags);
  1932.     void                        (*FindInManager                )(BaseList2D *bl);
  1933.  
  1934.     CUSTOMDATATYPEPLUGIN*        (*FindCustomDataTypePlugin        )(LONG type);
  1935.     RESOURCEDATATYPEPLUGIN*    (*FindResourceDataTypePlugin    )(LONG type);
  1936.  
  1937.     void                        (*GeSleep                            )(LONG milliseconds);
  1938.     GeData                    (*SendCoreMessage            )(LONG coreid, const BaseContainer &msg, LONG eventid);
  1939.     Bool                        (*CheckIsRunning            )(LONG type);
  1940.     BaseContainer*    (*GetWorldContainerInstance)(void);
  1941.  
  1942.     Bool                        (*GenerateTexturePath )(const Filename &docpath, const Filename &srcname, const Filename &suggestedpath, Filename *dstname);
  1943.     Bool                        (*IsInSearchPath            )(const Filename &texfilename, const Filename &docpath);
  1944. };
  1945.  
  1946. struct C4D_Link
  1947. {
  1948.     BaseLink*                (*Alloc                                )(void);
  1949.     void                        (*Free                                )(BaseLink *link);
  1950.     BaseList2D*            (*GetLink                            )(BaseLink *link, BaseDocument *doc, LONG instanceof);
  1951.     void                        (*SetLink                            )(BaseLink *link, BaseList2D *list);
  1952.     Bool                        (*Read                                )(BaseLink *link, HyperFile *hf);
  1953.     Bool                        (*Write                                )(BaseLink *link, HyperFile *hf);
  1954.     BaseLink*                (*GetClone                        )(BaseLink *link, LONG flags, AliasTrans *trn);
  1955.     Bool                        (*CopyTo                            )(BaseLink *src, BaseLink *dst, LONG flags, AliasTrans *trn);
  1956.     AliasTrans*            (*TrnAlloc                        )(void);
  1957.     Bool                        (*TrnInit                            )(AliasTrans *trn, BaseDocument *doc);
  1958.     void                        (*TrnFree                            )(AliasTrans *trn);
  1959.     void                        (*TrnTranslate                )(AliasTrans *trn, Bool connect_oldgoals);    
  1960.     BaseList2D*            (*ForceGetLink                )(BaseLink *link);
  1961. };
  1962.  
  1963. struct C4D_Neighbor
  1964. {
  1965.     EnumerateEdges*    (*Alloc                                )(LONG pcnt, Polygon *vadr, LONG vcnt, BaseSelect *bs);
  1966.     void                        (*Free                                )(EnumerateEdges *nb);
  1967.     void                        (*GetEdgePolys                )(EnumerateEdges *nb, LONG a, LONG b,LONG *first,LONG *second);
  1968.     void                        (*GetPointPolys                )(EnumerateEdges *nb, LONG pnt, LONG **dadr, LONG *dcnt);
  1969.     LONG                        (*GetEdgeCount                )(EnumerateEdges *nb);
  1970.     PolyInfo*                (*GetPolyInfo                    )(EnumerateEdges *nb, LONG poly);
  1971. };
  1972.  
  1973. struct C4D_Painter
  1974. {
  1975.     void*                        (*SendPainterCommand  )(LONG command, BaseDocument *doc, PaintTexture *tex, const BaseContainer *bc);
  1976.     Bool                        (*OptimalMappingEx        )(PMStruct *pm_adr, Polygon *vadr, LONG vcnt, Vector *padr, LONG pcnt, Bool progressbar, const BaseContainer *bc);
  1977.  
  1978.     // new in BP2
  1979.     Bool                        (*CallUVCommand                )(Vector *padr, LONG PointCount, Polygon *polys, LONG lPolyCount, UVWStruct *uvw, BaseSelect *polyselection,
  1980.                                             BaseSelect* pointselection, BaseObject*op, LONG mode, LONG cmdid, const BaseContainer &settings);
  1981.  
  1982.     TempUVHandle*        (*GetActiveUVSet            )(BaseDocument* doc, LONG flags);
  1983.     void                        (*FreeActiveUVSet            )(TempUVHandle *handle);
  1984.  
  1985.     LONG                        (*UVSetGetMode                )(TempUVHandle *handle);
  1986.     Vector*                    (*UVSetGetPoint                )(TempUVHandle *handle);
  1987.     LONG                        (*UVSetGetPointCount    )(TempUVHandle *handle);
  1988.     Polygon*                (*UVSetGetPoly                )(TempUVHandle *handle);
  1989.     LONG                        (*UVSetGetPolyCount        )(TempUVHandle *handle);
  1990.     UVWStruct*            (*UVSetGetUVW                    )(TempUVHandle *handle);
  1991.     BaseSelect*            (*UVSetGetPolySel            )(TempUVHandle *handle);
  1992.     BaseSelect*            (*UVSetGetPointSel        )(TempUVHandle *handle);
  1993.     BaseObject*            (*UVSetGetBaseObject    )(TempUVHandle *handle);
  1994.  
  1995.     Bool                        (*UVSetSetUVW                    )(TempUVHandle *handle, UVWStruct *uv);
  1996.  
  1997.     Bool                        (*Private1                        )(LONG lCommand, AtomArray* pArray, BaseSelect **polyselection,BaseContainer& setttings);
  1998.  
  1999.     PaintTexture*        (*CreateNewTexture        )(const Filename &path, const BaseContainer &settings);
  2000.     Bool                        (*GetTextureDefaults    )(LONG channel,BaseContainer &settings);
  2001.  
  2002.     Bool                        (*UVSetIsEditable            )(TempUVHandle *handle);
  2003.  
  2004.     LONG                        (*IdentifyImage                )(const Filename &texpath);
  2005. };
  2006.  
  2007. #define C4D_RADIOSITY_ID    1000969
  2008. #define C4D_CAUSTICS_ID        1000970
  2009.  
  2010. struct SSSData
  2011. {
  2012.     Vector    color;
  2013.     LONG        samples;
  2014.     Bool        multiscatter;
  2015.     Real        density,minthickness,strength;
  2016. };
  2017.  
  2018. struct C4D_Radiosity
  2019. {
  2020.     LONG disklevel,custom_id;
  2021.  
  2022.     Vector                    (*ComputeDiffuseIllumination)(VideoPostData *data, VolumeData *vd, Real receive_strength, Real accuracy);
  2023.     Bool                        (*LoadGI                                        )(VideoPostData *data, BaseFile *file, LONG disklevel);
  2024.     Bool                        (*SaveGI                                        )(VideoPostData *data, BaseFile *file);
  2025.     void                        (*FlushGI                                        )(VideoPostData *data);
  2026.  
  2027.     Vector                    (*ComputeSSS                              )(VolumeData *vd, SSSData *dat);
  2028. };
  2029.  
  2030. struct C4D_Caustics
  2031. {
  2032.     LONG disklevel,custom_id;
  2033.  
  2034.     Vector                    (*ComputeSurfaceCaustic         )(VideoPostData *data, VolumeData *vd, Real sampleradius, LONG accuracy);
  2035.     Vector                    (*ComputeVolumeCaustic             )(VideoPostData *data, const Vector &p);
  2036.     Bool                        (*LoadCS                                        )(VideoPostData *data, BaseFile *file, LONG disklevel);
  2037.     Bool                        (*SaveCS                                        )(VideoPostData *data, BaseFile *file);
  2038.     void                        (*FlushCS                                        )(VideoPostData *data);
  2039. };
  2040.  
  2041. struct OperatingSystem
  2042. {
  2043.     LONG version;
  2044.  
  2045.     C4D_General                *Ge;
  2046.     C4D_Shader                *Sh;
  2047.     C4D_HyperFile            *Hf;
  2048.     C4D_BaseContainer *Bc;
  2049.     C4D_String                *St;
  2050.     C4D_Bitmap                *Bm;
  2051.     C4D_MovieSaver        *Ms;
  2052.     C4D_BaseChannel        *Ba;
  2053.     C4D_Filename            *Fn;
  2054.     C4D_File                    *Fl;
  2055.     C4D_BrowseFiles        *Bf;
  2056.     C4D_Dialog                *Cd;
  2057.     C4D_UserArea            *Cu;
  2058.     C4D_Parser                *Pr;
  2059.     C4D_Resource            *Lr;
  2060.     C4D_BaseList            *Bl;
  2061.     C4D_Tag                        *Tg;
  2062.     C4D_Object                *Bo;
  2063.     C4D_Document            *Bd;
  2064.     C4D_Thread                *Bt;
  2065.     C4D_Material            *Mt;
  2066.     C4D_Texture                *Tx;
  2067.     C4D_BaseSelect        *Bs;
  2068.     C4D_Key                        *Bk;
  2069.     C4D_Sequence            *Bq;
  2070.     C4D_Track                    *Be;
  2071.     C4D_BaseSound            *Bu;
  2072.     C4D_BaseDraw            *Br;
  2073.     C4D_BaseView            *Bv;
  2074.     C4D_Neighbor            *Nb;
  2075.     C4D_Pool                    *Pl;
  2076.     C4D_BitmapFilter    *Fi;
  2077.     C4D_Painter                *Pa;
  2078.     C4D_Radiosity            *Ra;
  2079.     C4D_Caustics            *Cs;
  2080.     C4D_Link                    *Ln;
  2081.     C4D_GraphView            *Gv;
  2082.     C4D_GeData                *Gd;
  2083.     C4D_Atom                    *At;
  2084.     C4D_Coffee                *Co;
  2085. };
  2086.  
  2087. #ifndef __API_INTERN__
  2088.     #define C4DOS (*t_C4DOS)
  2089. #endif
  2090.  
  2091. extern OperatingSystem C4DOS;
  2092.  
  2093. #endif
  2094.