With resolving the linking error of the audio patch Celestia can be build properly, however the executable crashes all the time.
Celestia is build with VC++ 2008 express edition on a windows 7 x86 enterprise machine.
It for sure that it is related with the audio support patch. I comment out all code related to audio support of celx.cpp, celestiacore.h and cpp, command.cpp and cmdparser.cpp. Further the link to fmod libraries and paths in celestia.vcproj. In short get rid of audio support.
A build of Celestia with the above modifications, thus without audio, works fine.
In a stadium of fault-finding it might be better to have audio support as a compiler option. In this way other changes to Celestia can be committed without the interference of the debug phase of audio support.
Crashes with sound patch
- Alexell
- Site Admin
- Posts: 303
- Joined: 07.10.2010
- Age: 30
- With us: 14 years 2 months
- Location: Moscow, Russia
- Contact:
The executable file does not crash all the time. Of 10 starts, only 3 falls. Demo scripts from the scripts\audio folder work well, clearly show how the audio patch works. I did not comment on the audio patch on my Celestia, because crashes do not happen too often.
As already written in this comment, we need help to find out the cause of the problem. There may be memory leaks.
Added after 4 minutes 23 seconds:
HB, I hope you remember to put fmod.dll in the root folder Celestia?
As already written in this comment, we need help to find out the cause of the problem. There may be memory leaks.
Added after 4 minutes 23 seconds:
HB, I hope you remember to put fmod.dll in the root folder Celestia?
Admin of celestia.space
PC: Intel Core i7-8700 @ 3.20GHz, SSD, 16 Gb RAM, NVIDIA GeForce GTX 1080, Creative Sound Blaster ZxR. Windows 10 x64.
Phone: iPhone Xs 256 Gb. iOS 14.
PC: Intel Core i7-8700 @ 3.20GHz, SSD, 16 Gb RAM, NVIDIA GeForce GTX 1080, Creative Sound Blaster ZxR. Windows 10 x64.
Phone: iPhone Xs 256 Gb. iOS 14.
-
Topic authorHB
- Posts: 132
- Joined: 26.11.2002
- With us: 22 years
- Location: Eindhoven, The Netherlands
What I've found out so far on this issue is that the audio patch is not compatible with Windows 7 x86 Enterprise which includes Service Pack 1.
Celestia crashes at the moment the cel scripts are initialised and/or loaded into memory during the start-up phase. This has been shown by the results of a Process Monitor tool. As far as I remember scripts have been caused memory leaks in the past. So likely indeed a memory leak.
The workaround for this problem is simple: just change the compatibility mode of Celestia. Anything from Windows XP onwards is ok. I've used a compatibility with Windows 7. By turning on compatibility mode an extra layer(shims) are between Celestia and Windows. A function call from the application to a windows dll is now to that shim instead of direct to the dll.
Later on I'll do the same trick on a debug build of Celestia. Maybe some other causes can be found with that as well.
What I'd like to know from the Celestia community if this problem also occurs on other Windows platforms as XP, Vista, 8, 8.1, 10 etc. with compatibility mode turned off?
Added after 38 minutes 9 seconds:
Start up Celestia with sound demo celx the following error appears:
Celestia crashes at the moment the cel scripts are initialised and/or loaded into memory during the start-up phase. This has been shown by the results of a Process Monitor tool. As far as I remember scripts have been caused memory leaks in the past. So likely indeed a memory leak.
The workaround for this problem is simple: just change the compatibility mode of Celestia. Anything from Windows XP onwards is ok. I've used a compatibility with Windows 7. By turning on compatibility mode an extra layer(shims) are between Celestia and Windows. A function call from the application to a windows dll is now to that shim instead of direct to the dll.
Later on I'll do the same trick on a debug build of Celestia. Maybe some other causes can be found with that as well.
What I'd like to know from the Celestia community if this problem also occurs on other Windows platforms as XP, Vista, 8, 8.1, 10 etc. with compatibility mode turned off?
Added after 38 minutes 9 seconds:
Start up Celestia with sound demo celx the following error appears:
[string "E:\C++\VC++2008\Celestia-master\script\au..."]:42: attempt to call method 'play' (a nil value)
HB
- Alexell
- Site Admin
- Posts: 303
- Joined: 07.10.2010
- Age: 30
- With us: 14 years 2 months
- Location: Moscow, Russia
- Contact:
This is what we know when I'll post binary files on forum for review. But it will be in a month or two.HB wrote:What I'd like to know from the Celestia community if this problem also occurs on other Windows platforms as XP, Vista, 8, 8.1, 10 etc. with compatibility mode turned off?
HB wrote:Start up Celestia with sound demo celx the following error appears:
[string "E:\C++\VC++2008\Celestia-master\script\au..."]:42: attempt to call method 'play' (a nil value)
Are you sure you're running the right script? I have everything working, I can even record video, where it will be seen that all works fine.
Admin of celestia.space
PC: Intel Core i7-8700 @ 3.20GHz, SSD, 16 Gb RAM, NVIDIA GeForce GTX 1080, Creative Sound Blaster ZxR. Windows 10 x64.
Phone: iPhone Xs 256 Gb. iOS 14.
PC: Intel Core i7-8700 @ 3.20GHz, SSD, 16 Gb RAM, NVIDIA GeForce GTX 1080, Creative Sound Blaster ZxR. Windows 10 x64.
Phone: iPhone Xs 256 Gb. iOS 14.
-
Topic authorHB
- Posts: 132
- Joined: 26.11.2002
- With us: 22 years
- Location: Eindhoven, The Netherlands
I wrote:
Start up Celestia with sound demo celx the following error appears:
[string "E:\C++\VC++2008\Celestia-master\script\au..."]:42: attempt to call method 'play' (a nil value)
It's a mistake made by me. Start up Celestia with a cel(x) scripts will point to my original Celestia application. That's an earlier version without the audio patch.
Sorry by that.
However sound_demo.celx will start a audio file comment.ogg, which doesn't exist. Fix that by a correction of the celx script.(ogg -> mp3)
Audio works fine now.
Still continue looking for memory leaks, it's hard job to do.
HB