New install, can't run demos?

bigkahuna

15-04-2006 01:24:00

Hi all,

Sorry if this is too simple a question, but I just installed PyOgre and the Media files for the first time. (I already had Python 2.4 installed) I launched IDLE and loaded a demo file (one of the .py files, right?) and I get an error about not being able to open a .zip file?

Here's what I did:
1. Installed PyOgre (latest Windows install)
2. Unzipped the Media archive and copied the entire folder \media into \Python24\pyogre\ogre_demos
3. Launched IDLE and loaded "ParticleFXDemo.py"
4. Ran the module (F5)
5. The script loads and exits with this error:
..\src\OgreZip.cpp(254): ogre error 9: ../media/packs/OgreCore.zip - error whilst open archive: Unable to read zip file.

I tried the other scripts and they all end with a similar error. What am I doing wrong??

Thanks!

bigkahuna

15-04-2006 03:42:08

Found the solution here:

http://www.ogre3d.org/phpBB2/viewtopic.php?t=8837&highlight=resources+cfg

Kris Schnee

11-05-2006 01:56:08

I'm having some trouble getting started, in a way that sounds similar.

I just installed PyOgre 1.0.6.0 and Psyco, and put the tutorial media directory (the contents of the ZIP, though I also tried putting the ZIP itself) in C:\Python\pyogre\media. I tried running the first "beginner" program in C:\Python\pyogre\tutorials and saw:
Traceback (most recent call last):
File "C:\Python\pyogre\tutorials\beginner_1.py", line 72, in ?
ta.go()
File "C:\Python\pyogre\tutorials\SampleFramework.py", line 23, in go
if not self._setUp():
File "C:\Python\pyogre\tutorials\SampleFramework.py", line 33, in _setUp
self.root = ogre.Root(ogre.getPluginPath())
File "C:\Python\Lib\site-packages\pyogre\ogre.py", line 13465, in __init__
newobj = _ogre.new_Root(*args)
ExceptionPtr: ..\src\OgreDynLib.cpp(82): ogre error 9: Could not load dynamic library .\RenderSystem_Direct3D9. System Error: The specified module could not be found.

In ogre.txt, the program's output, I saw:
20:24:47: Registering ResourceManager for type HighLevelGpuProgram
20:24:47: Loading library .\RenderSystem_Direct3D9
20:24:47: An exception has been thrown!
-----------------------------------
Details:
-----------------------------------
Error #: 9
Function: DynLib::load
Description: Could not load dynamic library .\RenderSystem_Direct3D9. System Error: The specified module could not be found.
.
File: ..\src\OgreDynLib.cpp
Line: 82

This error looks similar to the one described in this thread, but changing the resources.cfg file doesn't seem to have an effect. That file looks the same as that described above, except that the lines are slightly different eg:
Zip=../media/packs/OgreCore.zip
FileSystem=../media

Does this make any sense? As per the note at the bottom of this page I also installed vcredist_x86. So, now what? I don't need to install Ogre itself in addition to PyOgre, do I?

dermont

11-05-2006 03:01:20

The error refers to your plugins.cfg file which is located in C:\Python24\Lib\site-packages\pyogre directory.

Looks like you dont have DirectX SDK installed or are missing some dll's, check here:
http://www.ogre3d.org/phpBB2addons/viewtopic.php?t=538

If you only want to use OpenGL you need to comment out the DirectX plugin as follows:

# Defines plugins to load
# Define plugin folder
PluginFolder=.

# Define plugins
#Plugin=RenderSystem_Direct3D9
Plugin=RenderSystem_GL
Plugin=Plugin_ParticleFX
Plugin=Plugin_BSPSceneManager
Plugin=Plugin_OctreeSceneManager
Plugin=Plugin_CgProgramManager


If DirectX/missing DLL's are installed correctly there may be a problem with your python path, you could try explicitly defining your folder path, e.g.:

PluginFolder=C:\Python24\Lib\site-packages\pyogre
# Define plugins
#Plugin=RenderSystem_Direct3D9
Plugin=RenderSystem_GL
Plugin=Plugin_ParticleFX
Plugin=Plugin_BSPSceneManager
Plugin=Plugin_OctreeSceneManager
Plugin=Plugin_CgProgramManager

Kris Schnee

11-05-2006 03:48:23

I commented out the one DX9 line, as you said, and now the demos run. Thanks!

I find, though, that when I try compiling beginner_3.py to an EXE (an important test, since I don't want to distribute my source code), it doesn't work. I copied the .py file to the main C:\Python directory, made the usual setup.py file, and ran it as normal. I got, in part:
creating python loader for extension 'bz2'
*** finding dlls needed ***
error: MSVCP80.dll: No such file or directory

Any ideas on this one?

Oh, and the CEGUI demos seem to run, too. The GUI looks nice!

Kris Schnee

18-05-2006 09:54:18

Can anyone tell me, please, why the demos don't compile to EXEs? (See previous message.)

dermont

19-05-2006 09:30:18

The MSVCP80.dll should be installed via vcredist_x86.exe. Do a search on your system in Windows/System , Windows/System32 or main C:\ drive.

On Windows98 it's installed in
c:\Windows\winsxs\x86_Microsoft.VC80.CRT....
c:\Windows\System

I just tried out the instructions from the wiki and everything built fine.

http://www.ogre3d.org/wiki/index.php/PyOgreExecutable

spazz

06-08-2006 19:16:40

I have the same problem...

It runs but runs back because it can't open the zip files.
Zip=../media/packs/OgreCore.zip
FileSystem=../media

So I tried to look into those folders and they weren't even there! :roll:

:arrow: I'll try to get that folder from previews versions.