Class: Collada::Parser::Geometry

Inherits:
Object
  • Object
show all
Defined in:
lib/collada/parser/scene.rb,
lib/collada/parser/geometry.rb

Defined Under Namespace

Classes: Mesh

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(id, name, mesh, attributes) ⇒ Geometry

Returns a new instance of Geometry.



195
196
197
# File 'lib/collada/parser/scene.rb', line 195

def initialize(mesh)
	@mesh = mesh
end

Instance Attribute Details

#attributesObject (readonly)

Returns the value of attribute attributes.



223
224
225
# File 'lib/collada/parser/geometry.rb', line 223

def attributes
  @attributes
end

#idObject (readonly)

Returns the value of attribute id.



219
220
221
# File 'lib/collada/parser/geometry.rb', line 219

def id
  @id
end

#meshObject (readonly)

Returns the value of attribute mesh.



199
200
201
# File 'lib/collada/parser/scene.rb', line 199

def mesh
  @mesh
end

#nameObject (readonly)

Returns the value of attribute name.



220
221
222
# File 'lib/collada/parser/geometry.rb', line 220

def name
  @name
end

Class Method Details

.parse(doc, element) ⇒ Object



201
202
203
204
205
# File 'lib/collada/parser/scene.rb', line 201

def self.parse(doc, element)
	mesh = Mesh.parse(doc, element.elements['mesh'])
	
	self.new(mesh)
end