It is currently Mon Dec 16, 2019 12:46 am


All times are UTC




Post new topic Reply to topic  [ 4 posts ] 
Author Message
 Post subject: Simple Volume giving error
PostPosted: Mon Oct 12, 2015 11:04 pm 

Joined: Mon Oct 12, 2015 11:00 pm
Posts: 2
Hello everyone,
i added the line
Code:
SimpleVolume<uint8_t> volData(PolyVox::Region(Vector3DInt32(0,0,0), Vector3DInt32(63, 63, 63)));
to my code and this error popped up when i try to run it



Terrain.obj : error LNK2019: unresolved external symbol "public: __thiscall PolyVox::Region::Region(void)" (??0Region@PolyVox@@QAE@XZ) referenced in function "public: __thiscall PolyVox::SimpleVolume<unsigned char>::SimpleVolume<unsigned char>(class PolyVox::Region const &,unsigned short)" (??0?$SimpleVolume@E@PolyVox@@QAE@ABVRegion@1@G@Z)
1>Terrain.obj : error LNK2019: unresolved external symbol "public: __thiscall PolyVox::Region::Region(class PolyVox::Vector<3,int> const &,class PolyVox::Vector<3,int> const &)" (??0Region@PolyVox@@QAE@ABV?$Vector@$02H@1@0@Z) referenced in function "public: void __thiscall Terrain::Draw(void)" (?Draw@Terrain@@QAEXXZ)
1>Terrain.obj : error LNK2019: unresolved external symbol "public: class PolyVox::Vector<3,int> const & __thiscall PolyVox::Region::getLowerCorner(void)const " (?getLowerCorner@Region@PolyVox@@QBEABV?$Vector@$02H@2@XZ) referenced in function "public: int __thiscall PolyVox::BaseVolume<unsigned char>::getDepth(void)const " (?getDepth@?$BaseVolume@E@PolyVox@@QBEHXZ)
1>Terrain.obj : error LNK2019: unresolved external symbol "public: class PolyVox::Vector<3,int> const & __thiscall PolyVox::Region::getUpperCorner(void)const " (?getUpperCorner@Region@PolyVox@@QBEABV?$Vector@$02H@2@XZ) referenced in function "public: int __thiscall PolyVox::BaseVolume<unsigned char>::getDepth(void)const " (?getDepth@?$BaseVolume@E@PolyVox@@QBEHXZ)
1>Terrain.obj : error LNK2019: unresolved external symbol "public: void __thiscall PolyVox::Region::setLowerCorner(class PolyVox::Vector<3,int> const &)" (?setLowerCorner@Region@PolyVox@@QAEXABV?$Vector@$02H@2@@Z) referenced in function "private: void __thiscall PolyVox::SimpleVolume<unsigned char>::initialise(class PolyVox::Region const &,unsigned short)" (?initialise@?$SimpleVolume@E@PolyVox@@AAEXABVRegion@2@G@Z)
1>Terrain.obj : error LNK2019: unresolved external symbol "public: void __thiscall PolyVox::Region::setUpperCorner(class PolyVox::Vector<3,int> const &)" (?setUpperCorner@Region@PolyVox@@QAEXABV?$Vector@$02H@2@@Z) referenced in function "private: void __thiscall PolyVox::SimpleVolume<unsigned char>::initialise(class PolyVox::Region const &,unsigned short)" (?initialise@?$SimpleVolume@E@PolyVox@@AAEXABVRegion@2@G@Z)
1>Terrain.obj : error LNK2019: unresolved external symbol "unsigned char __cdecl PolyVox::logBase2(unsigned int)" (?logBase2@PolyVox@@YAEI@Z) referenced in function "private: void __thiscall PolyVox::SimpleVolume<unsigned char>::initialise(class PolyVox::Region const &,unsigned short)" (?initialise@?$SimpleVolume@E@PolyVox@@AAEXABVRegion@2@G@Z)
1>Terrain.obj : error LNK2019: unresolved external symbol "bool __cdecl PolyVox::isPowerOf2(unsigned int)" (?isPowerOf2@PolyVox@@YA_NI@Z) referenced in function "private: void __thiscall PolyVox::SimpleVolume<unsigned char>::initialise(class PolyVox::Region const &,unsigned short)" (?initialise@?$SimpleVolume@E@PolyVox@@AAEXABVRegion@2@G@Z)


Top
Offline Profile  
Reply with quote  
 Post subject: Re: Simple Volume giving error
PostPosted: Tue Oct 13, 2015 7:05 am 
Developer
User avatar

Joined: Sun May 04, 2008 6:35 pm
Posts: 1827
It looks like you haven't linked against the PolyVox.lib (I think that's what it is called) in your linker settings?

However, it also looks like you are using the last stable release. If you have Visual Studio 2013 or newer then I'd recommend using the 'develop' version of PolyVox from Git. This version is header-only, so you don't need to configure the linker.


Top
Offline Profile  
Reply with quote  
 Post subject: Re: Simple Volume giving error
PostPosted: Tue Oct 13, 2015 12:16 pm 

Joined: Mon Oct 12, 2015 11:00 pm
Posts: 2
David Williams wrote:
It looks like you haven't linked against the PolyVox.lib (I think that's what it is called) in your linker settings?

However, it also looks like you are using the last stable release. If you have Visual Studio 2013 or newer then I'd recommend using the 'develop' version of PolyVox from Git. This version is header-only, so you don't need to configure the linker.


Thank you for your reply . I found the developer version gonna give it a try

edit: how would i include the developer one into the project

edit: i just included the project into my one but im getting weird error
Code:
'PolyVox::PagedVolume<int>::PagedVolume(const PolyVox::PagedVolume<int> &)': cannot convert argument 1 from 'PolyVox::Region' to 'PolyVox::PagedVolume<int>::Pager *'


The line of code causing it is
Code:
PagedVolume<int> volume(PolyVox::Region(Vector3DInt32(0, 0, 0), Vector3DInt32(63, 127, 255)));


Top
Offline Profile  
Reply with quote  
 Post subject: Re: Simple Volume giving error
PostPosted: Tue Oct 13, 2015 9:30 pm 
Developer
User avatar

Joined: Sun May 04, 2008 6:35 pm
Posts: 1827
The programming interface has changed between the last stable release and the develop version. You'll need to look at the examples to see how to use the latest API as the documentation is often not up to date.

In the latest version the PagedVolume does not have a defined size, and needs to be given an instance of 'Pager' to get the data from. For example, in PagingExample:

Code:
PerlinNoisePager* pager = new PerlinNoisePager();
PagedVolume<MaterialDensityPair44> volData(pager, 8 * 1024 * 1024, 64);


However, I recommend you don't work with paging until you are quite experienced with PolyVox. It's much better to start with the RawVolume and the BasicExample until you have got volumes rendering, update and interaction working, etc.


Top
Offline Profile  
Reply with quote  
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 4 posts ] 

All times are UTC


Who is online

Users browsing this forum: No registered users and 3 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
cron
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group
Theme created StylerBB.net