Irrlicht / Qt4 integration + QtCreator

A forum to store posts deemed exceptionally wise and useful

Re: Irrlicht / Qt4 integration + QtCreator

Postby YankzzDev » Mon Oct 10, 2011 4:13 am

i am using visual studio 2008 to do it, not code block.. can you help me? i really need it..
Nobody is Perfect!!
YankzzDev
 
Posts: 23
Joined: Wed Oct 05, 2011 4:37 am
Location: Indonesia

Re: Irrlicht / Qt4 integration + QtCreator

Postby aanderse » Mon Oct 10, 2011 4:59 pm

you'd need to state the problems you are having before anyone can help you
User avatar
aanderse
 
Posts: 155
Joined: Sun Aug 10, 2008 2:02 pm
Location: Canada

Re: Irrlicht / Qt4 integration + QtCreator

Postby Virion » Tue Oct 11, 2011 6:04 pm

YankzzDev wrote:it's work on windows? i want integration to windows

yes it works on windows
User avatar
Virion
 
Posts: 2102
Joined: Mon Dec 18, 2006 5:04 am
Location: Malaysia

Re: Irrlicht / Qt4 integration + QtCreator

Postby YankzzDev » Wed Oct 12, 2011 4:07 am

thank you for the reply...


i got a small error

cannot convert parameter 1 from 'QString' to 'const irr::io::path &'

because i have successful integrated with windows..

n i try to open a model example and import it to irrlicht engine..

i use the qt QFileDialog::getOpenFileName function to open the model file..

here is the code:

cpp Code: Select all
 
QString filename = QFileDialog::getOpenFileName(this);
        ui->label->setText(filename);
 


and at the irrlicht code, i change this code:

cpp Code: Select all
 
IAnimatedMesh* mesh = smgr->getMesh("sydney.md2");
 


to this code

cpp Code: Select all
 
IAnimatedMesh* mesh = smgr->getMesh(filename);
 



and got this error

cpp Code: Select all
 
1>.\mainwindow.cpp(43) : error C2664: 'irr::scene::IAnimatedMesh *irr::scene::ISceneManager::getMesh(const irr::io::path &)' : cannot convert parameter 1 from 'QString' to 'const irr::io::path &'
1>        Reason: cannot convert from 'QString' to 'const irr::io::path'
1>        No user-defined-conversion operator available that can perform this conversion, or the operator cannot be called
1>Build log was saved at "file://d:\QT Project\1011irrlichtqt\debug\BuildLog.htm"
 
 


Can you help me solve this problem?
Nobody is Perfect!!
YankzzDev
 
Posts: 23
Joined: Wed Oct 05, 2011 4:37 am
Location: Indonesia

Re: Irrlicht / Qt4 integration + QtCreator

Postby aanderse » Wed Oct 12, 2011 4:33 am

well... as your compiler tells you
you're passing the getMesh function a QString (filename) when it doesn't accept a QString, it accepts an io::path

you could pass qPrintable (filename) to getMesh instead of just filename and it should work

cpp Code: Select all
IAnimatedMesh* mesh = smgr->getMesh(qPrintable (filename));
User avatar
aanderse
 
Posts: 155
Joined: Sun Aug 10, 2008 2:02 pm
Location: Canada

Re: Irrlicht / Qt4 integration + QtCreator

Postby YankzzDev » Wed Oct 12, 2011 4:48 am

aanderse wrote:well... as your compiler tells you
you're passing the getMesh function a QString (filename) when it doesn't accept a QString, it accepts an io::path

you could pass qPrintable (filename) to getMesh instead of just filename and it should work

cpp Code: Select all
IAnimatedMesh* mesh = smgr->getMesh(qPrintable (filename));



thank you very much.. it's work!!
Nobody is Perfect!!
YankzzDev
 
Posts: 23
Joined: Wed Oct 05, 2011 4:37 am
Location: Indonesia

Re: Irrlicht / Qt4 integration + QtCreator

Postby YankzzDev » Wed Oct 12, 2011 6:36 am

hmmm, i have another question...


after i load the model, it's displayed on the screen, but i load another model, it's displayed 2 model with selected one and previous one...

how i can clear the previous one?
Nobody is Perfect!!
YankzzDev
 
Posts: 23
Joined: Wed Oct 05, 2011 4:37 am
Location: Indonesia

Re: Irrlicht / Qt4 integration + QtCreator

Postby serengeor » Wed Oct 12, 2011 11:10 am

YankzzDev wrote:hmmm, i have another question...


after i load the model, it's displayed on the screen, but i load another model, it's displayed 2 model with selected one and previous one...

how i can clear the previous one?


Read the F***** API and get some c++ skills :|
Not trying to be rude, but basically it seams that we're programming for you.
Working on game: Marrbles (Currently stopped).
User avatar
serengeor
 
Posts: 1694
Joined: Tue Jan 13, 2009 7:34 pm
Location: Lithuania

Re: Irrlicht / Qt4 integration + QtCreator

Postby aanderse » Wed Oct 12, 2011 3:34 pm

YankzzDev wrote:hmmm, i have another question...


after i load the model, it's displayed on the screen, but i load another model, it's displayed 2 model with selected one and previous one...

how i can clear the previous one?


can you please post your code so i can understand what you mean?
User avatar
aanderse
 
Posts: 155
Joined: Sun Aug 10, 2008 2:02 pm
Location: Canada

Re: Irrlicht / Qt4 integration + QtCreator

Postby YankzzDev » Thu Oct 13, 2011 3:27 am

serengeor wrote:
YankzzDev wrote:hmmm, i have another question...


after i load the model, it's displayed on the screen, but i load another model, it's displayed 2 model with selected one and previous one...

how i can clear the previous one?


Read the F***** API and get some c++ skills :|
Not trying to be rude, but basically it seams that we're programming for you.


the rude one is you... i not asking you to programming for me.....

Because i don't understand so i ask..

i am not expert like you(C++ Expert maybe than C++ god)..

i am newbie in c++ and irrlicht engine too...

my basic languange is vb.net..

if i don't understand, so i ask? it's fault?
Nobody is Perfect!!
YankzzDev
 
Posts: 23
Joined: Wed Oct 05, 2011 4:37 am
Location: Indonesia

Re: Irrlicht / Qt4 integration + QtCreator

Postby YankzzDev » Thu Oct 13, 2011 3:30 am

aanderse wrote:
YankzzDev wrote:hmmm, i have another question...


after i load the model, it's displayed on the screen, but i load another model, it's displayed 2 model with selected one and previous one...

how i can clear the previous one?


can you please post your code so i can understand what you mean?


i am so bad luck.. my hard disk is damaged yesterday.. all my files are gone.. so i can't not upload my code to you now.. i will upload it after i fix my computer.. thank's for your help
Nobody is Perfect!!
YankzzDev
 
Posts: 23
Joined: Wed Oct 05, 2011 4:37 am
Location: Indonesia

Re: Irrlicht / Qt4 integration + QtCreator

Postby YankzzDev » Thu Oct 20, 2011 3:55 am

here is my code...

http://www.2shared.com/file/U5jXL-fP/Vi ... nning.html

i wish to ask about collada files..

do you try to load a collada files?

i export a collada files using sketch up 8, and show in irrlicht engine.. but it's failed

and i try using sketch up 7, it's can load it, but not exactly what i expected..

do you have any solution?
Nobody is Perfect!!
YankzzDev
 
Posts: 23
Joined: Wed Oct 05, 2011 4:37 am
Location: Indonesia

Re: Irrlicht / Qt4 integration + QtCreator

Postby Virion » Thu Oct 20, 2011 6:02 am

YankzzDev wrote:it's work on windows? i want integration to windows

yes it does. Qt is cross platform.
User avatar
Virion
 
Posts: 2102
Joined: Mon Dec 18, 2006 5:04 am
Location: Malaysia

Re: Irrlicht / Qt4 integration + QtCreator

Postby hybrid » Thu Oct 20, 2011 11:54 am

Due to element ordering changes in the last few versions of sketchup, the current Irrlicht loader cannot open those collada files properly. Next version wil have a fixed loader.
hybrid
Admin
 
Posts: 13942
Joined: Wed Apr 19, 2006 9:20 pm
Location: Oldenburg(Oldb), Germany

Re: Irrlicht / Qt4 integration + QtCreator

Postby YankzzDev » Fri Oct 21, 2011 3:00 am

hybrid wrote:Due to element ordering changes in the last few versions of sketchup, the current Irrlicht loader cannot open those collada files properly. Next version wil have a fixed loader.



tq admin
Nobody is Perfect!!
YankzzDev
 
Posts: 23
Joined: Wed Oct 05, 2011 4:37 am
Location: Indonesia

PreviousNext

Return to FAQs, Tutorials, Howtos, and external tool lists

Who is online

Users browsing this forum: No registered users and 0 guests