Class: Floorplanner::XML::Document
- Inherits:
-
Object
- Object
- Floorplanner::XML::Document
- Includes:
- ROXML
- Defined in:
- lib/floorplanner/xml.rb,
lib/floorplanner/collada_export.rb
Instance Method Summary collapse
Instance Method Details
#asset(refid) ⇒ Object
107 108 109 |
# File 'lib/floorplanner/xml.rb', line 107 def asset(refid) assets.detect { |a| a.id == refid } end |
#to_dae(thing, conf = {}) ⇒ Object
4 5 6 7 8 9 10 11 12 13 14 15 16 17 |
# File 'lib/floorplanner/collada_export.rb', line 4 def to_dae thing, conf={} @design = Floorplanner::Design.new(self) @design.build_geometries if thing.kind_of? String unless conf[:xrefs] @design.save_textures(File.dirname(thing)) end dae = File.new(thing,'w') dae.write @design.to_dae(conf) dae.close elsif thing.respond_to? :write thing.write @design.to_dae(conf) end end |