SkyX

16 views
Skip to first unread message

artn3r

unread,
Nov 22, 2009, 9:43:36 PM11/22/09
to Python Ogre Developers
Hello Andy,
Now i switched to the mailing list!
I successfully compiled your new skyx wrapper,
imported it in my app, but there is a problem now:

If i do

>> import _skyx_

then this error happens:

Traceback (most recent call last):
File "<console>", line 1, in <module>
TypeError: No to_python (by-value) converter found for C++ type: enum
Ogre::SceneBlendType

if i do

>>> import _skyx_ as skyx
>>> dir(skyx)

i only see this classes:

['AtmosphereManager', 'CloudLayer', 'CloudsManager', 'ColorGradient',
'GPUManage
r', '__doc__', '__name__', '__package__']

Should be much more, especially the main class (SkyX) is not there...

Do you have any suggestions how to work on?

Thanks for your support,
Christian (artn3r from the forums)

Andy Miller

unread,
Nov 23, 2009, 3:34:16 AM11/23/09
to python-ogre...@googlegroups.com
You need to import ogre (ogre.renderer.OGRE) before importing skyx (ogre.addons.skyx)

>>> import ogre.renderer.OGRE as ogre
>>> import ogre.addons.skyx as skyx
>>> print dir(skyx)
['AtmosphereManager', 'CloudLayer', 'CloudsManager', 'ColorGradient', 'CompileDate__', 'CompileTime__', 'DataManager', '
FastFakeRandom', 'GPUManager', 'GeometryBlock', 'GeometryManager', 'MeshManager', 'MoonManager', 'PythonOgreDetail__', '
PythonOgreVersion__', 'PythonVersion__', 'SkyX', 'VClouds', 'VCloudsManager', 'Version__', '__builtins__', '__doc__', '_
_file__', '__name__', '__package__', '__path__', '_skyx_']
>>>

Andy


2009/11/23 artn3r <chri...@artn3r.com>

--

You received this message because you are subscribed to the Google Groups "Python Ogre Developers" group.
To post to this group, send email to python-ogre...@googlegroups.com.
To unsubscribe from this group, send email to python-ogre-devel...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/python-ogre-developers?hl=.



artn3r

unread,
Nov 23, 2009, 3:51:56 AM11/23/09
to Python Ogre Developers
Ok, thanks i got it already working.
But there is another issue, which i dont't understand.
If I want to create an instance of the SkyX class, this
error happens:

>>> import ogre.renderer.OGRE as ogre
>>> import ogre.addons.skyx as skyx
>>>print scenemanager
<ogre.renderer.OGRE._ogre_.SceneManager object at 0x062CF848>
>>>print cam
Camera(Name='Camera', pos=Vector3(0, -100, -933.003), direction=Vector3
(0, 0, 1)
,near=20, far=30000, FOVy=45, aspect=1.33333, , xoffset=0, yoffset=0,
focalLengt
h=1, NearFrustumPlane=Plane(normal=Vector3(0, 0, 1), d=913.003),
FarFrustumPlane
=Plane(normal=Vector3(0, 0, -1), d=29067.7), LeftFrustumPlane=Plane
(normal=Vecto
r3(-0.87537, 0, 0.483453), d=451.063), RightFrustumPlane=Plane
(normal=Vector3(0.
87537, 0, 0.483453), d=451.063), TopFrustumPlane=Plane(normal=Vector3
(0, -0.9238
8, 0.382683), d=264.657), BottomFrustumPlane=Plane(normal=Vector3(0,
0.92388, 0.
382683), d=449.433))
>>> sky = skyx.SkyX(scenemanager, cam)
Traceback (most recent call last):
File "<console>", line 1, in <module>
ArgumentError: Python argument types in
SkyX.__init__(SkyX, SceneManager, Camera)
did not match C++ signature:
__init__(struct _object *, class Ogre::SceneManager * sm, class
Ogre::Camera
* c)

I do not have an answer of that problem, it seems like python doesn't
know the
scenemanager and camera objects are from Ogre:: namespace?
Thanks for your help!

On 23 Nov., 09:34, Andy Miller <nzmill...@gmail.com> wrote:
> You need to import ogre (ogre.renderer.OGRE) before importing skyx
> (ogre.addons.skyx)
>
> >>> import ogre.renderer.OGRE as ogre
> >>> import ogre.addons.skyx as skyx
> >>> print dir(skyx)
>
> ['AtmosphereManager', 'CloudLayer', 'CloudsManager', 'ColorGradient',
> 'CompileDate__', 'CompileTime__', 'DataManager', '
> FastFakeRandom', 'GPUManager', 'GeometryBlock', 'GeometryManager',
> 'MeshManager', 'MoonManager', 'PythonOgreDetail__', '
> PythonOgreVersion__', 'PythonVersion__', 'SkyX', 'VClouds',
> 'VCloudsManager', 'Version__', '__builtins__', '__doc__', '_
> _file__', '__name__', '__package__', '__path__', '_skyx_']
>
>
>
> Andy
>
> 2009/11/23 artn3r <christ...@artn3r.com>
> > python-ogre-devel...@googlegroups.com<python-ogre-developers%2Bunsu...@googlegroups.com>
> > .
Reply all
Reply to author
Forward
0 new messages