A Primer for C++ Developers on Windows Vista and VS2005
Posted: 27.08.2007, 15:15
Check out the sticky for WinXP development and download all the necessary libs. Then download Windows Vista Platform SDK at the Microsoft website:
http://www.microsoft.com/downloads/details.aspx?familyid=c2b1e300-f358-4523-b479-f53d234cdccf&displaylang=en
Grab a copy of the source from CVS, open the VS project and the the following amendments to update the project:
1. Removed octree.cpp //This is an empty file
2. Excluded libc.lib from Project Celestia //Not used anymore
3. Delete the following line from celestia.rc: //VS2005 creates its own manifest - duplicate errors otherwise
1 RT_MANIFEST "celestia.exe.manifest"
4. Included intl.lib to Project Celestia //Resolves 37 linker errors
5. Added existing items starcolors.h & starcolors.cpp to Project celengine //Resolves 2 linker errors
6. Adding 3dsmesh.h & 3dsmesh.cpp to Project celengine but it gives a number of errors: //Files were excluded as a result
`Normals' undeclared
`Colors' undeclared
`Multipass' undeclared
`VertexProgParams' undeclared
7. Added existing item CGBuffer.h to Project celengine //Had no effect on number of linker errors
8. Added existing items dsodb.cpp, dsoname.cpp & dsooctree.cpp and their headers to Project celengine //Resolves 18 linker errors
9. Added existing item glshader.cpp and glshader.h to Project celengine //Resolves 1 linker error
10. Added existing item lightenv.h to celengine //Had no effect on number of linker errors
11. Added existing item staroctree.cpp and staroctree.h to Project celengine //Resolves 7 linker errors
12. Added existing item starbrowser.cpp and starbrowser.h to Project celengine //Had no effect on number of linker errors
13. Added existing item spiceorbit.cpp & spiceinterface.cpp and their headers to Project celengine (Note: Added spice libs as well) //Had no effect on number of linker errors
14. Added existing item solarsys.cpp and header to Project celengine. //Had no effect on number of linker errors
15. Added existing item solarsysxml.cpp and header to Project celengine //File was excluded - Generated 22 coding errors
16. Added cspice.lib to Project celestia //Had no effect on number of linker errors
17. Added the following existing files & associated headers where applicable to Project celengine: //Revolves 17 linker errors
shadermanager.cpp
scriptrotation.cpp
scriptorbit.cpp
scriptobject.cpp
samporient.cpp
rotationmanager.cpp
rotation.cpp
renderglsl.cpp
renderinfo.h
18. Added existing items name.h and parseobject.cpp/parseobject.h to celengine //Resolve 7 linker errors
At this stage you are left with errors within the Project Celestia Only. To correct these add all files, except the following:
celx.h & celx.cpp //Coding errors
glutmain.cpp //coding errors
oggtheoracapture.cpp & oggtheoracapture.h //Coding errors.
This will now build, just make sure you disable the usage of pre-compiled headers and that you use the multi-threaded runtime (/MT).
Additonal notes:
You can create a new Win32 project for celscript and add all the files. Just remember to add the lib to the Project celestia.
UPDATE: 28th Aug 2007
Add celx.h and celx.cpp to the Project celestia...
Obtain the latest libs:
http://www.shatters.net/~claurel/celestia/winbuild/
...add the following libs to the celestia Project:
lua5.1.lib, lualib.lib, lua.lib
Define CELX and increase the LUA_VER to 0x050100 (celx.h)
Now you can enjoy full script support and the Lau Edu Tools.
UPDATE: 29th Aug 2007
Do NOT add ijgjpeg.lib to the linker. This will result in all the planets, except Earth, having no textures.
Thanks to Cartrite on that one.
UPDATE: 30th Aug 2007
For those looking to add sound support here are the instructions:
1. Download the following file:
http://vincent.gian.club.fr/celestia/ce ... patch3.zip
2. Copy alut.dll and OpenAL32.dll to the Celestia base folder.
3. Copy the folder 'Sounds' to the Celestia base folder.
4. Copy the Alut.lib and OpenAL32.lib to the libs folder you use for development.
5. Copy the headers from \inc\Al to the headers folder you use for development.
6. Three files need to be updated:
celx.cpp
celestiacore.h
celestiacore.cpp
Search for the term 'Victor' and copy the routines to your working copy.
7. Add the libs to the linker
8. Compile
Copy the file sound_test3.celx to your scripts folder.
Run Celestia and load the script. You should now have sound support.
http://www.microsoft.com/downloads/details.aspx?familyid=c2b1e300-f358-4523-b479-f53d234cdccf&displaylang=en
Grab a copy of the source from CVS, open the VS project and the the following amendments to update the project:
1. Removed octree.cpp //This is an empty file
2. Excluded libc.lib from Project Celestia //Not used anymore
3. Delete the following line from celestia.rc: //VS2005 creates its own manifest - duplicate errors otherwise
1 RT_MANIFEST "celestia.exe.manifest"
4. Included intl.lib to Project Celestia //Resolves 37 linker errors
5. Added existing items starcolors.h & starcolors.cpp to Project celengine //Resolves 2 linker errors
6. Adding 3dsmesh.h & 3dsmesh.cpp to Project celengine but it gives a number of errors: //Files were excluded as a result
`Normals' undeclared
`Colors' undeclared
`Multipass' undeclared
`VertexProgParams' undeclared
7. Added existing item CGBuffer.h to Project celengine //Had no effect on number of linker errors
8. Added existing items dsodb.cpp, dsoname.cpp & dsooctree.cpp and their headers to Project celengine //Resolves 18 linker errors
9. Added existing item glshader.cpp and glshader.h to Project celengine //Resolves 1 linker error
10. Added existing item lightenv.h to celengine //Had no effect on number of linker errors
11. Added existing item staroctree.cpp and staroctree.h to Project celengine //Resolves 7 linker errors
12. Added existing item starbrowser.cpp and starbrowser.h to Project celengine //Had no effect on number of linker errors
13. Added existing item spiceorbit.cpp & spiceinterface.cpp and their headers to Project celengine (Note: Added spice libs as well) //Had no effect on number of linker errors
14. Added existing item solarsys.cpp and header to Project celengine. //Had no effect on number of linker errors
15. Added existing item solarsysxml.cpp and header to Project celengine //File was excluded - Generated 22 coding errors
16. Added cspice.lib to Project celestia //Had no effect on number of linker errors
17. Added the following existing files & associated headers where applicable to Project celengine: //Revolves 17 linker errors
shadermanager.cpp
scriptrotation.cpp
scriptorbit.cpp
scriptobject.cpp
samporient.cpp
rotationmanager.cpp
rotation.cpp
renderglsl.cpp
renderinfo.h
18. Added existing items name.h and parseobject.cpp/parseobject.h to celengine //Resolve 7 linker errors
At this stage you are left with errors within the Project Celestia Only. To correct these add all files, except the following:
celx.h & celx.cpp //Coding errors
glutmain.cpp //coding errors
oggtheoracapture.cpp & oggtheoracapture.h //Coding errors.
This will now build, just make sure you disable the usage of pre-compiled headers and that you use the multi-threaded runtime (/MT).
Additonal notes:
You can create a new Win32 project for celscript and add all the files. Just remember to add the lib to the Project celestia.
UPDATE: 28th Aug 2007
Add celx.h and celx.cpp to the Project celestia...
Obtain the latest libs:
http://www.shatters.net/~claurel/celestia/winbuild/
...add the following libs to the celestia Project:
lua5.1.lib, lualib.lib, lua.lib
Define CELX and increase the LUA_VER to 0x050100 (celx.h)
Now you can enjoy full script support and the Lau Edu Tools.
UPDATE: 29th Aug 2007
Do NOT add ijgjpeg.lib to the linker. This will result in all the planets, except Earth, having no textures.
Thanks to Cartrite on that one.
UPDATE: 30th Aug 2007
For those looking to add sound support here are the instructions:
1. Download the following file:
http://vincent.gian.club.fr/celestia/ce ... patch3.zip
2. Copy alut.dll and OpenAL32.dll to the Celestia base folder.
3. Copy the folder 'Sounds' to the Celestia base folder.
4. Copy the Alut.lib and OpenAL32.lib to the libs folder you use for development.
5. Copy the headers from \inc\Al to the headers folder you use for development.
6. Three files need to be updated:
celx.cpp
celestiacore.h
celestiacore.cpp
Search for the term 'Victor' and copy the routines to your working copy.
7. Add the libs to the linker
8. Compile
Copy the file sound_test3.celx to your scripts folder.
Run Celestia and load the script. You should now have sound support.