MOgre 1.8 1st attempt

Ascendion

14-12-2012 18:35:40

Just for grins I pulled down MOgreBuilder and took a shot at building 1.8 stable against it... and it actually didn't go too badly... just a few patch chunks that failed to apply. I haven't really looked at exactly what failed on the patches yet, but I wanted to know what could be done in a MINIMAL fashion to get MOgre on 1.8 even if only a few or none of the new 1.8 features are exposed. The main thing I'm looking to get access to is geometry shaders at this point, but if we can get moving on a 1.8 update I'd be very interested in contributing to get new stuff integrated.

I'm not much of a forum person, but I will be watching this thread, and I'm hanging out in both the Ogre3d and MOgre IRC channels.

Tubulii

15-12-2012 18:40:15

Good to know that someone is trying to build mogre for ogre 1.8.
But we definitly need to wrap all stuff of ogre 1.7.* BEFORE we are working on mogre 1.8.* . There some missing classes and known bugs (shared ptr issue, "unwrapped" void* pointers, ...). Sadly I am not the right person for doing this.

Ascendion

15-12-2012 22:30:31

Come on Tubulii :) moving up to a later version doesn't necessarily hurt us.. the stuff that is already broken will still be broken, and we wont get anything new unless we are bloody lucky with the autowrapping, but we should at least get what we got working hooked up to the newer source. (or were there REALLY that many breaking changes in ogre from 1.7 to 1.8 that can't be handled automatically ??)

I've gotten a bit of understanding now how the builder works and need know a bit more about the wrapping process... I've got a rebuilt clrobject patch that works with the 1.8 ogre, but the builder loses its mind further down the process actually trying to wrap 1.8 (actually causes an exception in autowrap... OUCH !! must be that some of the attributes.xml tweaks don't apply or apply badly to 1.8)

I created the patch by applying the 1.7.3 patch to the 1.8 sources, then hand fixing any failed hunks (all trivial fails.. lines added that blew context, stuff moved too far for the fuzz due to earlier insertions), then I used HG to create the new patch.. the only problem is the new patch requires using HG to apply the patch, which really isn't all that bad an idea since its there and we wont have to carry patch.exe around with us in the builder :)

OK ... so we don't have everything in 1.7 wrapped yet... who is gonna teach me whats gotta be done so I can push things forward ?? :) I'm starting to study meta.xml and attributes.xml, but the errors I'm getting are obscure... they dont point to specific entities within the code that are having problems being wrapped, or if they do I'm not sure exactly where to look... all the errors so far seem to do with InstanceBatch* stuff

time to hunt through the ogre source for that.. but it would help if I understood the autowrap errors better

Ascendion

16-12-2012 08:23:44

OK ... I've made some progress.. if you search my name up on bitbucket you'll find the repos I forked to make life a little easier... I've got the revised clrobject patch in there, with a few additions to fix issues related to forum urls in some of the doc comments, I've got my edits to mogrebuilder committed.. the major one being to use HG to apply the clrobject patch, the rest being changes to default.cfg to pull my forked repos. And lastly an edit to attributes.xml to block out ILImageCodec since it seems to have been completely eliminated in v1.8 and it was making autowrap crash

I'm now getting another crash in autowrap related to the VertexBufferLockGuard type, but I'm too wiped out to go any further with it tonight... at least now anyone can take a look and make suggestions on what to do next to get things working :)

Seeya tomorrow !!

Ascendion

16-12-2012 19:33:22

After adding a couple of ignore lines to attributes.xml for a couple of typedefs in OgreProgressiveMesh.h that were only used internally within the class, I've actually gotten to the point where builder is building against ogre 1.8.. I'll update when the build finishes one way or another :)

wish me luck :)

Beauty

17-12-2012 22:06:45

I whish you good luck.
Especially I say thank you so much for your efforts in figuring out the problems and your reports.
Unfortunately I can't help, because I have too less knowledge in this topic.

In the case that you don't know a specific forum topic, have a look here:
Understanding the Mogre build process


User Caprico has some first experience with Ogre 1.8. Maybe you can combine your forces?
Here is a related post of the topic [MogreBuilder] My mission to build a better Mogre

I started to work on this. I already ported the ClrObject patch. It applies cleanly against the current Ogre 1.8 source but doesn't include any of the new classes in 1.8 yet. MogreBuilder still crashes sometime later in the build process. Didn't found the time to look into this further.
I uploaded the patch file here, in case somebody else wants to try too.


And here is a suggestion of me:

I think it's a good idea to create a second branch for Ogre 1.8 related improvements.
This is good for team orientated development and doesn't disturb the 1.7 build process.
When the 1.8 branch works stable/successful, we can merge it with the default branch.



Ascendion, which version of TortoiseHG / Mercurial did you use for your MogreBuilder builds?
The latest one?
I ask, because there were problems with a specific version (TortoiseHG 2.4.3, Mercurial 2.3).


But we definitly need to wrap all stuff of ogre 1.7.* BEFORE we are working on mogre 1.8.* .
Yes, it would be fine to have all new 1.7 features in Mogre.
Now we had about one year for improvements. I think it's no good idea to stick on the waiting level like a deadlock. :mrgreen:
I think it's no barrier to put efforts to Ogre 1.8.
I'm happy to see that someone improves the Mogre core.


There some missing classes and known bugs (shared ptr issue, "unwrapped" void* pointers, ...).
I didn't know that there are bugs.
Tubulii, it would be nice if you add the known bugs to the Mogre issue tracker. (If not done yet.)
Additionally you could publish the names of the missing classes to an other issue report.
This would be good for the further development.

Ascendion

18-12-2012 16:54:52

I've been trying to work through the issues created by setting up what I thought was needed in attributes.xml based on the errors I was getting, but they just caused more problems, backing up the crash into autowrap until I caught some typos, and now the cygon patch wont apply even though the generated files look exactly correct for the patch.

I'm about fed up with how much the builder hides when it comes to errors in the process, and I've been sitting in the mogre channel on IRC for 5 days and no one has shown up... I wont say this project is dead, but you guys are moving too slow for me...

I think I'm gonna take a shot at resurrecting a swig wrapper setup like ogre.net tried... I really needed linux and mac compatibility anyway so mogre was not going to work for me in the long run. The interesting part about a swig wrapper for .net is it gets us c#, Iron Python, and Iron Ruby on win/mac/*nix all in one shot :) hmmmmmmmm !!!!!

my repos are still up if anyone with more experience wants to see what I've done and maybe take it to the next stage.. but I think I'm pretty much done with it.

Zonder

19-12-2012 13:11:20

I've been trying to work through the issues created by setting up what I thought was needed in attributes.xml based on the errors I was getting, but they just caused more problems, backing up the crash into autowrap until I caught some typos, and now the cygon patch wont apply even though the generated files look exactly correct for the patch.

I'm about fed up with how much the builder hides when it comes to errors in the process, and I've been sitting in the mogre channel on IRC for 5 days and no one has shown up... I wont say this project is dead, but you guys are moving too slow for me...

I think I'm gonna take a shot at resurrecting a swig wrapper setup like ogre.net tried... I really needed linux and mac compatibility anyway so mogre was not going to work for me in the long run. The interesting part about a swig wrapper for .net is it gets us c#, Iron Python, and Iron Ruby on win/mac/*nix all in one shot :) hmmmmmmmm !!!!!

my repos are still up if anyone with more experience wants to see what I've done and maybe take it to the next stage.. but I think I'm pretty much done with it.


I would look at this first before swig http://tirania.org/blog/archive/2011/Dec-19.html

means compiling ogre with GCC though

Ascendion

19-12-2012 16:43:50

I looked at CXXI but it appears to be abandonware... no git commits in a year, and I take it from your statement that I would have to build with gcc on windows using cygwin or mingw even though CXXI says that it has SOME msvc ABI support.. going with gcc on windows is possible but certainly not my first choice....

I might take a FAST shot at building with mingw/CXXI some time this week as I already have a mingw workspace on my system but I don't think that will happen until I have swig at least wrapping, if not functional using the builder tool I'm creating... then it would be simple enough to make a new set of builder projects to build with mingw/cxxi
.
I've taken some of the concepts from MogreBuilder and reworked them into a more data driven system that uses xml project files to define the tasks required to build ogre and any addons.. one project file for ogre, one for each addon so that the end user can select what to build via the builder gui. The project files are cross platform in that they allow you to specify what tasks work with specific platforms. I'll give a post in here when I've got it working enough to shove up on bitbucket :) That will happen hopefully later today or tomorrow.. once I have it actually building ogre, I'm going to work up the GUI then it will get pushed up.

Zonder

19-12-2012 22:14:49

Yeah its a shame it didn't get more support they should have gone for a GSOC on it but with mono splitting from novell they have been more busy getting native compilers sorted and mobile support.

Tubulii

20-12-2012 13:04:24

There some missing classes and known bugs (shared ptr issue, "unwrapped" void* pointers, ...).
I didn't know that there are bugs.
Tubulii, it would be nice if you add the known bugs to the Mogre issue tracker. (If not done yet.)
Additionally you could publish the names of the missing classes to an other issue report.
This would be good for the further development.


The missing classes were (should be) added to the bug tracker already.
And the bugs:
New terrain problem : BlendPointer not found
Possible memory leak in ManagedDataStream
ResourcePtrs: disposal, thread-safety, implicit conversions

I've added them to the issue tracker.

Beauty

20-12-2012 15:21:05

I've added them to the issue tracker.
Verry good - thank you :D

ghiboz

21-02-2013 13:27:09

hi all..
i'm also trying to build this damn mogre with at least ogre 1.8..
i've downloaded the Ascendion mogre builder, compiled it
changed the default.cfg from
OgreBranch = @"v1-7";
to
OgreBranch = @"v1-8";

launched RUN_example.bat, after a while:


so i've tried to remove the patches:

same error...

does anybody reached to use mogrebuilder to build mogre with ogre 1.8.x?

Zonder

21-02-2013 13:33:33

GLES shouldn't be wrapped. Not sure how you can exclude it from the patcher though someone else might know

Ascendion

21-02-2013 15:27:10

just look at what failed on the hunks, and look at the original file.. its most likely a bit of fuzz (offset... lines moved further than the patcher likes) which you can fix by manually editing the patch, or manually editing the target file then regenerating the patch (I'm checking here cause I thought I had commited all the updated patches)

Ascendion

21-02-2013 15:45:26

are you sure you got MY MogreBuilder ?? I just ran my local copy and it patched 100% and I'm in sync with the repo

(watching it build binaries now.. but that will fail at a later step)

the right repo to start from is https://Ascendion@bitbucket.org/Ascendion/mogre-v1-8.. it will grab and build my builder

here is the top part of my error log after my latest run


Checking out the source code of Mogre (please be patient)
warning: Main/Mogre_vs2010.opensdf cannot be removed
warning: Main/Mogre_vs2010.sdf cannot be removed
Running CMake on Ogre source tree
-- Could not locate ZLIB
-- Could not locate FreeImage
-- Could not locate FREETYPE
-- Could not locate Cg
-- Could not locate POCO
-- Could not locate TBB
-- Could not locate GLSL_Optimizer
-- Could not locate HLSL2GLSL
-- Could not locate OIS
-- Could not locate Softimage
-- Could not locate CppUnit
CMake Error at CMake/Utils/MacroLogFeature.cmake:100 (MESSAGE):
-----------------------------------------------------------------------------
-- The following REQUIRED packages could NOT be located on your system.
-- Please install them before continuing this software installation.
-- If you are in Windows, try passing -DOGRE_DEPENDENCIES_DIR=<path to
dependencies>
-----------------------------------------------------------------------------
+ freetype: Portable font engine <http://www.freetype.org>
-----------------------------------------------------------------------------
Call Stack (most recent call first):
CMake/Dependencies.cmake:229 (MACRO_DISPLAY_FEATURE_LOG)
CMakeLists.txt:194 (include)
Running CMake again to include fresh built Ogre depencies
-- Could not locate POCO
-- Could not locate TBB
-- Could not locate GLSL_Optimizer
-- Could not locate HLSL2GLSL
-- Could not locate Softimage
-- Could not locate CppUnit
send_errorC:/Users/John/Documents/Visual Studio 2010/Projects/Mogre-V1.8/Build/Main/OgreSrc/ogre/Dependencies/src/bin/debug/OIS_d.dll did not exist, can't install!
-- The following OPTIONAL packages could NOT be located on your system.
send_errorC:/Users/John/Documents/Visual Studio 2010/Projects/Mogre-V1.8/Build/Main/OgreSrc/ogre/Dependencies/src/bin/release/OIS.dll did not exist, can't install!
Autowrapping Ogre classes
Notice: Output directory `build\doxyxml' does not exist. I have created it for you.
GroupDef::insertMembers(): member `InstanceBatchShader' (typeid=9) with scope `Ogre::InstancedEntity' inserted in group scope `Scene'!
GroupDef::insertMembers(): member `InstanceBatchHW' (typeid=9) with scope `Ogre::InstancedEntity' inserted in group scope `Scene'!
GroupDef::insertMembers(): member `InstanceBatchHW_VTF' (typeid=9) with scope `Ogre::InstancedEntity' inserted in group scope `Scene'!
GroupDef::insertMembers(): member `BaseInstanceBatchVTF' (typeid=9) with scope `Ogre::InstancedEntity' inserted in group scope `Scene'!
Building Mogre
'AnimationContainer' : is not a member of 'Mogre'
'AnimationContainer' : is not a member of 'Mogre'
syntax error : missing ';' before identifier 'AnimationContainer'
missing type specifier - int assumed. Note: C++ does not support default-int
syntax error : missing ';' before '^'
missing type specifier - int assumed. Note: C++ does not support default-int
missing type specifier - int assumed. Note: C++ does not support default-int
'Container' : looks like a function definition, but there is no parameter list.
'AnimationContainer' : is not a member of 'Mogre'
syntax error : missing ';' before '^'
missing type specifier - int assumed. Note: C++ does not support default-int
missing type specifier - int assumed. Note: C++ does not support default-int
'property' : missing an adjacent semicolon, could be either keyword or identifier.
syntax error : missing ';' before 'Mogre::Animation::InterpolationMode'
'property' : global or static variable may not have managed type 'Mogre::Animation'
'Mogre::Animation::Animation' : no appropriate default constructor available
'{dtor}' : is not a member of 'System::IDisposable'
'DefaultInterpolationMode' : looks like a function definition, but there is no parameter list; skipping apparent body
syntax error : 'property'
syntax error : missing ';' before '{'
'{' : missing function header (old-style formal list?)
syntax error : 'property'
syntax error : missing ';' before '{'
'{' : missing function header (old-style formal list?)
syntax error : 'property'
syntax error : missing ';' before '{'
'{' : missing function header (old-style formal list?)
syntax error : 'property'
syntax error : missing ';' before '{'
'{' : missing function header (old-style formal list?)
syntax error : 'property'
syntax error : missing ';' before '{'
'{' : missing function header (old-style formal list?)
syntax error : 'property'
syntax error : missing ';' before '{'
'{' : missing function header (old-style formal list?)
syntax error : 'property'
syntax error : missing ';' before '{'
'{' : missing function header (old-style formal list?)
'AnimationContainer' : is not a member of 'Mogre'
'AnimationContainer' : undeclared identifier
'c' : undeclared identifier
'_notifyContainer' : illegal use of type 'void'
unable to recover from previous error(s); stopping compilation
'AnimationContainer' : is not a member of 'Mogre'
'AnimationContainer' : is not a member of 'Mogre'
syntax error : missing ';' before identifier 'AnimationContainer'
missing type specifier - int assumed. Note: C++ does not support default-int
syntax error : missing ';' before '^'
missing type specifier - int assumed. Note: C++ does not support default-int
missing type specifier - int assumed. Note: C++ does not support default-int
'Container' : looks like a function definition, but there is no parameter list.
'AnimationContainer' : is not a member of 'Mogre'
syntax error : missing ';' before '^'
missing type specifier - int assumed. Note: C++ does not support default-int
missing type specifier - int assumed. Note: C++ does not support default-int
'property' : missing an adjacent semicolon, could be either keyword or identifier.
syntax error : missing ';' before 'Mogre::Animation::InterpolationMode'
'property' : global or static variable may not have managed type 'Mogre::Animation'
'Mogre::Animation::Animation' : no appropriate default constructor available
'{dtor}' : is not a member of 'System::IDisposable'
'DefaultInterpolationMode' : looks like a function definition, but there is no parameter list; skipping apparent body
syntax error : 'property'


this is where I got stalled because there was no file or line number information, nor any documentation on how to deal with these types of errors when upgrading (or at least none I could really understand), and what changes I attempted to make to resolve the missing symbols just made things worse....

I've moved off to other engines/frameworks since creating this, so I won't be much help moving forward