From ca31ec231cf6f251dad4fd51603424311ddf7884 Mon Sep 17 00:00:00 2001 From: David Rose Date: Wed, 26 Apr 2006 13:33:35 +0000 Subject: [PATCH] GeomVertexWriter now has a default constructor --- .../src/particlesystem/spriteParticleRenderer.cxx | 7 +------ panda/src/particlesystem/spriteParticleRenderer.h | 14 ++------------ 2 files changed, 3 insertions(+), 18 deletions(-) diff --git a/panda/src/particlesystem/spriteParticleRenderer.cxx b/panda/src/particlesystem/spriteParticleRenderer.cxx index 70e2d0d00d..62321ce936 100644 --- a/panda/src/particlesystem/spriteParticleRenderer.cxx +++ b/panda/src/particlesystem/spriteParticleRenderer.cxx @@ -505,12 +505,7 @@ init_geoms() { geom->add_primitive(_sprites[i][j]); // This will be overwritten in render(), but we had to have some initial value - // since there are no default constructors for GeomVertexWriter. - _sprite_writer[i].push_back(SpriteWriter(GeomVertexWriter(_vdata[i][j], InternalName::get_vertex()), - GeomVertexWriter(_vdata[i][j], InternalName::get_color()), - GeomVertexWriter(_vdata[i][j], InternalName::get_rotate()), - GeomVertexWriter(_vdata[i][j], InternalName::get_size()), - GeomVertexWriter(_vdata[i][j], InternalName::get_aspect_ratio()))); + _sprite_writer[i].push_back(SpriteWriter()); state = state->add_attrib(RenderModeAttrib::make(RenderModeAttrib::M_unchanged, _base_y_scale * _height, true)); if (anim->get_frame(j) != (Texture *)NULL) { diff --git a/panda/src/particlesystem/spriteParticleRenderer.h b/panda/src/particlesystem/spriteParticleRenderer.h index 67f88ff9eb..e2446d843b 100644 --- a/panda/src/particlesystem/spriteParticleRenderer.h +++ b/panda/src/particlesystem/spriteParticleRenderer.h @@ -45,18 +45,8 @@ class NodePath; //////////////////////////////////////////////////////////////////// class SpriteWriter { public: - SpriteWriter(GeomVertexWriter v, - GeomVertexWriter c, - GeomVertexWriter r, - GeomVertexWriter s, - GeomVertexWriter a): - vertex(v), - color(c), - rotate(r), - size(s), - aspect_ratio(a){ - }; - + SpriteWriter() { + } SpriteWriter(const SpriteWriter ©): vertex(copy.vertex), color(copy.color),