Sha256: cf4b8d68ddbc0ab2b5eb53dd752cb8c8def8dc8bbc41876749893c42785b56ae

Contents?: true

Size: 629 Bytes

Versions: 7

Compression:

Stored size: 629 Bytes

Contents

require 'mittsu/extras/geometries/plane_buffer_geometry'

module Mittsu
  class PlaneGeometry < Geometry
    def initialize(width, height, width_segments = 1, height_segments = 1)
      puts 'Mittsu::PlaneGeometry: Consider using Mittsu::PlaneBufferGeometry for lower memory footprint.'

      super()

      @type = 'PlaneGeometry'

      @parameters = {
        width:           width,
        height:          height,
        width_segments:  width_segments,
        height_segments: height_segments
      }

      from_buffer_geometry(PlaneBufferGeometry.new(width, height, width_segments, height_segments))
    end
  end
end

Version data entries

7 entries across 7 versions & 1 rubygems

Version Path
mittsu-0.5.0 lib/mittsu/extras/geometries/plane_geometry.rb
mittsu-0.4.1 lib/mittsu/extras/geometries/plane_geometry.rb
mittsu-0.4.0 lib/mittsu/extras/geometries/plane_geometry.rb
mittsu-0.3.3 lib/mittsu/extras/geometries/plane_geometry.rb
mittsu-0.3.2 lib/mittsu/extras/geometries/plane_geometry.rb
mittsu-0.3.1 lib/mittsu/extras/geometries/plane_geometry.rb
mittsu-0.3.0 lib/mittsu/extras/geometries/plane_geometry.rb