[gameprogrammer] Re: c++ template problem
- From: Felde Norbert <fenor@xxxxxxxxxxx>
- To: gameprogrammer@xxxxxxxxxxxxx
- Date: Sun, 19 Jul 2009 16:18:17 +0200
Thanks. The problem was that the va_list dous not handle float type.I need to get the parameter as double and than convert it to float which makes it difficult to implement it as template.
I could not find out yet the problem of the derived vect3 class. fenor Matthew Weigel írta:
Felde Norbert wrote:The c'tor should get the values of the coordinates, but because of the template parameter N, I do not know how many parameter the c'tor should get. I tried that: Vect<T,N>(T v0, T v1, ...) { va_list params; V[0] = v0; V[1] = v1;Other people report having success with this kind of code online, e.g. http://groups.google.com/group/microsoft.public.vc.language/browse_thread/thread/25e1820b7f894bde As a starting point, why don't you try building and running the code from that link (without the reference in the constructor) and see if you have any problems.
--------------------- To unsubscribe go to http://gameprogrammer.com/mailinglist.html
- Follow-Ups:
- [gameprogrammer] Re: c++ template problem
- From: Madison McGaffin
- [gameprogrammer] Re: c++ template problem
- References:
- [gameprogrammer] c++ template problem
- From: Felde Norbert
- [gameprogrammer] Re: c++ template problem
- From: Matthew Weigel
- [gameprogrammer] c++ template problem
Other related posts:
- » [gameprogrammer] c++ template problem - Felde Norbert
- » [gameprogrammer] Re: c++ template problem - Brian
- » [gameprogrammer] Re: c++ template problem - Matthew Weigel
- » [gameprogrammer] Re: c++ template problem - Felde Norbert
- » [gameprogrammer] Re: c++ template problem - Nicolas Goy
- » [gameprogrammer] Re: c++ template problem - Felde Norbert
- » [gameprogrammer] Re: c++ template problem - Roman Hwang
- » [gameprogrammer] Re: c++ template problem - Robbert de Groot
- » [gameprogrammer] Re: c++ template problem - Felde Norbert
- » [gameprogrammer] Re: c++ template problem - Roman Hwang
- » [gameprogrammer] Re: c++ template problem - Brian
- » [gameprogrammer] Re: c++ template problem - Madison McGaffin