|   Registered Member   
 | 
							I don't understand how to operate the Matrix::cast() method. In a test I wrote: 
 to cast a matrix of doubles in a matrix of ints and it compiled and executed prefectly. In another test I have a class which stores a const reference to a Matrix (m0) and I must cast this matrix in a matrix of a specific type (m1). Consider the following code: 
 The error I become from the compiler is: 
 Why does the cast work good in normal cases but not compile if this is used within a class? 
								Last edited by Spiros on Mon Dec 14, 2009 1:46 pm, edited 2 times in total.
								
							 | 
|   Moderator   
 | 
							since cast is a template member function, in template code you have to prefix it with the template keywords: m1 = m0.template cast<Scalar>(); | 
|   Registered Member   
 | 
 Thank you very much! | 
Registered users: Bing [Bot], Google [Bot], Sogou [Bot]
 
		 
		 
		 
		