Convert C-style casts to C++-style
class Renderable
{
+protected:
+ Renderable() { }
public:
+ virtual ~Renderable() { }
+
virtual bool has_pass(const Tag &tag) const =0;
virtual void render(const Tag &tag=Tag()) const =0;
};
protected:
Uniform() { }
public:
+ virtual ~Uniform() { }
+
virtual void apply(int) const =0;
};
if(size==1)
{
union { ubyte c[4]; float f; } u;
- u.c[0]=(ubyte)(cr*255);
- u.c[1]=(ubyte)(cg*255);
- u.c[2]=(ubyte)(cb*255);
- u.c[3]=(ubyte)(ca*255);
+ u.c[0]=static_cast<ubyte>(cr*255);
+ u.c[1]=static_cast<ubyte>(cg*255);
+ u.c[2]=static_cast<ubyte>(cb*255);
+ u.c[3]=static_cast<ubyte>(ca*255);
*+ptr++=u.f;
}
else