MCPcopy Create free account
hub / github.com/Kitware/VTK / EnableAnimation

Method EnableAnimation

IO/Geometry/vtkGLTFReader.cxx:921–936  ·  view source on GitHub ↗

------------------------------------------------------------------------------

Source from the content-addressed store, hash-verified

919
920//------------------------------------------------------------------------------
921void vtkGLTFReader::EnableAnimation(vtkIdType animationIndex)
922{
923 if (this->AnimationSelection == nullptr)
924 {
925 vtkErrorMacro("Error accessing animations: model is not loaded yet");
926 return;
927 }
928 if (animationIndex < 0 || animationIndex >= this->AnimationSelection->GetNumberOfArrays())
929 {
930 vtkErrorMacro("Out of range animation index");
931 return;
932 }
933 auto name = this->AnimationSelection->GetArrayName(animationIndex);
934 this->AnimationSelection->EnableArray(name);
935 this->Modified();
936}
937
938//------------------------------------------------------------------------------
939void vtkGLTFReader::DisableAnimation(vtkIdType animationIndex)

Callers 2

TestGLTFReaderAnimationFunction · 0.45

Calls 4

EnableArrayMethod · 0.80
GetNumberOfArraysMethod · 0.45
GetArrayNameMethod · 0.45
ModifiedMethod · 0.45

Tested by 2

TestGLTFReaderAnimationFunction · 0.36