- This topic has 8 replies, 3 voices, and was last updated 5 years, 4 months ago by .
Viewing 9 posts - 1 through 9 (of 9 total)
Viewing 9 posts - 1 through 9 (of 9 total)
- You must be logged in to reply to this topic.
Home › Forum › SOFA › Programming with SOFA › [SOLVED] Generating .exe file out of a scene
Tagged: 64_bits, Linux_ubuntu, SOFA_1806
Hello,
I have created the cloth simulation of a circular disc. Now I would like to generate an executable file(eg: .exe). Can you please help me if there ways to generate an executable file from Sofa or Qt
Cheers
Shiva
Hey @avihs98
Congratulations for your cloth simulation.
Did you write it as an XML scene file? a Python file? a C++ file?
Best
Hugo
Several solutions then:
– you can open it with runSofa.exe
– or you can create a batch file launching directly runSofa path/to/your/file.xml
– or you can change the default scene of runSofa
– or modify the Main.cpp (C++) of runSofa so that it opens directly your xml file.
Hugo
No sir,
I am asking, just like runSofa.exe can we create a .exe for a xml scene like scene.exe, such that i can directly launch the scene.exe .
Cheers
Shiva
Hey @avihs98
You can simply modify in the source code of runSofa, line 408 (located in applications/projects/runSofa/Main.cpp):
the file path with your own file path. And then recompile. runSofa will afterwards automatically run your scene file by default.
Best,
Hugo
No Sir,
My doubt is that, just like how you have created a option toDownload in your page, is there a way i can create a file.
I am trying to do the cloth simulation as a mini project in my college, so it would be easy for me if i could get the file as in the Download icon is pressed.
Cheers
Shiva
Hi @shiva,
There is no “make an exe” button in the runSofa gui. This would be a nice addendum, not to hard to do, but right now there is none.
To achieve what you want to do you can:
– put the content of the .xml or a .scn or a .py as a big string in a .cpp file and use this string as the source of a scene loader. This would allows to load the scene without extra file in the filesystem.
– to visualize the scene, implement a minimalistic application with glut/freeglut/whatever. A good starting, yet not up-to-date, is the example in application/projects/glutOnePick
Regards,
Damien
WARNING
The forum has been moved to GitHub Discussions.
Old topics and replies are kept here as an archive.