lib/mittsu/renderers/opengl/opengl_geometry_group.rb in mittsu-0.1.2 vs lib/mittsu/renderers/opengl/opengl_geometry_group.rb in mittsu-0.1.3
- old
+ new
@@ -55,20 +55,19 @@
end
end
def init_mesh_buffers(object)
geometry = object.geometry
- object_impl = object.implementation(@renderer)
nvertices = @faces3.length * 3
nvertices2 = nvertices * 2
nvertices3 = nvertices * 3
nvertices4 = nvertices * 4
ntris = @faces3.length * 1
nlines = @faces3.length * 3
- material = object_impl.buffer_material(self)
+ material = object.buffer_material(self)
@vertex_array = Array.new(nvertices3) # Float32Array
@normal_array = Array.new(nvertices3) # Float32Array
@color_array = Array.new(nvertices3) # Float32Array
@uv_array = Array.new(nvertices2) # Float32Array
@@ -157,13 +156,12 @@
def set_mesh_buffers(object, hint, should_dispose, material)
return unless @initted_arrays
geometry = object.geometry
- material_impl = material.implementation(@renderer)
- needs_face_normals = material_impl.needs_face_normals?
+ needs_face_normals = material.needs_face_normals?
vertex_index = 0
offset = 0
offset_uv = 0
@@ -752,12 +750,8 @@
@face_array = nil
@vertex_array = nil
@line_array = nil
@skin_index_array = nil
@skin_weight_array = nil
- end
-
- def implementation(_)
- self
end
end
end