Commit 0db93e29 authored by zmoelnig's avatar zmoelnig
Browse files

reinterpret_cast<t_method>

converted all the CCASTs to C++CASTS with:
for i in *.cpp
do
  sed -e 's|(t_method) *\([^ ]*\)\([,)]\)|reinterpret_cast<t_method>(\1)\2|' -i "${i}"
done

git-svn-id: https://pd-gem.svn.sourceforge.net/svnroot/pd-gem/trunk/Gem@3059 49b2a0ca-c541-4d49-a7ef-d785e4371512
parent ecbfb5f5
......@@ -125,13 +125,13 @@ void colorRGB :: obj_setupCallback(t_class *classPtr)
{
class_addcreator((t_newmethod)create_colorRGB,
gensym("colourRGB"), A_GIMME, A_NULL);
class_addmethod(classPtr, (t_method)&colorRGB::rMessCallback,
class_addmethod(classPtr, reinterpret_cast<t_method>(&colorRGB::rMessCallback),
gensym("rVal"), A_FLOAT, A_NULL);
class_addmethod(classPtr, (t_method)&colorRGB::gMessCallback,
class_addmethod(classPtr, reinterpret_cast<t_method>(&colorRGB::gMessCallback),
gensym("gVal"), A_FLOAT, A_NULL);
class_addmethod(classPtr, (t_method)&colorRGB::bMessCallback,
class_addmethod(classPtr, reinterpret_cast<t_method>(&colorRGB::bMessCallback),
gensym("bVal"), A_FLOAT, A_NULL);
class_addmethod(classPtr, (t_method)&colorRGB::aMessCallback,
class_addmethod(classPtr, reinterpret_cast<t_method>(&colorRGB::aMessCallback),
gensym("aVal"), A_FLOAT, A_NULL);
}
void colorRGB :: rMessCallback(void *data, t_floatarg val)
......
......@@ -85,7 +85,7 @@ void depth :: depthMess(int state)
/////////////////////////////////////////////////////////
void depth :: obj_setupCallback(t_class *classPtr)
{
class_addfloat(classPtr, (t_method)&depth::depthMessCallback);
class_addfloat(classPtr, reinterpret_cast<t_method>(&depth::depthMessCallback));
}
void depth :: depthMessCallback(void *data, t_floatarg state)
{
......
......@@ -87,7 +87,7 @@ void diffuse :: diffuseMess(float red, float green, float blue, float alpha)
/////////////////////////////////////////////////////////
void diffuse :: obj_setupCallback(t_class *classPtr)
{
class_addmethod(classPtr, (t_method)&diffuse::diffuseMessCallback,
class_addmethod(classPtr, reinterpret_cast<t_method>(&diffuse::diffuseMessCallback),
gensym("diffuse"), A_GIMME, A_NULL);
}
void diffuse :: diffuseMessCallback(void *data, t_symbol *, int argc, t_atom *argv)
......
......@@ -133,13 +133,13 @@ void diffuseRGB :: aMess(float val)
/////////////////////////////////////////////////////////
void diffuseRGB :: obj_setupCallback(t_class *classPtr)
{
class_addmethod(classPtr, (t_method)&diffuseRGB::rMessCallback,
class_addmethod(classPtr, reinterpret_cast<t_method>(&diffuseRGB::rMessCallback),
gensym("rVal"), A_FLOAT, A_NULL);
class_addmethod(classPtr, (t_method)&diffuseRGB::gMessCallback,
class_addmethod(classPtr, reinterpret_cast<t_method>(&diffuseRGB::gMessCallback),
gensym("gVal"), A_FLOAT, A_NULL);
class_addmethod(classPtr, (t_method)&diffuseRGB::bMessCallback,
class_addmethod(classPtr, reinterpret_cast<t_method>(&diffuseRGB::bMessCallback),
gensym("bVal"), A_FLOAT, A_NULL);
class_addmethod(classPtr, (t_method)&diffuseRGB::aMessCallback,
class_addmethod(classPtr, reinterpret_cast<t_method>(&diffuseRGB::aMessCallback),
gensym("aVal"), A_FLOAT, A_NULL);
}
void diffuseRGB :: rMessCallback(void *data, t_floatarg val)
......
......@@ -89,7 +89,7 @@ void emission :: emissionMess(float red, float green, float blue, float alpha)
/////////////////////////////////////////////////////////
void emission :: obj_setupCallback(t_class *classPtr)
{
class_addmethod(classPtr, (t_method)&emission::emissionMessCallback,
class_addmethod(classPtr, reinterpret_cast<t_method>(&emission::emissionMessCallback),
gensym("emission"), A_GIMME, A_NULL);
}
void emission :: emissionMessCallback(void *data, t_symbol *, int argc, t_atom *argv)
......
......@@ -135,13 +135,13 @@ void emissionRGB :: aMess(float val)
/////////////////////////////////////////////////////////
void emissionRGB :: obj_setupCallback(t_class *classPtr)
{
class_addmethod(classPtr, (t_method)&emissionRGB::rMessCallback,
class_addmethod(classPtr, reinterpret_cast<t_method>(&emissionRGB::rMessCallback),
gensym("rVal"), A_FLOAT, A_NULL);
class_addmethod(classPtr, (t_method)&emissionRGB::gMessCallback,
class_addmethod(classPtr, reinterpret_cast<t_method>(&emissionRGB::gMessCallback),
gensym("gVal"), A_FLOAT, A_NULL);
class_addmethod(classPtr, (t_method)&emissionRGB::bMessCallback,
class_addmethod(classPtr, reinterpret_cast<t_method>(&emissionRGB::bMessCallback),
gensym("bVal"), A_FLOAT, A_NULL);
class_addmethod(classPtr, (t_method)&emissionRGB::aMessCallback,
class_addmethod(classPtr, reinterpret_cast<t_method>(&emissionRGB::aMessCallback),
gensym("aVal"), A_FLOAT, A_NULL);
}
void emissionRGB :: rMessCallback(void *data, t_floatarg val)
......
......@@ -326,9 +326,9 @@ void glsl_geometry :: printInfo()
/////////////////////////////////////////////////////////
void glsl_geometry :: obj_setupCallback(t_class *classPtr)
{
class_addmethod(classPtr, (t_method)&glsl_geometry::openMessCallback,
class_addmethod(classPtr, reinterpret_cast<t_method>(&glsl_geometry::openMessCallback),
gensym("open"), A_SYMBOL, A_NULL);
class_addmethod(classPtr, (t_method)&glsl_geometry::printMessCallback,
class_addmethod(classPtr, reinterpret_cast<t_method>(&glsl_geometry::printMessCallback),
gensym("print"), A_NULL);
}
void glsl_geometry :: openMessCallback(void *data, t_symbol *filename)
......
......@@ -737,23 +737,23 @@ void glsl_program:: outverticesMess(GLint vertices) {
/////////////////////////////////////////////////////////
void glsl_program :: obj_setupCallback(t_class *classPtr)
{
class_addmethod(classPtr, (t_method)&glsl_program::shaderMessCallback,
class_addmethod(classPtr, reinterpret_cast<t_method>(&glsl_program::shaderMessCallback),
gensym("shader"), A_GIMME, A_NULL);
class_addmethod(classPtr, (t_method)&glsl_program::linkCallback,
class_addmethod(classPtr, reinterpret_cast<t_method>(&glsl_program::linkCallback),
gensym("link"), A_GIMME, A_NULL);
class_addmethod(classPtr, (t_method)&glsl_program::printMessCallback,
class_addmethod(classPtr, reinterpret_cast<t_method>(&glsl_program::printMessCallback),
gensym("print"), A_NULL);
class_addmethod(classPtr, (t_method)&glsl_program::intypeMessCallback,
class_addmethod(classPtr, reinterpret_cast<t_method>(&glsl_program::intypeMessCallback),
gensym("geometry_intype"), A_GIMME, A_NULL);
class_addmethod(classPtr, (t_method)&glsl_program::outtypeMessCallback,
class_addmethod(classPtr, reinterpret_cast<t_method>(&glsl_program::outtypeMessCallback),
gensym("geometry_outtype"), A_GIMME, A_NULL);
class_addmethod(classPtr, (t_method)&glsl_program::typeMessCallback,
class_addmethod(classPtr, reinterpret_cast<t_method>(&glsl_program::typeMessCallback),
gensym("geometry_type"), A_GIMME, A_NULL);
class_addmethod(classPtr, (t_method)&glsl_program::outverticesMessCallback,
class_addmethod(classPtr, reinterpret_cast<t_method>(&glsl_program::outverticesMessCallback),
gensym("geometry_outvertices"), A_FLOAT, A_NULL);
class_addanything(classPtr, (t_method)&glsl_program::paramMessCallback);
class_addanything(classPtr, reinterpret_cast<t_method>(&glsl_program::paramMessCallback));
}
void glsl_program :: shaderMessCallback(void *data, t_symbol *, int argc, t_atom *argv)
{
......
......@@ -332,9 +332,9 @@ void glsl_vertex :: printInfo()
/////////////////////////////////////////////////////////
void glsl_vertex :: obj_setupCallback(t_class *classPtr)
{
class_addmethod(classPtr, (t_method)&glsl_vertex::openMessCallback,
class_addmethod(classPtr, reinterpret_cast<t_method>(&glsl_vertex::openMessCallback),
gensym("open"), A_SYMBOL, A_NULL);
class_addmethod(classPtr, (t_method)&glsl_vertex::printMessCallback,
class_addmethod(classPtr, reinterpret_cast<t_method>(&glsl_vertex::printMessCallback),
gensym("print"), A_NULL);
}
void glsl_vertex :: openMessCallback(void *data, t_symbol *filename)
......
......@@ -102,8 +102,8 @@ void ortho :: compatMess(int state)
/////////////////////////////////////////////////////////
void ortho :: obj_setupCallback(t_class *classPtr)
{
class_addfloat (classPtr, (t_method)&ortho::orthoMessCallback);
class_addmethod(classPtr, (t_method)&ortho::compatMessCallback,
class_addfloat (classPtr, reinterpret_cast<t_method>(&ortho::orthoMessCallback));
class_addmethod(classPtr, reinterpret_cast<t_method>(&ortho::compatMessCallback),
gensym("compat"), A_FLOAT, A_NULL);}
void ortho :: orthoMessCallback(void *data, t_floatarg state)
{
......
......@@ -78,7 +78,7 @@ void polygon_smooth :: polygon_smoothMess(int polygon_smoothState)
/////////////////////////////////////////////////////////
void polygon_smooth :: obj_setupCallback(t_class *classPtr)
{
class_addfloat(classPtr, (t_method)&polygon_smooth::polygon_smoothMessCallback);
class_addfloat(classPtr, reinterpret_cast<t_method>(&polygon_smooth::polygon_smoothMessCallback));
}
void polygon_smooth :: polygon_smoothMessCallback(void *data, t_floatarg polygon_smoothState)
{
......
......@@ -100,9 +100,9 @@ void rotate :: vectorMess(float x, float y, float z)
/////////////////////////////////////////////////////////
void rotate :: obj_setupCallback(t_class *classPtr)
{
class_addmethod(classPtr, (t_method)&rotate::angleMessCallback,
class_addmethod(classPtr, reinterpret_cast<t_method>(&rotate::angleMessCallback),
gensym("ft1"), A_FLOAT, A_NULL);
class_addmethod(classPtr, (t_method)&rotate::vectorMessCallback,
class_addmethod(classPtr, reinterpret_cast<t_method>(&rotate::vectorMessCallback),
gensym("vector"), A_FLOAT, A_FLOAT, A_FLOAT, A_NULL);
}
void rotate :: angleMessCallback(void *data, t_floatarg angle)
......
......@@ -105,11 +105,11 @@ void rotateXYZ :: zMess(float val)
/////////////////////////////////////////////////////////
void rotateXYZ :: obj_setupCallback(t_class *classPtr)
{
class_addmethod(classPtr, (t_method)&rotateXYZ::xMessCallback,
class_addmethod(classPtr, reinterpret_cast<t_method>(&rotateXYZ::xMessCallback),
gensym("xVal"), A_FLOAT, A_NULL);
class_addmethod(classPtr, (t_method)&rotateXYZ::yMessCallback,
class_addmethod(classPtr, reinterpret_cast<t_method>(&rotateXYZ::yMessCallback),
gensym("yVal"), A_FLOAT, A_NULL);
class_addmethod(classPtr, (t_method)&rotateXYZ::zMessCallback,
class_addmethod(classPtr, reinterpret_cast<t_method>(&rotateXYZ::zMessCallback),
gensym("zVal"), A_FLOAT, A_NULL);
}
void rotateXYZ :: xMessCallback(void *data, t_floatarg val)
......
......@@ -99,9 +99,9 @@ void scale :: vectorMess(float x, float y, float z)
/////////////////////////////////////////////////////////
void scale :: obj_setupCallback(t_class *classPtr)
{
class_addmethod(classPtr, (t_method)&scale::distanceMessCallback,
class_addmethod(classPtr, reinterpret_cast<t_method>(&scale::distanceMessCallback),
gensym("ft1"), A_FLOAT, A_NULL);
class_addmethod(classPtr, (t_method)&scale::vectorMessCallback,
class_addmethod(classPtr, reinterpret_cast<t_method>(&scale::vectorMessCallback),
gensym("vector"), A_FLOAT, A_FLOAT, A_FLOAT, A_NULL);
}
void scale :: distanceMessCallback(void *data, t_floatarg distance)
......
......@@ -109,11 +109,11 @@ void scaleXYZ :: zMess(float val)
/////////////////////////////////////////////////////////
void scaleXYZ :: obj_setupCallback(t_class *classPtr)
{
class_addmethod(classPtr, (t_method)&scaleXYZ::xMessCallback,
class_addmethod(classPtr, reinterpret_cast<t_method>(&scaleXYZ::xMessCallback),
gensym("xVal"), A_FLOAT, A_NULL);
class_addmethod(classPtr, (t_method)&scaleXYZ::yMessCallback,
class_addmethod(classPtr, reinterpret_cast<t_method>(&scaleXYZ::yMessCallback),
gensym("yVal"), A_FLOAT, A_NULL);
class_addmethod(classPtr, (t_method)&scaleXYZ::zMessCallback,
class_addmethod(classPtr, reinterpret_cast<t_method>(&scaleXYZ::zMessCallback),
gensym("zVal"), A_FLOAT, A_NULL);
}
void scaleXYZ :: xMessCallback(void *data, t_floatarg val)
......
......@@ -84,7 +84,7 @@ void shearXY :: shearMess(float val)
/////////////////////////////////////////////////////////
void shearXY :: obj_setupCallback(t_class *classPtr)
{
class_addmethod(classPtr, (t_method)&shearXY::shearMessCallback,
class_addmethod(classPtr, reinterpret_cast<t_method>(&shearXY::shearMessCallback),
gensym("shearVal"), A_FLOAT, A_NULL);
}
void shearXY :: shearMessCallback(void *data, t_floatarg val)
......
......@@ -85,7 +85,7 @@ void shearXZ :: shearMess(float val)
/////////////////////////////////////////////////////////
void shearXZ :: obj_setupCallback(t_class *classPtr)
{
class_addmethod(classPtr, (t_method)&shearXZ::shearMessCallback,
class_addmethod(classPtr, reinterpret_cast<t_method>(&shearXZ::shearMessCallback),
gensym("shearVal"), A_FLOAT, A_NULL);
}
void shearXZ :: shearMessCallback(void *data, t_floatarg val)
......
......@@ -85,7 +85,7 @@ void shearYX :: shearMess(float val)
/////////////////////////////////////////////////////////
void shearYX :: obj_setupCallback(t_class *classPtr)
{
class_addmethod(classPtr, (t_method)&shearYX::shearMessCallback,
class_addmethod(classPtr, reinterpret_cast<t_method>(&shearYX::shearMessCallback),
gensym("shearVal"), A_FLOAT, A_NULL);
}
void shearYX :: shearMessCallback(void *data, t_floatarg val)
......
......@@ -85,7 +85,7 @@ void shearYZ :: shearMess(float val)
/////////////////////////////////////////////////////////
void shearYZ :: obj_setupCallback(t_class *classPtr)
{
class_addmethod(classPtr, (t_method)&shearYZ::shearMessCallback,
class_addmethod(classPtr, reinterpret_cast<t_method>(&shearYZ::shearMessCallback),
gensym("shearVal"), A_FLOAT, A_NULL);
}
void shearYZ :: shearMessCallback(void *data, t_floatarg val)
......
......@@ -85,7 +85,7 @@ void shearZX :: shearMess(float val)
/////////////////////////////////////////////////////////
void shearZX :: obj_setupCallback(t_class *classPtr)
{
class_addmethod(classPtr, (t_method)&shearZX::shearMessCallback,
class_addmethod(classPtr, reinterpret_cast<t_method>(&shearZX::shearMessCallback),
gensym("shearVal"), A_FLOAT, A_NULL);
}
void shearZX :: shearMessCallback(void *data, t_floatarg val)
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment