Simplify macro by assuming PolyVox:: in front of all classes

This commit is contained in:
Matt Williams 2012-11-24 15:20:34 +00:00
parent edf2bf87d4
commit e7daab5bbc
5 changed files with 10 additions and 10 deletions

View File

@ -9,4 +9,4 @@
%include "Density.h"
%include "BaseVolume.h"
VOLUMETYPES(BaseVolume, PolyVox::BaseVolume)
VOLUMETYPES(BaseVolume)

View File

@ -9,4 +9,4 @@
%include "Density.h"
%include "LargeVolume.h"
VOLUMETYPES(LargeVolume, PolyVox::LargeVolume)
VOLUMETYPES(LargeVolume)

View File

@ -26,12 +26,12 @@ const char* __str__() {
//Centralise this to avoid repeating ourselves
//This macro will be called in the volume interface files to define the various volume types.
%define VOLUMETYPES(shortname, class)
%template(shortname ## Density8) class<PolyVox::Density8>;
%template(shortname ## Material8) class<PolyVox::Material8>;
%template(shortname ## Material16) class<PolyVox::Material16>;
%template(shortname ## MaterialDensityPair44) class<PolyVox::MaterialDensityPair44>;
%template(shortname ## MaterialDensityPair88) class<PolyVox::MaterialDensityPair88>;
%define VOLUMETYPES(class)
%template(class ## Density8) PolyVox::class<PolyVox::Density8>;
%template(class ## Material8) PolyVox::class<PolyVox::Material8>;
%template(class ## Material16) PolyVox::class<PolyVox::Material16>;
%template(class ## MaterialDensityPair44) PolyVox::class<PolyVox::MaterialDensityPair44>;
%template(class ## MaterialDensityPair88) PolyVox::class<PolyVox::MaterialDensityPair88>;
%enddef
%feature("autodoc", "1");

View File

@ -9,4 +9,4 @@
%include "Density.h"
%include "RawVolume.h"
VOLUMETYPES(RawVolume, PolyVox::RawVolume)
VOLUMETYPES(RawVolume)

View File

@ -9,4 +9,4 @@
%include "Density.h"
%include "SimpleVolume.h"
VOLUMETYPES(SimpleVolume, PolyVox::SimpleVolume)
VOLUMETYPES(SimpleVolume)