Show Posts
|
|
Pages: 1 [2] 3 4 ... 9
|
|
17
|
Associate Projects / CEL Discussion / Re: Basics: Celtst and Cal3D
|
on: January 06, 2006, 06:35:52 pm
|
I believe I had a similar problem, if I am not mistaken, it was because libcal3d was in the wrong lib folder. Now, I can't verify it right here, but I believe I had to make sym link from /usr/local/lib/libcal3d.so.11.0.0 to /usr/lib/libcal3d.so.11.0.0. I think...It was a while ago 
|
|
|
|
|
20
|
Crystal Space Development / Support / Re: Parsing XML file
|
on: December 28, 2005, 07:50:25 am
|
Well, after a bit of messing, I think I got something that should work. Here is the code I used for my own (you might want to change it  ) if someone else is interested, but please, if I am doing something wrong, tell me. void App::LoadPlanetData() { csPrintf("Loading planet data...\n"); csRef<iFile> file = vfs->Open("/puniverse/planet/planets.xml",VFS_FILE_READ); csRef<csTinyDocumentSystem> xml; xml.AttachNew(new csTinyDocumentSystem()); csRef<iDocumentNode> root, planet; csRef<iDocumentNodeIterator> rooti, planeti;
CS_ASSERT(xml != NULL);
if(file.IsValid()) { csRef<iDocument> doc = xml->CreateDocument(); if(!doc->Parse(file)) { root = doc->GetRoot(); root = root->GetNode("planets"); rooti = root->GetNodes(); while(rooti->HasNext()) { root = rooti->Next(); if(!root) break; csPrintf("Node: %s\n", root->GetValue()); planeti = root->GetNodes(); planet = root; while(planeti->HasNext()) { planet = planeti->Next(); csPrintf("Node value: %s\n", planet->GetContentsValue()); } } } else csPrintf("Could not parse file!\n");
} else ReportError("Could not parse planets.xml file!"); }
|
|
|
|
|
21
|
Crystal Space Development / Support / Parsing XML file
|
on: December 27, 2005, 11:09:37 pm
|
I was wondering how I could parse an XML file using the iDocument interfaces. In my attempts when I try to read the file can't iterate the nodes (I found a similar post like this, but not enough information). Basically, I want to parse a file that has this structure: <?xml version="1.0"?> <planets> <planet> <name>Sun</name> <mass>1.99*10^30</mass> <radius>695990000</radius> <description>Center of the Sol System.</description> </planet> </planets>
and get each all the information for each <planet>. Is there somewhere I could look to find a block of code to handle this, or could you show me? Thanks.
|
|
|
|
|
24
|
Crystal Space Development / Support / Re: CEGUI problem
|
on: December 21, 2005, 12:11:37 am
|
Here is the error before the fix: ./ceguitest: error while loading shared libraries: libCEGUIBase.so.0: cannot open shared object file: No such file or directory
And this was just with the ceguitest from CS, so flags are in the Jamfile in the apps/tests/ceguitest/ folder (I assume): SubDir TOP apps tests ceguitest ;
if $(CEGUI.AVAILABLE) = "yes" { Description ceguitest : "CEGUI Test Application" ; Application ceguitest : [ Wildcard *.h *.cpp ] ; CFlags ceguitest : $(COMPILER.C++FLAGS.EXCEPTIONS.ENABLE) ; LinkWith ceguitest : crystalspace ; ExternalLibs ceguitest : CEGUI ; }
|
|
|
|
|
26
|
Crystal Space Development / Support / Re: CEGUI problem
|
on: December 20, 2005, 03:36:48 pm
|
|
When building the cegui source package from cegui.org, the default installation installs the libraries to /usr/local/lib/ and that works fine for building and linking, but when you actually try to run say, the ceguitest application, it can't find the libcegui libraries. I just made symlinks from /usr/local/lib/libcegui* to /usr/lib/ and the application ran fine.
|
|
|
|
|
27
|
Crystal Space Development / Support / Re: CEGUI problem
|
on: December 20, 2005, 06:20:37 am
|
|
Thanks it compiles now! About the libcegui, make installing the 0.4.1 source package with the prefix /usr/local is fine for everything, until you actually try to run the CS application. I just made symlinks to all the /usr/local/lib/libCEGUI* to /usr/lib/ and it ran fine, but is this a bug in CEGUI or CS?
|
|
|
|
|
28
|
Crystal Space Development / Support / CEGUI problem
|
on: December 19, 2005, 05:18:33 am
|
I am trying to use CEGUI in my application, but compiling the app fails to find header files. I wonder why the test ceguitest app from crystal space compiled fine while my application, which uses many of the same things from the test can't find header files like "CEGUI.h." I am using the same installation of CEGUI for both. Am I doing something wrong? I basically copied the CEGUI stuff from the tests seeing as I've never used CEGUI before. Any suggestions? Thanks. Here is the first part of the build output: ...found 37 target(s)... ...updating 3 target(s)... C++ ./out/linuxx86/optimize/src/puniverse.o In file included from src/puniverse.cpp:1: src/pApp.h:5:19: CEGUI.h: No such file or directory In file included from src/pApp.h:6, from src/puniverse.cpp:1: /home/max/files/cvs/CS/include/ivaria/icegui.h:27:19: CEGUI.h: No such file or directory In file included from src/pApp.h:6, from src/puniverse.cpp:1: /home/max/files/cvs/CS/include/ivaria/icegui.h:49: error: ISO C++ forbids declaration of `CEGUI' with no type /home/max/files/cvs/CS/include/ivaria/icegui.h:49: error: `CEGUI' declared as a `virtual' field /home/max/files/cvs/CS/include/ivaria/icegui.h:49: error: parse error before `
But the test application in CS has the same includes and works fine...
|
|
|
|
|
29
|
Crystal Space Development / General Crystal Space Discussion / Glow effect?
|
on: December 18, 2005, 01:52:14 am
|
|
I was wondering how I could achieve a glow effect around a sphere or other object? I want a selected object appear selected by having it glow around the edges or radiate light or something to that effect. How could I go about doing this? Thanks.
|
|
|
|
|
|