[realXtend] Re: LudoCraft's Tundra 2.0-preview installer and code is out!
New attempts: added these: (header) //getters for Transform pos,rot and scale float3 objects float3 position(const Transform* self); float3 rotation(const Transform* self); float3 scale(const Transform* self); (source) float3 TundraDecorator::position(const Transform* self) { return self-pos; } float3 TundraDecorator::rotation(const Transform* self) { return self-rot; } float3 TundraDecorator::scale(const Transform* self) { return self-scale; } = = = = they compile without errors but give this error at py runtime: Error: PythonScriptModule: Called float3 rotation(), return type 'float3' is ignored because it is unknown to PythonQt. Probably you should register it using qRegisterMetaType() or add a default constructor decorator to the class. - - - - - - Now I might try registering or adding a constructor, but I don't know whether to add it to TundraWrapper, to Transform (which I've included of course) or to float3. This is a bit over my head... On Aug 1, 5:19 pm, Jonne Nauha jo...@adminotech.com wrote: Good work, when you are done adding stuff please give me a pastebin.compaste of the header and cpp and i will put them to the repo! Or just attach the files, or we can give you git access if you can handle git commits. Might consider committing if I can make them work;-) The exit crash is still a bit open, it is because we kill the py objects, then the one that is sending the signals gets killed and we guess (with toni) that it goes and pokes the dead py ptrs somehow. Its kind of weird why qt would do that but it propably fails somewhere there. This is propably one reason why python was not uninitialized properly in the previous python module. disconnecting should be similar obj.diconnect(sameSignal(), receiverCallable) if it goes wrong the py will print suggestions for you. Does not crash anymore, exits cleanly, thanks. Best regards, Jonne Nauha Adminotech developer On Mon, Aug 1, 2011 at 4:41 PM, ilikia t...@ee.oulu.fi wrote: OK, I've got more fun for you guys. I added these functions into PythonScriptModule/TundraWrapper class: in the header: //getters for float3 x, y and z coordinates float x(float3* self); float y(float3* self); float z(float3* self); in the source: float TundraDecorator::x(float3* self) { return self-x; } float TundraDecorator::y(float3* self) { return self-y; } float TundraDecorator::z(float3* self) { return self-z; } and ran it in py like this: import tundra as tundra class CameraTest: def __init__(self): tundra.LogInfo(* Python CameraTest starting *) tundra.Frame().connect(Updated(float), self.update) def update(self, frametime): print tundra._pythonscriptmodule.GetActiveCamera().GetComponentRaw(EC_Placeable).Position().x() print tundra._pythonscriptmodule.GetActiveCamera().GetComponentRaw(EC_Placeable).Position().y() print tundra._pythonscriptmodule.GetActiveCamera().GetComponentRaw(EC_Placeable).Position().z() = = = = = It works, hooray. But my efforts to do the same with the rotation haven't so far. Tried something like this: float3 TundraDecorator::rotation(Quat* self) { return self-ToEulerZYX; } Which compiles, but crashes at runtime, if I try this: print tundra._pythonscriptmodule.GetActiveCamera().GetComponentRaw(EC_Placeable).Orientation().rotation().z() same thing with this: float3 TundraDecorator::rot(Transform* self) { return self-rot; } and in py print tundra._pythonscriptmodule.GetActiveCamera().GetComponentRaw(EC_Placeable).transform.rot().z() Crashes. Ahh, one more stupid question: should probably add a graceful exit function of some kind, because the line at init tundra.Frame().connect(Updated(float), self.update) causes a crashdump at Tundra exit. A hint on disconnecting gracefully? -- http://groups.google.com/group/realxtend http://www.realxtend.org -- http://groups.google.com/group/realxtend http://www.realxtend.org
[realXtend] Re: LudoCraft's Tundra 2.0-preview installer and code is out!
Well, at some point I'll have to start committing. I've done it with svn, for a real company, albeit only on hourly basis. But I thought I'll write some more of them, basically like they used to be in Vector3dfDecorator and TransformDecorator, and do some testing first. On Aug 2, 2:04 pm, Toni Alatalo t...@playsign.net wrote: On Aug 2, 2011, at 1:29 PM, ilikia wrote: All right, figured out the metatype thingy. Added this to TundraWrapper.cpp before my functions: int id = qRegisterMetaTypefloat3(float3); Now they work. Great! If you want my code, just tell me where to paste it. If you wanna learn GIT, you can make an account on github, clone the repo there, and push your changes to your copy of it. Then you can make a pull request using github's web UI. And applying it to the central repo is just a push of a button. You can also skip that and just say where pushed, so we can go take a look and get it over. We can also just give access to the repo, but also for that you need to make the account, so basically the same to do the above anyway. Having the own copy there is a nice way to test the commands etc. to see what happens e.g. when you push. If you don't wanna bother with git now, you can e.g. just mail the code to the -dev list or put to somewhere on the web .. or submit a patch to the issue tracker (I've sometimes used the file attachment thingie in the google code repo, i suppose github has that too). ~Toni -- http://groups.google.com/group/realxtend http://www.realxtend.org
Re: [realXtend] Re: LudoCraft's Tundra 2.0-preview installer and code is out!
Ilikia, I just landed fix for the python crash last night (was a looong night debugging :) https://github.com/realXtend/naali/commit/49e2db22d37f5e29b3e2700d16b42b91d1f9e517 Pull head again to your clone, run the update deps bat and you should have it :) It needed a custom PythonQt that I have put into VC9 and VC10 prebuild deps now, also the sources are there in sources branch. Best regards, Jonne Nauha Adminotech developer On Tue, Aug 2, 2011 at 2:17 PM, ilikia t...@ee.oulu.fi wrote: Well, at some point I'll have to start committing. I've done it with svn, for a real company, albeit only on hourly basis. But I thought I'll write some more of them, basically like they used to be in Vector3dfDecorator and TransformDecorator, and do some testing first. On Aug 2, 2:04 pm, Toni Alatalo t...@playsign.net wrote: On Aug 2, 2011, at 1:29 PM, ilikia wrote: All right, figured out the metatype thingy. Added this to TundraWrapper.cpp before my functions: int id = qRegisterMetaTypefloat3(float3); Now they work. Great! If you want my code, just tell me where to paste it. If you wanna learn GIT, you can make an account on github, clone the repo there, and push your changes to your copy of it. Then you can make a pull request using github's web UI. And applying it to the central repo is just a push of a button. You can also skip that and just say where pushed, so we can go take a look and get it over. We can also just give access to the repo, but also for that you need to make the account, so basically the same to do the above anyway. Having the own copy there is a nice way to test the commands etc. to see what happens e.g. when you push. If you don't wanna bother with git now, you can e.g. just mail the code to the -dev list or put to somewhere on the web .. or submit a patch to the issue tracker (I've sometimes used the file attachment thingie in the google code repo, i suppose github has that too). ~Toni -- http://groups.google.com/group/realxtend http://www.realxtend.org -- http://groups.google.com/group/realxtend http://www.realxtend.org
Re: [realXtend] Re: tundra addons suggestion/ request
I'm sure ogitor is compatible as long as it has the .scene file in the same folder with the meshes that are referenced in the .scene file. It should not matter what produced the .scene file as long as it sticks to the spec. But you need to have the meshes in the same folder (afaik) for tundra to find the actual assets referenced in the .scene file. Hydrax and skyx will not work like this, I dont even know how that would be described in the .scene (i think it only tells where mesh nodes should be etc.). And either way our hydrax and skyx support is via ECs. Make a new entity and add skyx and hydrax components to it and you are done, there is nothing magical about them. Best regards, Jonne Nauha Adminotech developer On Tue, Aug 2, 2011 at 9:22 PM, MasterJ djmat...@hotmail.com wrote: Good evening, I have found a great ogre editor named Ogitor. it's really good to use it and can export the scene as .scene file. actually if i drag and drop this famous .scene file created with Ogitor it's appear blank on Tundra 1.0.8 or 2 it's totaly okay because i simply put hydrax and skyx with settings on Ogitor. so for tundra 1.0.8 it's can not work but for tundra 2.0 i don't exactly know how to made it work. logicaly i must drop meshes and .material on the same folder as the .scene file is problem is for hydrax and skyx i ... of course... have nothing like that probably i must put the /media/ folder of hydrax and skyx into the smae directory as the .scene file. But it's just because actually Ogitor is not compatible with Tundra, simply, what you think about is that possible to made it work with tundra? then we have our building tool ;). source code and download is here : http://www.ogitor.org/Ogitor+0.4.4 more info on the wiki: http://www.ogitor.org/HomePage On 17 juil, 13:39, MasterJ djmat...@hotmail.com wrote: hello to all i want to load a new module on tundra 1.0.8 at startup. example hydrax.dll wich file must i need to mdoify for load hydrax at startup? then i can test if it's work this time. On 6 juil, 21:35, MasterJ djmat...@hotmail.com wrote: Hello to all i want to know what you think about that : adding some addons(integrate them?) as building tools like : ofusion:http://www.ofusiontechnologies.com/oFusion.html i have searched a few for Ogre Forests (made forests) but i can't found any picture i can only found this addon inside: python-ogre package and i 'm extremly lost with that (possible i must compile that ) -- http://groups.google.com/group/realxtend http://www.realxtend.org -- http://groups.google.com/group/realxtend http://www.realxtend.org
[realXtend] Re: tundra addons suggestion/ request
okay good to know about skyx and hydrax so no need to add them on Ogitor ;). ok let's see if Ogitor made .material files for terrain when we done some default Terrain i will report my work here in a few . On 2 août, 20:33, Jonne Nauha jo...@adminotech.com wrote: I'm sure ogitor is compatible as long as it has the .scene file in the same folder with the meshes that are referenced in the .scene file. It should not matter what produced the .scene file as long as it sticks to the spec. But you need to have the meshes in the same folder (afaik) for tundra to find the actual assets referenced in the .scene file. Hydrax and skyx will not work like this, I dont even know how that would be described in the .scene (i think it only tells where mesh nodes should be etc.). And either way our hydrax and skyx support is via ECs. Make a new entity and add skyx and hydrax components to it and you are done, there is nothing magical about them. Best regards, Jonne Nauha Adminotech developer On Tue, Aug 2, 2011 at 9:22 PM, MasterJ djmat...@hotmail.com wrote: Good evening, I have found a great ogre editor named Ogitor. it's really good to use it and can export the scene as .scene file. actually if i drag and drop this famous .scene file created with Ogitor it's appear blank on Tundra 1.0.8 or 2 it's totaly okay because i simply put hydrax and skyx with settings on Ogitor. so for tundra 1.0.8 it's can not work but for tundra 2.0 i don't exactly know how to made it work. logicaly i must drop meshes and .material on the same folder as the .scene file is problem is for hydrax and skyx i ... of course... have nothing like that probably i must put the /media/ folder of hydrax and skyx into the smae directory as the .scene file. But it's just because actually Ogitor is not compatible with Tundra, simply, what you think about is that possible to made it work with tundra? then we have our building tool ;). source code and download is here : http://www.ogitor.org/Ogitor+0.4.4 more info on the wiki: http://www.ogitor.org/HomePage On 17 juil, 13:39, MasterJ djmat...@hotmail.com wrote: hello to all i want to load a new module on tundra 1.0.8 at startup. example hydrax.dll wich file must i need to mdoify for load hydrax at startup? then i can test if it's work this time. On 6 juil, 21:35, MasterJ djmat...@hotmail.com wrote: Hello to all i want to know what you think about that : adding some addons(integrate them?) as building tools like : ofusion:http://www.ofusiontechnologies.com/oFusion.html i have searched a few for Ogre Forests (made forests) but i can't found any picture i can only found this addon inside: python-ogre package and i 'm extremly lost with that (possible i must compile that ) -- http://groups.google.com/group/realxtend http://www.realxtend.org -- http://groups.google.com/group/realxtend http://www.realxtend.org
[realXtend] Ogitor (Ogre Editor)
hello to all i have try a few to export some content created directly with an Ogre editor named : Ogitor 0.4.4 actually if i drag and drop a .scene file created with into tundra, tundra tell me can't fund .material file. problem is ogitor doesn't made .material file or use it the .scene file look like this : http://www.masterj.name/terrain.scene. any idea how to have it on tundra? or how to have that on a .material file? (if possible) feel free to download it and try Greetings, MasterJ -- http://groups.google.com/group/realxtend http://www.realxtend.org