home *** CD-ROM | disk | FTP | other *** search
/ Apple WWDC 1996 / WWDC96_1996 (CD).toast / Technology Materials / QuickTime VR / MacOS / QuickDraw™ 3D 1.0.6F4 SDK / Samples / SampleCode / CustomAttribute / CustomAttributesSupport.h < prev    next >
Encoding:
Text File  |  1995-11-11  |  2.2 KB  |  74 lines  |  [TEXT/MPCC]

  1. // Quickdraw 3D sample code
  2. //
  3. // Nick Thompson, AppleLink: DEVSUPPORT (devsupport@applelink.apple.com)
  4. //
  5. // ©1994-5 Apple Computer Inc., All Rights Reserved
  6.  
  7. #ifndef _MY3DSUPPORT_H_
  8. #define _MY3DSUPPORT_H_
  9.  
  10. // Macintosh System Stuff
  11. #include <Files.h>
  12. #include <Types.h>
  13. #include <Windows.h>
  14.  
  15. // QuickDraw 3D stuff
  16. #include "QD3D.h"
  17. #include "QD3DGroup.h"
  18. #include "QD3DErrors.h"
  19. #include "QD3DView.h"
  20. #include "QD3DPick.h"
  21.  
  22. //-------------------------------------------------------------------------------------------
  23.  
  24. struct _documentRecord {
  25.     TQ3ViewObject    fView ;                    // the view for the scene
  26.     TQ3GroupObject    fModel ;                // object in the scene being modelled
  27.     TQ3StyleObject    fInterpolation ;        // interpolation style used when rendering
  28.     TQ3StyleObject    fBackFacing ;            // whether to draw shapes that face away from the camera
  29.     TQ3StyleObject    fFillStyle ;            // whether drawn as solid filled object or decomposed to components
  30.     TQ3Matrix4x4        fRotation;            // the transform for the model
  31.     TQ3Point3D        fGroupCenter ;            // the center of the group (for rotation) 
  32.     float            fGroupScale    ;            // scaling factor to apply before drawing
  33.     
  34.     TQ3PickObject    fPickObject;
  35.     TQ3StringObject    fStringObject;
  36.     char            *fName;
  37.     
  38.     TQ3StringObject    fDescription;
  39.     char            *fDescString;
  40.     Str255            fURL;
  41.     
  42.     float            units;
  43.     
  44.     TQ3Boolean        launchNetscape;
  45. };
  46.  
  47. typedef struct _documentRecord DocumentRec, *DocumentPtr, **DocumentHdl ;
  48.  
  49. //---------------------------------------------------------------------------------------
  50.  
  51. OSErr MyQD3DInitialize( void ) ;
  52. OSErr MyQD3DExit() ;
  53.  
  54. TQ3ViewObject        MyNewView(WindowPtr theWindow) ;
  55. TQ3DrawContextObject    MyNewDrawContext( WindowPtr theWindow) ;
  56. TQ3CameraObject        MyNewCamera(WindowPtr theWindow) ;
  57. TQ3GroupObject        MyNewLights(void) ;
  58. TQ3GroupObject        MyNewModelFromFile(FSSpec *theFileSpec, DocumentPtr theDocument) ;
  59. TQ3Status SubmitScene( DocumentPtr theDocument ) ;
  60.  
  61. void AdjustCamera(
  62.     DocumentPtr            theDocument,
  63.     short                winWidth,
  64.     short                winHeight) ;
  65.     
  66. Boolean             MetafileFileSpecify( FSSpec *theFile ) ; 
  67. TQ3Status             MyReadModelFromFile( TQ3FileObject theFile,TQ3GroupObject myGroup, DocumentPtr theDocument) ;
  68.  
  69. void DisplayCustomAttributes(DocumentPtr theDocument);
  70.  
  71. Boolean OpenURL(char *name);
  72.  
  73. #endif
  74.