To bind a template, you must bind a specific instantiation of it. I'm binding the instantiations defined by the typedefs in Vector.h (though I have to specify them manually in SWIG).
The uint8 etc. typedefs aren't working for now though.
This commit is contained in:
parent
25898425f5
commit
69751dc084
@ -7,5 +7,5 @@
|
|||||||
%include "Enums.i"
|
%include "Enums.i"
|
||||||
%include "PolyVoxCStdInt.i"
|
%include "PolyVoxCStdInt.i"
|
||||||
%include "Utility.i"
|
%include "Utility.i"
|
||||||
%include "PolyVoxForwardDeclarations.i"
|
//%include "PolyVoxForwardDeclarations.i" //Shouldn't be needed
|
||||||
//%include "Vector.i"
|
%include "Vector.i"
|
||||||
|
@ -1,10 +1,18 @@
|
|||||||
%module Vector
|
%module Vector
|
||||||
%{
|
%{
|
||||||
#include "PolyVoxCore/Vector.h"
|
#include "PolyVoxCore/Vector.h"
|
||||||
|
//#include "PolyVoxCore/PolyVoxCStdInt.h"
|
||||||
%}
|
%}
|
||||||
|
|
||||||
%include "PolyVoxCore/Vector.h"
|
%include "PolyVoxCore/Vector.h"
|
||||||
|
|
||||||
%template(VectorTest) PolyVox::Vector<3,float>;
|
%template(Vector3DFloat) PolyVox::Vector<3,float>;
|
||||||
|
%template(Vector3DDouble) PolyVox::Vector<3,double>;
|
||||||
|
//%template(Vector3DInt8) PolyVox::Vector<3,int8>;
|
||||||
|
//%template(Vector3DUint8) PolyVox::Vector<3,uint8>;
|
||||||
|
//%template(Vector3DInt16) PolyVox::Vector<3,int16>;
|
||||||
|
//%template(Vector3DUint16) PolyVox::Vector<3,uint16>;
|
||||||
|
//%template(Vector3DInt32) PolyVox::Vector<3,int32>;
|
||||||
|
//%template(Vector3DUint32) PolyVox::Vector<3,uint32>;
|
||||||
|
|
||||||
%rename(assign) VectorTest::operator=;
|
%rename(assign) Vector3DFloat::operator=;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user