Copyright ©1995 by NeXT Computer, Inc. All Rights Reserved.
| 17 |
3D Graphics Kit
| Classes
N3DCamera |
| Inherits From: | View : Responder : Object |
| Initializing and Freeing |
| Initializes with 0 frame size | ||
| Initializes with specified frame size | ||
| Frees the N3DCamera |
| All Drawing |
| YES if PostScript and RenderMan drawing lock on camera | ||
| Unlocks PostScript and RenderMan drawing | ||
| Performs all RIB and PostScript drawing |
| RenderMan Drawing |
| Renders the camera and any content shapes | ||
| Override to perform custom rendering in the camera | ||
| Sets the receiver to invoke flushRIB within render | ||
| Tests whether the receiver invokes flushRIB within render | ||
| Waits until all RIB code has been rendered |
| PostScript Drawing |
| Override to perform custom PostScript drawing |
| Background Color |
| Sets the NXColor filled behind all drawing | ||
| The NXColor filled behind all drawing | ||
| If flag is YES, fills color behind all drawing | ||
| YES if camera fills color behind all drawing |
| PostScript Transformation Management |
| Sets frame for both PostScript and RenderMan coordinate systems | ||
| Moves both PostScript and RenderMan coordinate systems | ||
| Moves both PostScript and RenderMan coordinate systems | ||
| Resizes both PostScript and RenderMan coordinate systems | ||
| Resizes both PostScript and RenderMan coordinate | ||
| Prevents rotation of PostScript coordinate system | ||
| Prevents rotation of PostScript coordinate system |
| Shape Hierarchy Management |
| Sets world shape | ||
| Returns world shape |
| Global Light Management |
| Adds an N3DLight to the camera's global light list | ||
| Removes an N3DLight to the camera's global light list | ||
| Returns the camera's global light list |
| Picking |
| Returns a List of N3DShapes in selectionRect |
| Projection Rectangle |
| Sets the 3D coordinate system projection rectangle | ||
| Returns the 3D coordinate system's projection | ||
| Selecting Projection Type |
| Sets the projection type | ||
| Returns the projection type |
| Pretransform Matrix |
| Sets the camera's pretransformation matrix | ||
| Returns the camera's pretransformation matrix | ||
| Sets the camera to use its pretransformation matrix | ||
| YES if camera uses its pretransformation matrix |
| Setting Viewpoint |
| Sets the eye-to-viewpoint vector and roll | ||
| Gets the eye-to-viewpoint vector and roll | ||
| Moves camera in its own coordinate system | ||
| Rotates the camera in its own coordinates | ||
| Clipping Planes |
| Sets the camera's near and far clipping planes | ||
| Returns the camera's near and far clipping planes | ||
| Field of View |
| Sets the viewing angle of the camera | ||
| Converts a focal length into a viewing angle for the camera | ||
| Returns the viewing angle of the camera |
| Pixel Aspect Ratio |
| Sets the pixel aspect ratio for the camera | ||
| Returns the pixel aspect ratio for the camera |
| Converting Coordinates |
| Converts an array of points to PostScript coordinates | ||
| Converts PostScript points to world coordinates | ||
| Crop Windows |
| Count of rectangle divisions for photoreal rendering | ||
| Returns rectangles representing horizontal strips of | ||
| Frame Number |
| Returns 1 |
| Printing |
| Returns YES |
| Copying RIB |
| Copies RIB code generated by the receiver |
| Setting World Attributes |
| Calls RiWorldBegin() | ||
| Calls RiWorldEnd() |
| Setting and Getting the Delegate |
| Sets the receiver's delegate | ||
| Returns the receiver's delegate |
| Setting the Hider |
| Returns the receiver's N3DHider | ||
| Sets the receiver's N3DHider |
| chooseHider:(BOOL)flag | Sets surface type for shapes in world shape hierarchy |
| Rendering Photorealistically |
| Begins rendering, returns identifier for rendering session | ||
| Begins rendering, returns identifier for rendering session |
| Archiving |
| Reads the camera from the stream | ||
| Writes the camera to the stream | ||
| Performs additional initialization after unarchiving |
| Methods Implemented by the Delegate |
| Handles images generated by photoreal rendering |
| didRenderStream:(NXStream *)imageStream methods tag:(int)theJob frameNumber:(int)currentFrame |
| N3DContextManager |
| Inherits From: | Object |
| Initializing and Freeing |
| + new | Returns (creating if necessary) one instance per application | |
| Destroys all contexts, frees the receiver |
| Getting the Main Context |
| Returns (creating if necessary) the application's main context |
| Creating Other Contexts |
| Creates a named context | ||
| Creates a named context for a specific renderer | ||
| Creates a named context on a file | ||
| Does nothing, returns NULL | ||
| Managing the Current Context |
| The application's current context | ||
| Sets the current context, returns previous context |
| Sets the current context by name, returns previous context |
| Destroying a Context |
| Destroys the context |
| Destroys a context with name |
| Archiving |
| Performs additional initialization after unarchiving |
| N3DLight |
| Inherits From: | N3DShape : Object |
| Initializing |
| Initializes the receiver as an N3D_AmbientLight |
| Setting Light Type |
| Sets the receiver's light type | ||
| Returns the receiver's light type | ||
| Sets type N3D_AmbientLight with appropriate parameter | ||
| Sets type N3D_PointLight with appropriate | ||
| Sets type N3D_PointLight with appropriate | ||
| Sets type N3D_SpotLight with appropriate parameters | ||
| Setting Light Parameters |
| Sets the from point | ||
| Sets the from and to points | ||
| Returns the from and to points | ||
| Sets the cone angle, cone delta, and beam distribution | ||
| Gets the cone angle, cone delta, and beam distribution | ||
| Sets the intensity | ||
| Returns the intensity |
| Rendering |
| Renders the light as a local light | ||
| Renders the light as a global light |
| Global Light Management |
| Override to add behavior on becoming/resigning global | ||
| YES if light is global |
| Switching On and Off |
| If flag is YES, turns receiver on |
| Setting Color |
| Sets the receiver's color | ||
| Returns the receiver's color |
| Archiving |
| Reads the receiver from the stream | ||
| Writes the receiver to the stream | ||
| Performs additional initialization after unarchiving |
| N3DMovieCamera |
| Inherits From: | N3DCamera : View : Responder : Object |
| Initializing |
| Initializes the receiver |
| RenderMan Drawing |
| Renders current frame; if printing, renders current page |
| Interactive Display |
| Displays movie, first frame to last, onscreen |
| Frame Numbers |
| Sets the current frame number | ||
| Returns the current frame number | ||
| Sets counters for movie | ||
| Returns the first frame number | ||
| Returns the last frame number | ||
| Returns the frame increment |
| Archiving |
| Reads the receiver from the stream | ||
| Writes the receiver to the stream | ||
| Performs additional initialization after unarchiving |
| N3DRenderPanel |
| Inherits From: | Panel : Window : Responder : Object |
| Initializing the Class |
| + initialize | Initializes the class with data from the defaults database | |
| + new | Creates, if necessary, and returns an N3DRenderPanel |
| Setting Accessory View |
| Returns the accessory view | ||
| Sets the accessory view |
| Running Modal |
| Presents the render panel in a model loop |
| Resolution |
| Returns the resolution set by the user in the panel |
| Host Management |
| Returns the number of hosts selected by the user | ||
| Returns an array of strings for selected host names |
| Browser Delegate Method |
| Fills the panel's browser with host names | ||
| N3DRIBImageRep |
| Inherits From: | NXImageRep : Object |
| Initializing and Freeing |
| Initializes the receiver from a file | ||
| Initializes the receiver from a stream | ||
| Frees the receiver |
| Declaring Data Types |
| + (const char *const *)imageUnfilteredFileTypes | Returns supported file types |
| + (const NXAtom *)imageUnfilteredPasteboardTypes |
| Returns supported pasteboard types |
| + (BOOL)canLoadFromStream:(NXStream *)theStream |
| Tests theStream for RIB data |
| Drawing |
| Returns YES if the image is successfully drawn at point | ||
| Returns YES if the image is successfully drawn in rect | ||
| Returns YES if the image is successfully drawn |
| Size |
| Returns the rectangle that bounds the image | ||
| Returns the size of the image |
| Background Color |
| Returns the background color | ||
| Sets the background color |
| Hidden Surface Removal Type |
| Returns the hider type for rendering images | ||
| Sets the hider type for rendering images |
| Surface Type |
| Sets the surface type used for rendering images | ||
| Returns the surface type used for rendering images |
| Archiving |
| Reads the receiver from the stream | ||
| Writes the receiver to the stream |
| N3DRotator |
| Inherits From: | Object |
| Initializing |
| Initializes the receiver | ||
| Initializes the receiver and sets its camera |
| Setting Parameters |
| Sets the receiver's camera | ||
| Sets the receiver's center point and radius | ||
| Axes of Rotation |
| Sets the axes about which the receiver rotates | ||
| Returns the axis about which the receiver rotates |
| Mouse Tracking |
| Accepts two points in camera coordinates, returns | ||
| Archiving |
| Reads the receiver from the stream | ||
| Writes the receiver to the stream |
| N3DShader |
| Inherits From: | Object |
| Initializing and Freeing |
| Initializes the receiver with no shader file | ||
| Initializes the receiver with a shader file | ||
| Frees the receiver |
| Shader Language Object File |
| Sets the receiver's shader | ||
| Returns the receiver's shader |
| Shader Color |
| Sets the receiver's color | ||
| Returns the receiver's color | ||
| Sets the receiver to apply its color | ||
| YES if receiver applies color |
| Shader Transparency |
| Sets the receiver's transparency | ||
| Returns the receiver's transparency |
| Shader Function Argument Handling |
| The number of arguments for the shader function | ||
| The name of the indicated argument |
| The type of the named argument |
| YES if argName is an argument to the shader function | ||
| Sets the specified argument to the specified value | ||
| Sets the specified argument to the specified value | ||
| Sets the specified argument to the specified value | ||
| Sets the specified argument to the specified value | ||
| Gets the specified value for the specified argument | ||
| Gets the specified value for the specified argument | ||
| Gets the specified value for the specified argument | ||
| Gets the specified value for the specified argument | ||
| Resets the specified argument to its default value |
| Shader Type |
| Returns the type of the shader |
| Setting |
| Applies the shader function during rendering |
| Archiving |
| Reads the receiver from the stream | ||
| Writes the receiver to the stream |
| N3DShape |
| Inherits From: | Object |
| Initializing and Freeing |
| Initializes and returns the receiver | ||
| Frees the receiver and its descendants | ||
| Frees the receiver, its next peer and its descendants |
| Rendering the N3DShape |
| Renders the shape and its descendants | ||
| Override to implement actual rendering | ||
| Renders only the shape's bounding box |
| Traversing the Shape Hierarchy |
| Returns the shape "to the right" | ||
| Returns the shape "to the left" | ||
| Returns the shape "to the far left" of receiver's peer group | ||
| Returns the shape "to the far right" of receiver's peer group | ||
| Returns the shape "below" the receiver | ||
| Returns the farthest descendant below the receiver | ||
| Returns the shape "above the receiver | ||
| Returns the shape at the top of the receiver's hierarchy | ||
| YES if the receiver is at the top of its hierarchy |
| Managing the Shape Hierarchy |
| Inserts aPeer between receiver and its next peer | ||
| Inserts aDescendant between receiver and its descendant | ||
| Sets receiver's ancestor, returns previous ancestor | ||
| Unlinks the receiver, reconnects peers and descendants | ||
| Makes the receiver a descendant of anAncestor | ||
| Removes receiver from hierarchy, promotes descendant |
| Shader |
| Sets an N3DShader for the shape | ||
| Returns the N3DShader of type |
| Surface |
| Returns the receiver's surface type | ||
| Sets receiver's surface type; if flag is YES, sets descendants | ||
| surface types |
| Bounding Box |
| Returns by reference the receiver's bounding box | ||
| Sets the receiver to draw only its bounding box | ||
| YES if the receiver draws only its bounding box | ||
| Returns the rectangle representing the receiver's | ||
| Converting Points |
| Converts points from the receiver's coordinate system | ||
| Converts points from an ancestor's coordinate system | ||
| Converts points from the receiver's coordinate system | ||
| Selectability |
| Sets whether the receiver can be selected | ||
| YES if the receiver can be selected |
| Visibility |
| Sets the receiver to render when renderSelf: is invoked | ||
| YES if receiver renders when renderSelf: is invoked |
| Naming Shapes |
| Sets the name of the shape | ||
| Returns the name of the shape |
| Delegate for Rendering |
| Sets the rendering delegate for the receiver | ||
| Removes and returns the render delegate | ||
| Returns the render delegate |
| Transformation Matrices |
| Sets the receiver's transformation matrix |
| Returns the receiver's transformation matrix | ||
| Multiplies the transform matrix with theMatrix, | ||
| relativeToAncestor:(N3DShape *)theAncestor |
| Returns the matrix representing the transformation between theAncestor's space and the receiver's |
| relativeToAncestor:(N3DShape *)theAncestor |
| Returns the matrix representing the transformation between the receiver's space and theAncestor's |
| Rotation, Scaling, Translation |
| Rotates the receiver about its origin and the point | ||
| Premultiplies the rotation of the receiver about its | ||
| Scales the receiver | ||
| Scales the receiver, premultiplying the transformation | ||
| Scales the receiver uniformly in all axes | ||
| Scales the receiver uniformly in all axes, premuliplying the transformation | ||
| Translates the receiver | ||
| Translates the receiver, premultiplying the | ||
| transformation | ||
| Archiving |
| Reads the camera from the stream | ||
| Writes the camera to the stream | ||
| Performs additional initialization after unarchiving |