Class: Rgltf::Validation::RootAssetExtensions

Inherits:
Rule
  • Object
show all
Defined in:
lib/rgltf/validation/root_asset_extensions.rb

Constant Summary collapse

ROOT_ARRAYS =
%w[accessors animations buffers bufferViews cameras images materials meshes nodes
samplers scenes skins textures extensionsUsed extensionsRequired].freeze

Instance Method Summary collapse

Methods inherited from Rule

#initialize

Constructor Details

This class inherits a constructor from Rgltf::Validation::Rule

Instance Method Details

#validateObject



9
10
11
12
13
14
15
# File 'lib/rgltf/validation/root_asset_extensions.rb', line 9

def validate
  validate_root_arrays
  validate_asset
  validate_extensions
  validate_extension_shapes(@json)
  reference('scenes', @json['scene'], 'scene') if @json.key?('scene')
end