Page 8 of 11

Re: Ogre Meshy 1.4 (Mesh viewer, Windows Installer & Linux s

Posted: Mon Sep 19, 2011 2:56 pm
by Brocan
It would be great if you could add an option to see the normals of the vertex/faces :D

Re: Ogre Meshy 1.4 (Mesh viewer, Windows Installer & Linux s

Posted: Mon Sep 19, 2011 7:06 pm
by dark_sylinc
Point taken.

Requested features in my TODO list:
  • Follow camera on clicked position in the mesh.
  • Light attached side to the camera like in most modeling programs.
  • Display vertex/face normals.
  • Visual dummies for debugging point & spot lights position and direction.
  • Move toolbar to the left corner.
  • Solve bone names being so close in edge cases where they overlap and become unreadable.
They'll eventually get implemented. I'm just working on other stuff meanwhile. They usually get a boost in the queue when it happens I need a specific feature.
Oh, btw, I've decided for Bitbucket. I just need to create the repo and upload the code. Start up point will be v1.4

Re: Ogre Meshy 1.4 (Mesh viewer, Windows Installer & Linux s

Posted: Mon Sep 19, 2011 7:32 pm
by Brocan
I'm doing a heavy use of your application, and i've two more ideas that (i think) could be useful to add if you want! :mrgreen:

- The first is the addition of a billboard in the same position than the point/spot lights. Sometimes is difficult to find where are the lights (specially if you are debugging materials :D )

- The second is the possibility of moving the selected light in the same way that camera does when you push (for example) the right mouse button.

Thanks for your great work!

Re: Ogre Meshy 1.4 (Mesh viewer, Windows Installer & Linux s

Posted: Tue Oct 04, 2011 8:38 pm
by duststorm
Does it have support for Ogre 1.7?
The latest version of meshy compiles with Ogre1.7 if you change one method header:

In src/Core/wxOgreMeshViewerMainFrameImpl.h (line 140)
change

Code: Select all

void messageLogged( const Ogre::String& message, Ogre::LogMessageLevel lml,
                                                bool maskDebug, const Ogre::String &logName, bool& skipThisMessage );
into

Code: Select all

void messageLogged( const Ogre::String& message, Ogre::LogMessageLevel lml,
                                                bool maskDebug, const Ogre::String &logName );
In src/Core/wxOgreMeshViewerMainFrameImpl.h (line 1541)
change

Code: Select all

void MeshyMainFrameImpl::messageLogged( const Ogre::String& message, Ogre::LogMessageLevel lml,
                                                                                                        bool maskDebug, const Ogre::String &logName, bool& skipThisMessage )
into

Code: Select all

void MeshyMainFrameImpl::messageLogged( const Ogre::String& message, Ogre::LogMessageLevel lml,
                                                                                                        bool maskDebug, const Ogre::String &logName )
There is a change in the OGRE API from 1.7 where messageLogged receives an extra parameter, and this breaks the build for Ogre 1.7. Since Meshy doesn't really use this parameter, nothing changes.

You will also need to generate Ogre 1.7 models for the meshes, which is not that difficult if you have blender with the ogre mesh exporter (for 1.7) because the .blend files are included in the source.

Re: Ogre Meshy 1.4 (Mesh viewer, Windows Installer & Linux s

Posted: Tue Oct 04, 2011 9:26 pm
by dark_sylinc
Hi. Thanks for posting an explanation.
Most likely Meshy compiles with Ogre 1.7.1 but is not guaranteed.

I understand the most important aspect in a tool like a mesh viewer is having binary compatibility than rather library compatibility at code level. Which is the philosophy from Ogre Meshy and my other tools too (that are user oriented, that is).
Linking against Ogre 1.8 provides binary compatibility with both new and old mesh formats.

Users that need to compile against Ogre 1.7 for their own (custom) needs may incorporate all necessary changes.
This doesn't mean of course, that Ogre Meshy breaks linkage on purpose. I'm friendly on that aspect, but it's not a priority. Next time I'll put a macro to solve it if I remember to.

Cheers
Dark Sylinc

Re: Ogre Meshy 1.4 (Mesh viewer, Windows Installer & Linux s

Posted: Tue Oct 04, 2011 9:40 pm
by duststorm
dark_sylinc wrote:I understand the most important aspect in a tool like a mesh viewer is having binary compatibility
I agree with you there. Using Ogre 1.8 to distribute it as a package has the big advantage of model compatibility.
Maybe it would be great to also have some linux binary (.deb ?) packages, but I agree that is a lot of work to maintain.

One more remark. The current "make install" script contains a "su root" command for installing the model viewer under linux, but I believe this is not such a good idea. Primarily because a lot of distributions (like ubuntu) use sudo instead, and have the root user disabled. I would just leave out the su root, and leave it up to the user to type sudo/su or whatever. This is how it is usually done.

Re: Ogre Meshy 1.4 (Mesh viewer, Windows Installer & Linux s

Posted: Thu Nov 03, 2011 10:18 am
by syedhs
I am starting to use OgreMeshy more often, and I wonder what others think of adding script within OgreMeshy.. Here are the following uses..

:arrow: Change material of the already loaded object.. - currently I have to change the material by converting to xml and change it in notepad and convert back to mesh, tiresome.

:arrow: Load more than one entities and then, position and orient them accordingly. Load lights too - can be a mini scene viewer.

:arrow: Add resource location - default now is the same path as the mesh which is limiting..

:arrow: Can change shader parameter in the fly.. therefore we can tweak it until we are satisfied.

For the last one - yes of course we can build a gui for it to make it more user-friendly (and artist friendly), but it could be too much work. Script would be simple.

If no one objects, what would be the script language of choice - I am more into lua via luabind. Just to be clear, I am offering myself to do this. :)

Re: Ogre Meshy 1.4 (Mesh viewer, Windows Installer & Linux s

Posted: Thu Nov 03, 2011 10:35 am
by syedhs
And I just realized that it doesn't recognize RTShader - probably the Ogremain is not compiled with RTShader option. @dark_sylinc, Is it because you simple didn't use RTShader or is it due to other reasons?

Re: Ogre Meshy 1.4 (Mesh viewer, Windows Installer & Linux s

Posted: Thu Nov 03, 2011 3:56 pm
by dark_sylinc
Hi, while I can see demand for it, if you're really into it, I think it would be best to carefully fork Meshy into a different application.
Keep two versions: the lite and the full versions.

With all the changes you suggest, it will stop being a mesh viewer. And from there it can quickly go everything to hell (more features = more failure possibilities, clunkier interface, etc)
syedhs wrote::arrow: Change material of the already loaded object.. - currently I have to change the material by converting to xml and change it in notepad and convert back to mesh, tiresome.
Ok, can be done in Meshy.
I was also planning highlighting a selection when a submesh is selected.
syedhs wrote: :arrow: Load more than one entities and then, position and orient them accordingly. Load lights too - can be a mini scene viewer.
Nope. It's not a scene viewer.
syedhs wrote: :arrow: Add resource location - default now is the same path as the mesh which is limiting..
Already supported. Press "Alt+F" (load resources.cfg) then hit F5 to reload the mesh.
syedhs wrote: Can change shader parameter in the fly.. therefore we can tweak it until we are satisfied.
You can always press F5 (or F8 if the material is defined outside the mesh' directory) to see the changes. Not exactly real time, but it's something.
I was thinking this fits more a material editor (or integrated Tool), rather than a mesh viewer.
syedhs wrote: For the last one - yes of course we can build a gui for it to make it more user-friendly (and artist friendly), but it could be too much work. Script would be simple.
Simple for developers, but the tool is aimed at artists. I'm afraid both ways ought to be supported. One step at a time though.

Sorry for the discouraging message. Those are cool suggestions, nevertheless OgreMeshy can be used as a starting point, potentially using the same core so both projects get benefit from improvements.

Cheers
Dark Sylinc

Re: Ogre Meshy 1.4 (Mesh viewer, Windows Installer & Linux s

Posted: Thu Nov 03, 2011 3:58 pm
by dark_sylinc
syedhs wrote:And I just realized that it doesn't recognize RTShader - probably the Ogremain is not compiled with RTShader option. @dark_sylinc, Is it because you simple didn't use RTShader or is it due to other reasons?
Forgot about RTShaders question. I never used it nor looked into it, so don't know how to integrate it. But would be cool if supported.

EDIT: The code is now at Bitbucket, you can grab it here!!

Re: Ogre Meshy 1.4 (Mesh viewer, Windows Installer & Linux s

Posted: Fri Nov 04, 2011 9:24 am
by syedhs
With all the changes you suggest, it will stop being a mesh viewer. And from there it can quickly go everything to hell (more features = more failure possibilities, clunkier interface, etc)
I don't think this will be a full blown scene viewer.. the end result as far as I can see is it can view more than one mesh, can be a lot too if you want - but that is all. One of the main reasons to view more than one mesh is to have quick comparison (eg old vs new material) or fast iteration of material development.

What I am thinking is to have a script with certain extension (eg .olua - I don't know.. I just made that up :mrgreen: ) that when you double click it, it will launch Ogre meshy app with say 3 predefined meshes and their respective resource locations. So that way, you don't have to do it over and over again for resource location which may vary depending on the ogre meshes loaded.
syedhs wrote::arrow: Change material of the already loaded object.. - currently I have to change the material by converting to xml and change it in notepad and convert back to mesh, tiresome.
Ok, can be done in Meshy.
I was also planning highlighting a selection when a submesh is selected.
That sounds a nice feature to me, probably if you have more time to have flag (checkbox button) which when turned on, display submeshes in different colour..
syedhs wrote: :arrow: Load more than one entities and then, position and orient them accordingly. Load lights too - can be a mini scene viewer.
Nope. It's not a scene viewer.
Like what I told above..
syedhs wrote: :arrow: Add resource location - default now is the same path as the mesh which is limiting..
Already supported. Press "Alt+F" (load resources.cfg) then hit F5 to reload the mesh.
Ditto - and I think you know this can be quite limiting because different mesh may have different resource locations so it is cumbersome to keep changing the resource locations. If you add all possible resource locations, then resource name conflicts may happen.
syedhs wrote: Can change shader parameter in the fly.. therefore we can tweak it until we are satisfied.
You can always press F5 (or F8 if the material is defined outside the mesh' directory) to see the changes. Not exactly real time, but it's something.
I was thinking this fits more a material editor (or integrated Tool), rather than a mesh viewer.
You are right. better not overdo it.. but an evolution is not unusual to hear nowadays ;)
Sorry for the discouraging message. Those are cool suggestions, nevertheless OgreMeshy can be used as a starting point, potentially using the same core so both projects get benefit from improvements.
That is okay, I prefer much honest feedback rather than polite message (but not true) hehe :mrgreen:

Re: Ogre Meshy 1.4 (Mesh viewer, Windows Installer & Linux s

Posted: Fri Nov 04, 2011 6:55 pm
by dark_sylinc
Hi!

The issue about adding new features, is not the feature itself, but how will some user-friendly interfaces be made to solve the new problems these features create. That's what needs to be haunted down.

For example:
syedhs wrote: I don't think this will be a full blown scene viewer.. the end result as far as I can see is it can view more than one mesh, can be a lot too if you want - but that is all. One of the main reasons to view more than one mesh is to have quick comparison (eg old vs new material) or fast iteration of material development.
Then how do you control them individually? How it can be made so that is better & easier than opening two instances of Ogre Meshy?
syedhs wrote: What I am thinking is to have a script with certain extension (eg .olua - I don't know.. I just made that up :mrgreen: ) that when you double click it, it will launch Ogre meshy app with say 3 predefined meshes and their respective resource locations. So that way, you don't have to do it over and over again for resource location which may vary depending on the ogre meshes loaded.
Mmm... that might work. So, it's the regular old viewer, with little GUI overhead, and a simple script format (Lua is fine) that allows Meshy to load multiple meshes with multiple resources. Advanced users would take advantage of that. Mmm may be possible.

Be aware on how F5 (mesh reload) is supposed to work (reload the entire scene?) and that the camera's math assumes there's only one mesh loaded. Same happens with F8 (reload resources from everyone?)
Mesh selection through raypicking could be implemented. But then it starts seriously looking like a scene viewer.
syedhs wrote: That sounds a nice feature to me, probably if you have more time to have flag (checkbox button) which when turned on, display submeshes in different colour..
I was actually thinking when the submesh is selected in the Info tab, the submesh is rendered again with additive pass over the original submesh + bounding box display (in case colour saturation happens, i.e. full white)
syedhs wrote: I think you know this can be quite limiting because different mesh may have different resource locations so it is cumbersome to keep changing the resource locations. If you add all possible resource locations, then resource name conflicts may happen.
Ok, that's strange. Because all (most?) Ogre projects I've worked with have the following structure:
  • They have a resources.cfg per project.
  • They have meshes each belonging to a different project (it's hard to see a team with +3 different projects)
  • Usually when working on meshes on materials, they're all about the same project. Which equals same resources.cfg. Loading it is all they need.
Your scenario is very weird for common cases of Ogre usage. If it's really THAT troubling, I was planning in adding the last 4/5 resources loaded in the File menu anyway. That's a lot easier to understand and intuitive; in the case you're working with that many different resources.cfg
syedhs wrote:
syedhs wrote: Can change shader parameter in the fly.. therefore we can tweak it until we are satisfied.
You can always press F5 (or F8 if the material is defined outside the mesh' directory) to see the changes. Not exactly real time, but it's something.
I was thinking this fits more a material editor (or integrated Tool), rather than a mesh viewer.
You are right. better not overdo it.. but an evolution is not unusual to hear nowadays ;)
I can't say a material pane wouldn't be nice. It's troublesome and I don't have the time to design the interface or code it. But if you're into it, then go ahead

Re: Ogre Meshy 1.4 (Mesh viewer, Windows Installer & Linux s

Posted: Thu Jan 05, 2012 11:11 am
by Shockeye
Hi,
I'm having a spot of bother getting this to work on (32 bit) Ubuntu 11.10. I managed to build it ok from the version 1.4, but when I attempt to run ogremeshy, I get the following:

Code: Select all

(ogremeshy:3718): Gdk-CRITICAL **: IA__gdk_drawable_get_size: assertion `GDK_IS_DRAWABLE (drawable)' failed
After that, all the Ogre loading messages display in the terminal as if everything is fine, but no window appears. You'd think at least the frame would appear, even if it couldn't render the window.
I noticed there was an earlier post with the same error. The suggestion was made that it could be something to do with multiple monitors, solution offered was disabling Xinerama. I don't think the guy ever replied as to whether that worked, or if something else did. :?:
I don't have multiple monitors & Xinerama enable. Valiant googling for an answer has left me bamboozled. Has anyone got any ideas?
Has anyone got this running on Ubuntu 11.10?
Thanks

[edit]
I'm a complete n00b when it comes to Linux, but I've finally manged to find where the crash happens using gdb.
(Debugging in under windows is so much easier :) )

Code: Select all


Breakpoint 4, MainFrame::MainFrame (this=0x813b648, parent=0xb740160c, 
    id=-1220536820, title=..., pos=..., size=..., style=-1220536820)
    at /home/gary/Downloads/OgreMeshy/OgreMeshy/src/Core/wxOgreMeshViewerMainFrame.cpp:19
19		m_menuFileLoad = new wxMenuItem( m_menuFile, wxID_MENUFILELOAD, wxString( wxT("Load...") ) + wxT('\t') + wxT("Ctrl+O"), wxT("Loads a new mesh"), wxITEM_NORMAL );
(gdb) step
[New Thread 0xb73ffb70 (LWP 2060)]

(ogremeshy:2057): Gdk-CRITICAL **: IA__gdk_drawable_get_size: assertion `GDK_IS_DRAWABLE (drawable)' failed

(ogremeshy:2057): Gdk-CRITICAL **: IA__gdk_drawable_get_depth: assertion `GDK_IS_DRAWABLE (drawable)' failed
Thats as far as I could step thru the code.
Why creating a menu item would crash it is beyond me. :?

Re: Ogre Meshy 1.4 (Mesh viewer, Windows Installer & Linux s

Posted: Sun Mar 04, 2012 10:57 am
by bstone
Thanks for this wonderful tool! It would be even more helpful if you could fix an issue with shared GPU program parameters. Currently if you have those in your materials and reload the resources.cfg file by pressing F8 it will generate an exception (because of redefining already existing shared params) and crash.

Re: Ogre Meshy 1.4 (Mesh viewer, Windows Installer & Linux s

Posted: Sun Mar 04, 2012 11:30 pm
by saejox
great tool!

i have two small feature requests :D

- "always on top" feature (great for multitasking, work side by side with notepad++)
- billboard icons for lights, would be awesome if they were movable with mouse

i use your viewer every hour of every day, thank you!

Re: Ogre Meshy 1.4 (Mesh viewer, Windows Installer & Linux s

Posted: Thu May 24, 2012 9:14 pm
by paul424
When I fire make I get :

Code: Select all

[ 11%] Building CXX object CMakeFiles/OgreMeshy.dir/src/main.cpp.o
/home/tom/Downloads/OgreMeshy/src/main.cpp: In member function ‘virtual bool wxWidgetsApp::OnInit()’:
/home/tom/Downloads/OgreMeshy/src/main.cpp:57:73: error: cannot allocate an object of abstract type ‘MeshyMainFrameImpl’
/home/tom/Downloads/OgreMeshy/include/Core/wxOgreMeshViewerMainFrameImpl.h:45:7: note:   because the following virtual functions are pure within ‘MeshyMainFrameImpl’:
/usr/include/OGRE/OgreLog.h:82:22: note: 	virtual void Ogre::LogListener::messageLogged(const String&, Ogre::LogMessageLevel, bool, const String&)
make[2]: *** [CMakeFiles/OgreMeshy.dir/src/main.cpp.o] Error 1
make[1]: *** [CMakeFiles/OgreMeshy.dir/all] Error 2
make: *** [all] Error 2

=========================================================


Looks like something wrong with OGRE packages versions.

Re: Ogre Meshy 1.4 (Mesh viewer, Windows Installer & Linux s

Posted: Thu May 24, 2012 9:34 pm
by dark_sylinc
IIRC that compilation error was fixed either in the last Source Code release, and if not; then it's in the Hg repository
Was caused by a change in Ogre 1.8 code

Re: Ogre Meshy 1.4 (Mesh viewer, Windows Installer & Linux s

Posted: Sat May 26, 2012 7:38 pm
by paul424
Good try , but after trying to build , I get the exactly same error.

Re: Ogre Meshy 1.4 (Mesh viewer, Windows Installer & Linux s

Posted: Sat May 26, 2012 11:12 pm
by dark_sylinc
OK. Will take a look. Ogre may have changed again.

PS. Are you sure you're building against 1.8? Because it won't compile against 1.7
PS 2: BTW just add any missing parameter (or removed unused ones) from the overloading of MeshyMainFrameImpl::messageLogged to get it compiling again. It's not hard at all ;)

Re: Ogre Meshy 1.4 (Mesh viewer, Windows Installer & Linux s

Posted: Sun May 27, 2012 2:23 pm
by duststorm
paul424 wrote:Good try , but after trying to build , I get the exactly same error.
A similar remark about that linker problem has been mentioned in this thread already. Maybe it can help you.

Re: Ogre Meshy 1.4 (Mesh viewer, Windows Installer & Linux s

Posted: Mon May 28, 2012 9:28 am
by paul424
EDIT Upps I m sorry I still use Ogre 1.7.4 which is the default for OpenSuse 12.1 :)

Re: Ogre Meshy 1.4 (Mesh viewer, Windows Installer & Linux s

Posted: Wed May 30, 2012 8:29 pm
by paul424
Finnaly I managed to compile the OgreMeshy. After choosing the renderer I get :

tom@linux-ex0a:~/OgreMeshy/bin/Release_Linux> ./OgreMeshy

(OgreMeshy:6522): Gdk-CRITICAL **: IA__gdk_drawable_get_size: assertion `GDK_IS_DRAWABLE (drawable)' failed

(OgreMeshy:6522): Gdk-CRITICAL **: IA__gdk_drawable_get_depth: assertion `GDK_IS_DRAWABLE (drawable)' failed
Creating resource group General
Creating resource group Internal
Creating resource group Autodetect

And the program quits with 0377 error code.
Normally executing with gdb helps nothing.

Why such popular package is not in OpenSuse repos ?

Re: Ogre Meshy 1.4 (Mesh viewer, Windows Installer & Linux s

Posted: Mon Jun 11, 2012 5:04 pm
by duststorm
While building it again today (on linux) I noticed a stupid mistake of mine that had quite some disastrous consequences.
I'm posting it here in case someone else makes the same mistake:

After building (make all) I issued an install command with superuser privilege, like so:

Code: Select all

sudo make install
I think this was the wrong thing to do. Now when I start OgreMeshy (from /opt/ogremeshy/OgreMeshy) the Ogre config window pops up, but if I select a render system and click OK it just quits. No error, no message, no trace on the terminal.

The reason was that the location where ogremeshy wanted to save the ogre.cfg file (/home/username/.ogremeshy) was owned by root, and not writeable by the user.
Simply issuing:

Code: Select all

sudo chown username ~/.ogremeshy
fixes it.


I have to admit, I find it a little spooky that Ogre doesn't warn about this and just silently fails. Debugging it I found nothing either (except for the clue to go look at the location where it saves the ogre.cfg file).

Re: Ogre Meshy 1.4 (Mesh viewer, Windows Installer & Linux s

Posted: Mon Jun 11, 2012 10:38 pm
by merlinblack

Code: Select all

sudo make install
or

Code: Select all

su -c "make install"
is a standard Linux way to install software you have compiled yourself. Nothing wrong there. :D

What I've seen a lot of other programs do in this case is install a "template" or "sane defaults" config file to somewhere like /usr/share/progname. Then when the user starts the program (as themselves, not root) there is no config file in the users home directory, so the template is copied. Some are even clever enough to use the standard version until the user changes something, and only then make a user specific config file.

Hmmmm.... if you tweak the makefile to install the config file in "/usr/share/meshy" .... this wrapper script should do the trick (just off the top of my head):

Code: Select all

#! /usr/bin/env bash
# Wrapper script to start meshy
if [ ! -f ~/.ogremeshy ] ; then
    cp /usr/share/meshy/ogremeshy ~/.ogremeshy
fi

/usr/bin/meshy
Or something like that. The makefile could even write it - and get things right if meshy is installed somewhere else (like /usr/local).

Re: Ogre Meshy 1.4 (Mesh viewer, Windows Installer & Linux s

Posted: Tue Nov 06, 2012 7:53 am
by shega
keep up the goodwork!
this meshviewer has becoming my favorite tool (in windows environment).
mm...now i have ubuntu 12.04 ( and i'm very2 noob)
is there any depedencies i have to install ?
i've already "make install" ogremeshy ,then when i click the binary at
/opt/ogremeshy/OgreMeshy nothing happend ( i checked the allow run as program tick box)