Main Page   Modules   Alphabetical List   Data Structures   Data Fields  

RwIm3d
[PS2All]


Functions

RxPipeline RwIm3DSkyGetPS2AllTransformPipeline (void)
RxPipeline RwIm3DSkyGetPS2AllRenderPipeline (RwPrimitiveType type)
RxPipeline RwIm3DSkyGetPS2AllMatPipeline (RwPrimitiveType type)
void  RwIm3DPS2AllGetMeshHeaderMeshCache (_rwIm3DPoolStash *stash, RxPS2AllPipeData *ps2AllPipeData)
void  RwIm3DPS2AllGatherObjMetrics (_rwIm3DPoolStash *stash)
void  RwIm3DPS2AllObjInstanceTest (RxPS2AllPipeData *ps2AllPipeData)
void  RwIm3DPS2AllTransformSetup (_rwIm3DPoolStash *stash, RwMatrix **transform)
void  RwIm3DPS2AllFrustumTest (_rwIm3DPoolStash *stash, RwFrustumTestResult *inFrustum)
void  RwIm3DPS2AllResEntryAlloc (RxPS2AllPipeData *ps2AllPipeData, RwResEntry **repEntry, RwUInt32 size, RwResEntryDestroyNotify destroyCallBack)
void  RwIm3DPS2AllGatherMeshMetrics (_rwIm3DPoolStash *stash, RxPS2AllPipeData *ps2AllPipeData)
RwBool  RwIm3DPS2AllObjectSetupCallBack (RxPS2AllPipeData *ps2AllPipeData, RwMatrix **transform)
RwResEntry RwIm3DPS2AllResEntryAllocCallBack (RxPS2AllPipeData *ps2AllPipeData, RwResEntry **repEntry, RwUInt32 size, RwResEntryDestroyNotify destroyCallBack)
RwBool  RwIm3DPS2AllInstanceCallBack (RxPS2AllPipeData *ps2AllPipeData, void **clusters, RwUInt32 numClusters)
RwBool  RwIm3DPS2AllBridgeCallBack (RxPS2AllPipeData *ps2AllPipeData)
RwBool  RwIm3DPS2AllPostMeshCallBack (RxPS2AllPipeData *ps2AllPipeData)
RwBool  RwIm3DPS2AllInstance (RxPS2AllPipeData *ps2AllPipeData)

Detailed Description

Platform-specific

Function Documentation

RwBool RwIm3DPS2AllBridgeCallBack RxPS2AllPipeData   ps2AllPipeData
 

RwIm3DPS2AllBridgeCallBack is the RxPipelineNodePS2AllMatBridgeCallBack used in the default RenderWare RwIm3D render pipeline.

See RxPipelineNodePS2AllMatBridgeCallBack for an overview of this callback type. For RwIm3D, this default callback is composed of the following helper macros (of which you may use either or both in constructing your own replacement callback), in the order shown here (you should keep the same order, as explained in RpMeshPS2AllStartVIFUploads):

RpMeshPS2AllStartVIFUploads, RpMeshPS2AllGIFTagUpload, RpMeshPS2AllMatColUpload, RpMeshPS2AllSurfPropsUpload, RpMeshPS2AllClipInfoUpload, RpMeshPS2AllVU1CodeIndexSetup, RpMeshPS2AllVU1CodeUpload, RpMeshPS2AllEndVIFUploads

Note that the only difference between this list and that of RpMeshPS2AllBridgeCallBack is the omission here of any texture setup. All renderstate persists through RwIm3D render calls, whereas RpAtomic or RpWorldSector render calls will change texture renderstate dependent on materials (RwIm3D does not use materials).

Parameters:
ps2AllPipeData  A pointer to a RxPS2AllPipeData struct containing information relevant to the current pipeline execution
Returns:
TRUE on success, FALSE otherwise
See also:
RxPipelineNodePS2AllMatMeshInstanceTestCallBack , RpMeshPS2AllStartVIFUploads, , RpMeshPS2AllGIFTagUpload, , RpMeshPS2AllMatColUpload, , RpMeshPS2AllSurfPropsUpload, , RpMeshPS2AllClipInfoUpload, , RpMeshPS2AllVU1CodeIndexSetup, , RpMeshPS2AllVU1CodeUpload, , RpMeshPS2AllEndVIFUploads
void RwIm3DPS2AllFrustumTest _rwIm3DPoolStash *    stash,
RwFrustumTestResult   inFrustum
 

RwIm3DPS2AllFrustumTest is a macro to test RwIm3D geometry against the current camera's view frustum to determine if clipping is necessary.

This is a helper macro which is called from the default RxPipelineNodePS2AllObjectSetupCallBack for RwIm3D, RwIm3DPS2AllObjectSetupCallBack. It simply checks whether the flags passed to RwIm3DTransform contained rwIM3D_NOCLIP or not. It may be used in constructing user callbacks.

This macro will be a function in a debug build, but it may be used explicitly in macro form through the name RwIm3DPS2AllFrustumTestMacro and in function form through RwIm3DPS2AllFrustumTestFunc, depending on how you wish to balance code size and function call overheads.

Parameters:
stash  A pointer to the current _rwIm3DPoolStash
inFrustum  A pointer to a RwFrustumTestResult to receive the result of a frustum test on the RwIm3D geometry
See also:
RwIm3DPS2AllObjectSetupCallBack , RxPipelineNodePS2AllObjectSetupCallBack
void RwIm3DPS2AllGatherMeshMetrics _rwIm3DPoolStash *    stash,
RxPS2AllPipeData   ps2AllPipeData
 

RwIm3DPS2AllGatherMeshMetrics is a macro to gather metrics information on RwIm3D rendering.

This is a helper macro which is called from the default RxPipelineNodePS2AllMatPostMeshCallBack for RwIm3D, RwIm3DPS2AllPostMeshCallBack. It gathers metrics information on the current RwIm3D render (though in non-RWMETRICS builds, the macro will boil away to nothing during compilation). Note that it currently only counts triangles, not other primitives. It may be used in constructing user callbacks.

This macro will be a function in a debug build, but it may be used explicitly in macro form through the name RwIm3DPS2AllGatherMeshMetricsMacro and in function form through RwIm3DPS2AllGatherMeshMetricsFunc, depending on how you wish to balance code size and function call overheads.

Parameters:
stash  A pointer to the current _rwIm3DPoolStash
ps2AllPipeData  A pointer to a RxPS2AllPipeData struct containing information relevant to the current pipeline execution
See also:
RwIm3DPS2AllPostMeshCallBack , RxPipelineNodePS2AllMatPostMeshCallBack
void RwIm3DPS2AllGatherObjMetrics _rwIm3DPoolStash *    stash
 

RwIm3DPS2AllGatherObjMetrics is a macro to gather metrics information for RwIm3D rendering.

This is a helper macro which is called from the default RxPipelineNodePS2AllObjectSetupCallBack for RwIm3D, RwIm3DPS2AllObjectSetupCallBack. It gathers metrics information from the current _rwIm3DPoolStash (though in non-RWMETRICS builds, the macro will boil away to nothing during compilation). It may be used in constructing user callbacks.

This macro will be a function in a debug build, but it may be used explicitly in macro form through the name RwIm3DPS2AllGatherObjMetricsMacro and in function form through RwIm3DPS2AllGatherObjMetricsFunc, depending on how you wish to balance code size and function call overheads.

Parameters:
stash  A pointer to the current _rwIm3DPoolStash
See also:
RwIm3DPS2AllObjectSetupCallBack , RxPipelineNodePS2AllObjectSetupCallBack
void RwIm3DPS2AllGetMeshHeaderMeshCache _rwIm3DPoolStash *    stash,
RxPS2AllPipeData   ps2AllPipeData
 

RwIm3DPS2AllGetMeshHeaderMeshCache is a macro to set up an RpMeshHeader and RwMeshCache for RwIm3D rendering.

This is a helper macro which is called from the default RxPipelineNodePS2AllObjectSetupCallBack for RwIm3D, RwIm3DPS2AllObjectSetupCallBack. It fills in the meshHeader and meshCache fields of the RxPS2AllPipeData struct, using a fake, RpMaterial, RwMeshCache and RpMeshHeader to do so (since there are no such structures in RwIm3D rendering). It may be used in constructing user callbacks.

This macro will be a function in a debug build, but it may be used explicitly in macro form through the name RpWorldSectorPS2AllGetMeshHeaderMeshCacheMacro and in function form through RpWorldSectorPS2AllGetMeshHeaderMeshCacheFunc, depending on how you wish to balance code size and function call overheads.

Parameters:
stash  A pointer to the current _rwIm3DPoolStash
ps2AllPipeData  A pointer to a RxPS2AllPipeData struct containing information relevant to the current pipeline execution
See also:
RwIm3DPS2AllObjectSetupCallBack , RxPipelineNodePS2AllObjectSetupCallBack
RwBool RwIm3DPS2AllInstance RxPS2AllPipeData   ps2AllPipeData
 

RwIm3DPS2AllInstance instances RwIm3D primitives.

Parameters:
ps2AllPipeData  A pointer to a RxPS2AllPipeData struct containing information relevant to the current pipeline execution
Returns:
TRUE on success, FALSE otherwise
RwBool RwIm3DPS2AllInstanceCallBack RxPS2AllPipeData   ps2AllPipeData,
void **    clusters,
RwUInt32    numClusters
 

RwIm3DPS2AllInstanceCallBack is the RxPipelineNodePS2AllMatInstanceCallBack used in the default RenderWare RwIm3D render pipeline.

See RxPipelineNodePS2AllMatInstanceCallBack for an overview of this callback type. For RwIm3D, this default callback just calls RwIm3DPS2AllInstance, since no user instancing is performed.

Parameters:
ps2AllPipeData  A pointer to a RxPS2AllPipeData struct containing information relevant to the current pipeline execution
clusters  An array of void pointers to the data of visible clusters
numClusters  The length of the clusterData array
Returns:
TRUE on success, FALSE otherwise
See also:
RxPipelineNodePS2AllMatInstanceCallBack
RwBool RwIm3DPS2AllObjectSetupCallBack RxPS2AllPipeData   ps2AllPipeData,
RwMatrix **    transform
 

RwIm3DPS2AllObjectSetupCallBack is the RxPipelineNodePS2AllObjectSetupCallBack used in the default RenderWare RwIm3D render pipeline.

See RxPipelineNodePS2AllObjectSetupCallBack for an overview of this callback type. For RwIm3D, this default callback is composed of the following helper macros (of which you may use some or all to construct your own replacement callback), in the order shown here (try and keep this order, some macros rely on the results of prior ones):

Parameters:
ps2AllPipeData  A pointer to a RxPS2AllPipeData struct containing information relevant to the current pipeline execution
transform  A pointer to a pointer to a transform matrix
Returns:
TRUE on success, FALSE to prematurely terminate the pipeline
See also:
RxPipelineNodePS2AllObjectSetupCallBack , RwIm3DPS2AllGetMeshHeaderMeshCache , RwIm3DPS2AllGatherObjMetrics , RwIm3DPS2AllObjInstanceTest , RwIm3DPS2AllTransformSetup , RwIm3DPS2AllFrustumTest , RpAtomicPS2AllPrimTypeTransTypeSetup
void RwIm3DPS2AllObjInstanceTest RxPS2AllPipeData   ps2AllPipeData
 

RwIm3DPS2AllObjInstanceTest is a macro to ensure that full instancing occurs during RwIm3D rendering.

This is a helper macro which is called from the default RxPipelineNodePS2AllObjectSetupCallBack for RwIm3D, RwIm3DPS2AllObjectSetupCallBack. It simply sets the objInstance identifier of the RxPS2AllPipeData struct to rxINSTANCEFULLINSTANCE, since full instancing must occur for every RwIm3D render. It may be used in constructing user callbacks.

This macro will be a function in a debug build, but it may be used explicitly in macro form through the name RwIm3DPS2AllObjInstanceTestMacro and in function form through RwIm3DPS2AllObjInstanceTestFunc, depending on how you wish to balance code size and function call overheads.

Parameters:
ps2AllPipeData  A pointer to a RxPS2AllPipeData struct containing information relevant to the current pipeline execution
See also:
RwIm3DPS2AllObjectSetupCallBack , RxPipelineNodePS2AllObjectSetupCallBack
RwBool RwIm3DPS2AllPostMeshCallBack RxPS2AllPipeData   ps2AllPipeData
 

RwIm3DPS2AllPostMeshCallBack is the RxPipelineNodePS2AllMatPostMeshCallBack used in the default RenderWare RwIm3D render pipeline.

See RxPipelineNodePS2AllMatPostMeshCallBack for an overview of this callback type. For RwIm3D, this default callback (only actually used in RWMETRICS builds) is composed of the following helper macro (which you may use in constructing your own replacement callback):

Parameters:
ps2AllPipeData  A pointer to a RxPS2AllPipeData struct containing information relevant to the current pipeline execution
Returns:
TRUE on success, FALSE otherwise
See also:
RxPipelineNodePS2AllMatPostMeshCallBack , RwIm3DPS2AllGatherMeshMetrics
void RwIm3DPS2AllResEntryAlloc RxPS2AllPipeData   ps2AllPipeData,
RwResEntry **    repEntry,
RwUInt32    size,
RwResEntryDestroyNotify    destroyCallBack
 

RwIm3DPS2AllResEntryAlloc is a macro to allocate space for the instance data of RwIm3D rendering.

This is a helper macro which is called from the default RxPipelineNodePS2AllMatResEntryAllocCallBack for RwIm3D, RwIm3DPS2AllResEntryAllocCallBack. It allocates the space required using an internal double buffer area (appropriate for RwIm3D because we know that the memory will be freed, after one use, in the order in which it is allocated), the maximum possible allocation size from which is half the value passed to _rwDMAPreAlloc() (the default value is 1MB - as an allocation nears half the maximum size, it is more likely to cause a buffer swap, which will slow the system down). It may be used in constructing user callbacks.

This macro will be a function in a debug build, but it may be used explicitly in macro form through the name RwIm3DPS2AllResEntryAllocMacro and in function form through RwIm3DPS2AllResEntryAllocFunc, depending on how you wish to balance code size and function call overheads.

Parameters:
ps2AllPipeData  A pointer to a RxPS2AllPipeData struct containing information relevant to the current pipeline execution
repEntry  A pointer to a pointer to a RwResEntry
size  A RwUInt32 value specifying the size in bytes of the memory block to allocate (excluding the RwResEntry header).
destroyCallBack  A RwResEntryDestroyNotify callback (see RwResourcesFreeResEntry)
See also:
RwIm3DPS2AllResEntryAllocCallBack , RxPipelineNodePS2AllMatResEntryAllocCallBack
RwResEntry* RwIm3DPS2AllResEntryAllocCallBack RxPS2AllPipeData   ps2AllPipeData,
RwResEntry **    repEntry,
RwUInt32    size,
RwResEntryDestroyNotify    destroyCallBack
 

RwIm3DPS2AllResEntryAllocCallBack is the RxPipelineNodePS2AllMatResEntryAllocCallBack used in the default RenderWare RwIm3D render pipeline.

See RxPipelineNodePS2AllMatResEntryAllocCallBack for an overview of this callback type. For RwIm3D, this default callback is composed of the following helper macro (which you may use in constructing your own replacement callback):

RwIm3DPS2AllResEntryAlloc

Parameters:
ps2AllPipeData  A pointer to a RxPS2AllPipeData struct containing information relevant to the current pipeline execution.
repEntry  A pointer to a pointer to a RwResEntry
size  A RwUInt32 value specifying the size in bytes of the memory block to allocate (excluding the RwResEntry header).
destroyCallBack  A RwResEntryDestroyNotify callback (see RwResourcesFreeResEntry)
Returns:
TRUE on success, FALSE otherwise
See also:
RxPipelineNodePS2AllMatResEntryAllocCallBack , RwIm3DPS2AllResEntryAlloc
void RwIm3DPS2AllTransformSetup _rwIm3DPoolStash *    stash,
RwMatrix **    transform
 

RwIm3DPS2AllTransformSetup is a macro to set up the transformation matrix for RwIm3D rendering.

This is a helper macro which is called from the default RxPipelineNodePS2AllObjectSetupCallBack for RwIm3D, RwIm3DPS2AllObjectSetupCallBack. It concatenates the matrix passed to RwIm3DTransform (if none was passed, it uses the identity matrix) with the current camera's view matrix (see RwCameraGetViewMatrix) and stores the result in the matrix passed in. It may be used in constructing user callbacks.

This macro will be a function in a debug build, but it may be used explicitly in macro form through the name RwIm3DPS2AllTransformSetupMacro and in function form through RwIm3DPS2AllTransformSetupFunc, depending on how you wish to balance code size and function call overheads.

Parameters:
stash  A pointer to the current _rwIm3DPoolStash
transform  A pointer to a pointer to the RwMatrix holding the object-space to camera-space transform for the current RpWorldSector
See also:
RwIm3DPS2AllObjectSetupCallBack , RxPipelineNodePS2AllObjectSetupCallBack
RxPipeline* RwIm3DSkyGetPS2AllMatPipeline RwPrimitiveType    type
 

RwIm3DSkyGetPS2AllMatPipeline returns a pointer to the default immediate mode PS2AllMat material render pipeline.

The PS2AllMat (see RxNodeDefinitionGetPS2AllMat) Im3D material render pipeline for PlayStation 2 is shown below.

This pipeline is used behind the scenes from within the default Im3D PS2All render pipeline. See RwIm3DSkyGetPS2AllRenderPipeline for details.

The PS2AllMat Im3D render pipeline (for all primitive types):

PS2AllMat.csl

The callbacks used for the PS2AllMat.csl node are:

Parameters:
type  RwPrimitiveType of the pipeline to fetch.
Returns:
Returns pointer to the pipeline if successful or NULL if there is an error.
See also:
RxNodeDefinitionGetPS2AllMat , RxPipelineNodePS2AllMatResEntryAllocCallBack , RxPipelineNodePS2AllMatInstanceCallBack , RxPipelineNodePS2AllMatBridgeCallBack , RxPipelineNodePS2AllMatPostMeshCallBack , RxNodeDefinitionGetPS2All , RwIm3DSkyGetPS2AllRenderPipeline , RwIm3DSkyGetPS2AllTransformPipeline , RwIm3DGetGenericTransformPipeline , RwIm3DGetGenericRenderPipeline , RwIm3DRenderIndexedPrimitive , RwIm3DRenderPrimitive , RwIm3DRenderTriangle , RwIm3DRenderLine , RwIm3DTransform , RwIm3DEnd , RwIm3DGetRenderPipeline , RwIm3DGetRenderPipeline , RwIm3DSetRenderPipeline , RwIm3DGetTransformPipeline , RwIm3DGetTransformPipeline , RwIm3DSetTransformPipeline
RxPipeline* RwIm3DSkyGetPS2AllRenderPipeline RwPrimitiveType    type
 

RwIm3DSkyGetPS2AllRenderPipeline returns a pointer to the default immediate mode PS2All render pipeline.

The PS2All (see RxNodeDefinitionGetPS2All) Im3D render pipeline for PlayStation 2 is shown below.

The Im3D render pipelines (in fact one pipeline can render all supported primitive types except rwPRIMTYPEPOINTLIST for which you will need to supply your own vector code) are by default based on the PS2All.csl node.

Note that this pipeline uses mesh grouping (see RxPipelineNodePS2AllGroupMeshes), which means that it always calls the same material pipeline - this can be retrieved through RwIm3DSkyGetPS2AllMatPipeline. Object pipelines (and we're treating an Im3D render pipeline as an object instance+render pipeline) based on PS2All.csl must be paired with material pipelines based on PS2AllMat.csl. See RxNodeDefinitionGetPS2All and RxNodeDefinitionGetPS2AllMat for further details.

This pipeline is intended for use with the PS2All Im3D transform pipeline (see RwIm3DSkyGetPS2AllTransformPipeline).

If you wish to submit 2D triangles through Submit.csl (i.e you want to do transformation and lighting and whatever else CPU-side - which will of course be very slow) then rather than use this Im3D transform pipeline, you should use a generic (non-PlayStation 2-specific) one. N.B. the PS2All Im3D transform pipe must be paired with PS2All render pipes and vice versa! Do not change one and not the other.

The PS2All Im3D render pipeline (for all primitive types):

PS2All.csl

The callbacks used for the PS2All.csl node are:

RwIm3DPS2AllObjectSetupCallBack (RxPipelineNodePS2AllObjectSetupCallBack)

Parameters:
type  RwPrimitiveType of the pipeline to fetch.
Returns:
Returns pointer to the pipeline if successful or NULL if there is an error.
See also:
RxNodeDefinitionGetPS2All , RxPipelineNodePS2AllObjectSetupCallBack , RxNodeDefinitionGetPS2AllMat , RwIm3DSkyGetPS2AllMatPipeline , RwIm3DSkyGetPS2AllTransformPipeline , RwIm3DGetGenericTransformPipeline , RwIm3DGetGenericRenderPipeline , RwIm3DRenderIndexedPrimitive , RwIm3DRenderPrimitive , RwIm3DRenderTriangle , RwIm3DRenderLine , RwIm3DTransform , RwIm3DEnd , RwIm3DGetRenderPipeline , RwIm3DGetRenderPipeline , RwIm3DSetRenderPipeline , RwIm3DGetTransformPipeline , RwIm3DGetTransformPipeline , RwIm3DSetTransformPipeline
RxPipeline* RwIm3DSkyGetPS2AllTransformPipeline void   
 

RwIm3DSkyGetPS2AllTransformPipeline returns a pointer to the default immediate mode transform PS2All pipeline.

The PS2All (see RxNodeDefinitionGetPS2All) Im3D transform pipeline does very little work, it just sets up a copy of the source vertices for the RwIm3DRender*() functions to work with and also caches the flags and transformation matrix.

If you wish to submit 2D triangles through Submit.csl (i.e you want to do transformation and lighting and whatever else CPU-side - which will of course be very slow) then rather than use this Im3D transform pipeline, you should use a generic (non-PlayStation 2-specific) one. N.B. the PS2All Im3D transform pipe must be paired with PS2All render pipes and vice versa! Do not change one and not the other.

The world plugin must be attached before using this function (for now, this is an RpWorld overload of the Im3D functionality, using RpWorld technology - PS2All.csl - to speed it up).

The PS2All Im3D transform pipeline:

    PS2Im3DFastTransform.csl
   
Returns:
Returns pointer to the pipeline if successful or NULL if there is an error.
See also:
RwIm3DSkyGetPS2AllRenderPipeline , RwIm3DSkyGetPS2AllMatPipeline , RwIm3DGetGenericTransformPipeline , RwIm3DGetGenericRenderPipeline , RwIm3DTransform , RwIm3DEnd , RwIm3DRenderIndexedPrimitive , RwIm3DRenderPrimitive , RwIm3DRenderTriangle , RwIm3DRenderLine , RwIm3DGetTransformPipeline , RwIm3DGetTransformPipeline , RwIm3DSetTransformPipeline , RwIm3DGetRenderPipeline , RwIm3DGetRenderPipeline , RwIm3DSetRenderPipeline

Criterion Software © 1993-2003 Criterion Software Limited. All rights reserved. Built Tue Apr 22 12:46:22 2003. Send Feedback
Converted from CHM to HTML with chm2web Pro 2.85 (unicode)