GeomVertexWriter now has a default constructor
This commit is contained in:
parent
ddd1046462
commit
ca31ec231c
|
|
@ -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) {
|
||||
|
|
|
|||
|
|
@ -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),
|
||||
|
|
|
|||
Loading…
Reference in New Issue