本文整理汇总了C++中CFacePoserModel::GetModel方法的典型用法代码示例。如果您正苦于以下问题:C++ CFacePoserModel::GetModel方法的具体用法?C++ CFacePoserModel::GetModel怎么用?C++ CFacePoserModel::GetModel使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类CFacePoserModel
的用法示例。
在下文中一共展示了CFacePoserModel::GetModel方法的11个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: GetEntry
StudioModel *IFaceposerModels::GetStudioModel( int index )
{
CFacePoserModel *m = GetEntry( index );
if ( !m )
return NULL;
if ( !m->GetModel() )
return NULL;
return m->GetModel();
}
示例2: CheckResetFlexes
void IFaceposerModels::CheckResetFlexes( void )
{
int current_render_frame = g_MDLViewer->GetCurrentFrame();
if ( current_render_frame == m_nLastRenderFrame )
return;
m_nLastRenderFrame = current_render_frame;
// the phoneme editor just adds to the face, so reset the controllers
int c = Count();
for ( int i = 0; i < c; i++ )
{
CFacePoserModel *m = GetEntry( i );
if ( !m )
continue;
StudioModel *model = m->GetModel();
if ( !model )
continue;
CStudioHdr *hdr = model->GetStudioHdr();
if ( !hdr )
continue;
for ( LocalFlexController_t i = LocalFlexController_t(0); i < hdr->numflexcontrollers(); i++ )
{
model->SetFlexController( i, 0.0f );
}
}
}
示例3: CheckResetFlexes
void IFaceposerModels::CheckResetFlexes( void )
{
int current_render_frame = g_MDLViewer->GetCurrentFrame();
if ( current_render_frame == m_nLastRenderFrame )
return;
m_nLastRenderFrame = current_render_frame;
int c = Count();
for ( int i = 0; i < c; i++ )
{
CFacePoserModel *m = GetEntry( i );
if ( !m )
continue;
StudioModel *model = m->GetModel();
if ( !model )
continue;
studiohdr_t *hdr = model->getStudioHeader();
if ( !hdr )
continue;
for ( int i = 0; i < hdr->numflexcontrollers; i++ )
{
model->SetFlexController( i, 0.0f );
}
}
}
示例4: GetIndexForStudioModel
int IFaceposerModels::GetIndexForStudioModel( StudioModel *model )
{
int c = Count();
for ( int i = 0; i < c; i++ )
{
CFacePoserModel *m = GetEntry( i );
if ( !m )
continue;
if ( m->GetModel() == model )
return i;
}
return -1;
}
示例5: FreeModel
void IFaceposerModels::FreeModel( int index )
{
CFacePoserModel *entry = GetEntry( index );
if ( !entry )
return;
StudioModel *m = entry->GetModel();
m->FreeModel();
delete m;
m_Models.Remove( index );
g_MDLViewer->InitModelTab();
}
示例6: Count
StudioModel *IFaceposerModels::GetModelForActor( char const *actorname )
{
int c = Count();
for ( int i = 0; i < c; i++ )
{
CFacePoserModel *m = GetEntry( i );
if ( !m )
continue;
if ( !stricmp( m->GetActorName(), actorname ) )
return m->GetModel();
}
return NULL;
}
示例7: SetSolveHeadTurn
void IFaceposerModels::SetSolveHeadTurn( int solve )
{
int c = Count();
for ( int i = 0; i < c; i++ )
{
CFacePoserModel *m = GetEntry( i );
if ( !m )
continue;
StudioModel *mdl = m->GetModel();
if ( !mdl )
continue;
mdl->SetSolveHeadTurn( solve );
}
}
示例8: ClearModelTargets
void IFaceposerModels::ClearModelTargets( bool force /*=false*/ )
{
int c = Count();
for ( int i = 0; i < c; i++ )
{
CFacePoserModel *m = GetEntry( i );
if ( !m )
continue;
StudioModel *mdl = m->GetModel();
if ( !mdl )
continue;
mdl->ClearLookTargets();
}
}
示例9: ClearOverlaysSequences
void IFaceposerModels::ClearOverlaysSequences( void )
{
int c = Count();
for ( int i = 0; i < c; i++ )
{
CFacePoserModel *m = GetEntry( i );
if ( !m )
continue;
StudioModel *model = m->GetModel();
if ( !model )
continue;
model->ClearOverlaysSequences();
}
}
示例10: FreeModel
void IFaceposerModels::FreeModel( int index )
{
CFacePoserModel *entry = GetEntry( index );
if ( !entry )
return;
StudioModel *m = entry->GetModel();
SaveViewerSettings( m->GetFileName(), m );
m->FreeModel( false );
delete m;
delete entry;
m_Models.Remove( index );
g_MDLViewer->InitModelTab();
}
示例11: CountActiveSources
int IFaceposerModels::CountActiveSources()
{
int count = 0;
int c = Count();
for ( int i = 0; i < c; i++ )
{
CFacePoserModel *m = GetEntry( i );
if ( !m )
continue;
StudioModel *model = m->GetModel();
if ( !model )
continue;
count += model->m_mouth.GetNumVoiceSources();
}
return count;
}