Changed cache->Prepare() to cache->GetModel()
This commit is contained in:
parent
c0fcb15e3a
commit
eab70be17b
|
@ -626,7 +626,7 @@ void S3D_CACHE::ClosePlugins( void )
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
S3DMODEL* S3D_CACHE::Prepare( const wxString& aModelFileName )
|
S3DMODEL* S3D_CACHE::GetModel( const wxString& aModelFileName )
|
||||||
{
|
{
|
||||||
S3D_CACHE_ENTRY* cp = NULL;
|
S3D_CACHE_ENTRY* cp = NULL;
|
||||||
SCENEGRAPH* sp = load( aModelFileName, &cp );
|
SCENEGRAPH* sp = load( aModelFileName, &cp );
|
||||||
|
@ -644,7 +644,7 @@ S3DMODEL* S3D_CACHE::Prepare( const wxString& aModelFileName )
|
||||||
if( cp->renderData )
|
if( cp->renderData )
|
||||||
return cp->renderData;
|
return cp->renderData;
|
||||||
|
|
||||||
S3DMODEL* mp = S3D::Prepare( sp );
|
S3DMODEL* mp = S3D::GetModel( sp );
|
||||||
cp->renderData = mp;
|
cp->renderData = mp;
|
||||||
|
|
||||||
return mp;
|
return mp;
|
||||||
|
|
|
@ -183,14 +183,14 @@ public:
|
||||||
void ClosePlugins( void );
|
void ClosePlugins( void );
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Function Prepare
|
* Function GetModel
|
||||||
* attempts to load the scene data for a model and to translate it
|
* attempts to load the scene data for a model and to translate it
|
||||||
* into an S3D_MODEL structure for display by a renderer
|
* into an S3D_MODEL structure for display by a renderer
|
||||||
*
|
*
|
||||||
* @param aModelFileName is the full path to the model to be loaded
|
* @param aModelFileName is the full path to the model to be loaded
|
||||||
* @return is a pointer to the render data or NULL if not available
|
* @return is a pointer to the render data or NULL if not available
|
||||||
*/
|
*/
|
||||||
S3DMODEL* Prepare( const wxString& aModelFileName );
|
S3DMODEL* GetModel( const wxString& aModelFileName );
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif // CACHE_3D_H
|
#endif // CACHE_3D_H
|
||||||
|
|
|
@ -581,7 +581,7 @@ void PANEL_PREV_3D::UpdateModelName( wxString const& aModelName )
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
model = m_ModelManager->Prepare( modelInfo.filename );
|
model = m_ModelManager->GetModel( modelInfo.filename );
|
||||||
|
|
||||||
if( NULL == model )
|
if( NULL == model )
|
||||||
{
|
{
|
||||||
|
@ -679,7 +679,7 @@ void PANEL_PREV_3D::updateOrientation( wxCommandEvent &event )
|
||||||
|
|
||||||
canvas->Clear3DModel();
|
canvas->Clear3DModel();
|
||||||
|
|
||||||
model = m_ModelManager->Prepare( modelInfo.filename );
|
model = m_ModelManager->GetModel( modelInfo.filename );
|
||||||
|
|
||||||
if( model )
|
if( model )
|
||||||
{
|
{
|
||||||
|
|
|
@ -304,7 +304,7 @@ SGNODE* S3D::ReadCache( const wxString& aFileName )
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
S3DMODEL* S3D::Prepare( SCENEGRAPH* aNode )
|
S3DMODEL* S3D::GetModel( SCENEGRAPH* aNode )
|
||||||
{
|
{
|
||||||
if( NULL == aNode )
|
if( NULL == aNode )
|
||||||
return NULL;
|
return NULL;
|
||||||
|
|
|
@ -130,13 +130,13 @@ namespace S3D
|
||||||
// of data structures for rendering
|
// of data structures for rendering
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Function Prepare
|
* Function GetModel
|
||||||
* creates an S3DMODEL representation of aNode (raw data, no transforms)
|
* creates an S3DMODEL representation of aNode (raw data, no transforms)
|
||||||
*
|
*
|
||||||
* @param aNode is the node to be transcribed into an S3DMODEL representation
|
* @param aNode is the node to be transcribed into an S3DMODEL representation
|
||||||
* @return an S3DMODEL representation of aNode on success, otherwise NULL
|
* @return an S3DMODEL representation of aNode on success, otherwise NULL
|
||||||
*/
|
*/
|
||||||
SGLIB_API S3DMODEL* Prepare( SCENEGRAPH* aNode );
|
SGLIB_API S3DMODEL* GetModel( SCENEGRAPH* aNode );
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Function Destroy3DModel
|
* Function Destroy3DModel
|
||||||
|
|
Loading…
Reference in New Issue