Navi

A place to show off your latest screenshots and for people to comment on them. Only start a new thread here if you have some nice images to show off!
Post Reply
User avatar
ajs15822
OGRE Expert User
OGRE Expert User
Posts: 570
Joined: Mon Jan 02, 2006 2:05 am
Location: Texas
x 2
Contact:

Navi

Post by ajs15822 »

I am pleased to announce the dawn of 'Navi', an exciting new library for Ogre3D developers.


For support and further discussion of NaviLibrary, please visit our forum.


Visit our Wiki: click here

Demo v1.3: get it here

Video v1.3: watch it here (XVID, 3.5mb)


Screenshots:
Image


Image


Image


Image


The Navi Library:
Interested? Cool, browse our wiki for more information or discuss it in our forum.

Enjoy. :D

Edited by Haffax: Fixed forum link
Last edited by ajs15822 on Wed Sep 12, 2007 8:48 pm, edited 8 times in total.
User avatar
KungFooMasta
OGRE Contributor
OGRE Contributor
Posts: 2087
Joined: Thu Mar 03, 2005 7:11 am
Location: WA, USA
x 16
Contact:

Post by KungFooMasta »

. . . . WOW!

Looks very nice! Although, it does get irritating when people mention "BetaGUI Derivatives". :P If you visited the Showcase thread in the past month or so You'd see QuickGUI floating around, its not so comparable to BetaGUI anymore (not good or bad, but it is distinct IMO). :)

Cool to see another GUI alternative! *steals alpha mask idea*. :lol:

[Edit] Hale nochi Guu is one of the best anime ever! [/Edit]

KungFooMasta
User avatar
betajaen
OGRE Moderator
OGRE Moderator
Posts: 3447
Joined: Mon Jul 18, 2005 4:15 pm
Location: Wales, UK
x 58
Contact:

Post by betajaen »

Indeed, I would like to see some QuickGUI and Navi derivatives in the future.
User avatar
ajs15822
OGRE Expert User
OGRE Expert User
Posts: 570
Joined: Mon Jan 02, 2006 2:05 am
Location: Texas
x 2
Contact:

Post by ajs15822 »

I've edited the page to be a little more accommodating towards your views ;)
User avatar
ajs15822
OGRE Expert User
OGRE Expert User
Posts: 570
Joined: Mon Jan 02, 2006 2:05 am
Location: Texas
x 2
Contact:

Post by ajs15822 »

KungFooMasta wrote:. . . . WOW!

Looks very nice! Although, it does get irritating when people mention "BetaGUI Derivatives". :P If you visited the Showcase thread in the past month or so You'd see QuickGUI floating around, its not so comparable to BetaGUI anymore (not good or bad, but it is distinct IMO). :)

Cool to see another GUI alternative! *steals alpha mask idea*. :lol:

[Edit] Hale nochi Guu is one of the best anime ever! [/Edit]

KungFooMasta
Lol, I don't mind *stealing* of ideas between open-source projects, the more the merrier! And yes, I admit your QuickGUI project is no longer just a derivative; nice work!

And yes, Guu is my hero.
CABAListic
OGRE Retired Team Member
OGRE Retired Team Member
Posts: 2903
Joined: Thu Jan 18, 2007 2:48 pm
x 58
Contact:

Post by CABAListic »

Hey, this is pretty neat. Just the other day I thought that somehow the usual GUI API designs don't quite fit games in general and that we'd need a different approach to make GUI design for games both easier and more flexible. But I guess I don't have to follow up on my thoughts too much now :D

Only thing bothering me is the mozlib dependency and it automatically catching input and hooking up to sound etc (if I understood your comments correctly?). From what I saw mozilla projects are usually monsters to compile, and the automatic hookings just cry for interaction problems with other components. But I'll likely still experiment with it some time :)
User avatar
ajs15822
OGRE Expert User
OGRE Expert User
Posts: 570
Joined: Mon Jan 02, 2006 2:05 am
Location: Texas
x 2
Contact:

Post by ajs15822 »

CABAListic wrote:Hey, this is pretty neat. Just the other day I thought that somehow the usual GUI API designs don't quite fit games in general and that we'd need a different approach to make GUI design for games both easier and more flexible. But I guess I don't have to follow up on my thoughts too much now :D

Only thing bothering me is the mozlib dependency and it automatically catching input and hooking up to sound etc (if I understood your comments correctly?). From what I saw mozilla projects are usually monsters to compile, and the automatic hookings just cry for interaction problems with other components. But I'll likely still experiment with it some time :)
Yup, compiling Mozilla from source is a monster (I had to do it twice in one night... *shudder*).

As long as a Navi window is not focused, the internal Mozilla library should not receive any key input. If that's still too much of a problem, I can modify the LLMozLib libs included with Navi to only use injected keys.
User avatar
radioman
Greenskin
Posts: 132
Joined: Sun Dec 31, 2006 3:59 pm
Location: lithuania

Post by radioman »

miraculous !!!
peace & serenity
grizzley90
Gnome
Posts: 318
Joined: Wed Jan 18, 2006 7:22 pm
Location: Montreal, Canada

Post by grizzley90 »

:shock: :shock: :shock: :shock:
Yanko
Kobold
Posts: 32
Joined: Thu Apr 26, 2007 7:13 pm

Post by Yanko »

man, this is just great :D

While researching to know how to do my univ project (which in the end would have to be entwined with the existing http library search), i considered using Gecko, especially to avoid having to work directly with sockets. You got my idea and pretty much did what i thought of doing in the long run :D

Unfortunately, my crappy computer at the university can´t even run the demo for some god unknown reason :oops:
so i´ll just look at this at home. But anyway, congrats, it´s looking great by the vids :D
User avatar
ajs15822
OGRE Expert User
OGRE Expert User
Posts: 570
Joined: Mon Jan 02, 2006 2:05 am
Location: Texas
x 2
Contact:

Post by ajs15822 »

Yanko wrote:man, this is just great :D

While researching to know how to do my univ project (which in the end would have to be entwined with the existing http library search), i considered using Gecko, especially to avoid having to work directly with sockets. You got my idea and pretty much did what i thought of doing in the long run :D

Unfortunately, my crappy computer at the university can´t even run the demo for some god unknown reason :oops:
so i´ll just look at this at home. But anyway, congrats, it´s looking great by the vids :D
wow, awesome! Glad to be of some help.
User avatar
Klaim
Old One
Posts: 2565
Joined: Sun Sep 11, 2005 1:04 am
Location: Paris, France
x 56
Contact:

Post by Klaim »

Glad to see that :D You talked about it on the IRC channel if i remember well.

First, just a little question about "Navi" name : are you a S.E.Lain fan? Isit inspired from that anime?


Ok now i've got to test it verry soon :D

As long as a Navi window is not focused, the internal Mozilla library should not receive any key input. If that's still too much of a problem, I can modify the LLMozLib libs included with Navi to only use injected keys.
That would be better i think. That would let lib user control the input behavior whitout having to activate/deactivte the GUI...


edit> Do you plan to support other platforms than Windows?
User avatar
ajs15822
OGRE Expert User
OGRE Expert User
Posts: 570
Joined: Mon Jan 02, 2006 2:05 am
Location: Texas
x 2
Contact:

Post by ajs15822 »

Klaim wrote:Glad to see that :D You talked about it on the IRC channel if i remember well.

First, just a little question about "Navi" name : are you a S.E.Lain fan? Isit inspired from that anime?


Ok now i've got to test it verry soon :D

As long as a Navi window is not focused, the internal Mozilla library should not receive any key input. If that's still too much of a problem, I can modify the LLMozLib libs included with Navi to only use injected keys.
That would be better i think. That would let lib user control the input behavior whitout having to activate/deactivte the GUI...
Hah, glad you remembered. And yes, the name 'Navi' is inspired by 'Navi' from Serial Experiments Lain.

As for manually injecting keycodes and overriding Mozilla's natural behavior, I haven't had very good luck with it and actually really prefer Mozilla to handle it instead.

I think a better compromise would be something like this:

Let's say we have some uber-cool-skills that are initiated by CTRL+1 and CTRL+2 key combinations. Normally, without any intervention, if a textbox inside of a focused Navi was focused, the user might see a '1' or '2' on this action.

So, we tell NaviManager to ignore any keys that are held down after CTRL

Code: Select all

void MyKeyHandler(KeyCode code)
{
    if(code == 'CTRL')
    {
         NaviManager::Get().toggleKeyListening(false);
         ctrlDown = true;
    }
    else
    {
         NaviManager::Get().toggleKeyListening(true);
         ctrlDown = false;
     }

     if(code == '1' && ctrlDown) 
          SuperCoolMove();
     
     if(code == '2' && ctrlDown)
          ReallyCoolMove();
}
That's really the only place where I think this kind of disabling of auto-key-listening is useful.

*shrugs* I'm just trying to come up with the best solution.
User avatar
ajs15822
OGRE Expert User
OGRE Expert User
Posts: 570
Joined: Mon Jan 02, 2006 2:05 am
Location: Texas
x 2
Contact:

Post by ajs15822 »

As for cross-platform viability, LLMozLib is not fully cross-platform, yet.

They are indeed working on support for other platforms at this time (hey cool, corporate interests work in our favor).

As for the Navi Library itself, it's almost completely non-Windows-specific besides having to pass HWND into LLMozLib (which will change in the future).

Heck, it's not even render-system dependent because Navi uses Ogre's Hardware Pixel Buffers to do all the texture-update-kung-fu.
User avatar
Klaim
Old One
Posts: 2565
Joined: Sun Sep 11, 2005 1:04 am
Location: Paris, France
x 56
Contact:

Post by Klaim »

Hah, glad you remembered. And yes, the name 'Navi' is inspired by 'Navi' from Serial Experiments Lain.
I cannot forget someone saying he have e ready to use solution to display fast html gui in ogre :shock:

And i'm a big fan of S.E.Lain ;)


I'm verry interested in displaying html on a texture for some features in my game (that are planned for some months in the future) and Navi would be verry useful to me with those features :
- Cross-platform (Windows, Linux and Mac) - ok you answered (edit);
- Let you display the texture on a mesh (quad or something) : i guess i can hack the current code to make it possible when i'll need that.

Another point : it don't seem obvious if gecko accesses automatically to internet or you have to "activate" something to make it possible.
What if i want to force it to not access internet, only local files or some provided strings?
User avatar
ajs15822
OGRE Expert User
OGRE Expert User
Posts: 570
Joined: Mon Jan 02, 2006 2:05 am
Location: Texas
x 2
Contact:

Post by ajs15822 »

Klaim wrote:
Hah, glad you remembered. And yes, the name 'Navi' is inspired by 'Navi' from Serial Experiments Lain.
I cannot forget someone saying he have e ready to use solution to display fast html gui in ogre :shock:

And i'm a big fan of S.E.Lain ;)


I'm verry interested in displaying html on a texture for some features in my game (that are planned for some months in the future) and Navi would be verry useful to me with those features :
- Cross-platform (Windows, Linux and Mac) - ok you answered (edit);
- Let you display the texture on a mesh (quad or something) : i guess i can hack the current code to make it possible when i'll need that.

Another point : it don't seem obvious if gecko accesses automatically to internet or you have to "activate" something to make it possible.
What if i want to force it to not access internet, only local files or some provided strings?
It really wouldn't be that hard to put a Navi on something other than an Overlay (See the uBrowser Plane Demo for an example) but it would complicate mouse-picking.

The Navi Library is very well-documented and most of the code is fairly understandable. If you do indeed modify it, however, please notify me of your changes so as to share them with the community. :)

As for using only local files, it's fairly easy by use of the 'local://' protocol when creating/navigating Navis. For example, let's say you have MyPage1.html and MyPage2.html in the 'NaviLocal' folder. Create the Navi using "local://MyPage1.html" as the homepage parameter.

To get to MyPage2.html, let's say this is the content of MyPage1.html:

Code: Select all

<html>
<body>
<a href="MyPage2.html">Go to My Page 2</a>
</body>
</html>
Mozilla allows relative links, even in local folders. 8)
User avatar
Klaim
Old One
Posts: 2565
Joined: Sun Sep 11, 2005 1:04 am
Location: Paris, France
x 56
Contact:

Post by Klaim »

It really wouldn't be that hard to put a Navi on something other than an Overlay (See the uBrowser Plane Demo for an example) but it would complicate mouse-picking.
Right, i know this problem. In my case it's not needed that the user can use the inputs while the display is not in front of the screen so i think it's not really a problem. It would be one if i needed to display the pages on something like Doom3 in-game interfaces.
I remember someone did provide the code to get the mouse coordinate from mesh data, not sure it was on Ogre forums ....

The Navi Library is very well-documented and most of the code is fairly understandable. If you do indeed modify it, however, please notify me of your changes so as to share them with the community.
I'll to that if nobody do it before me (as i have a lot of other features to implement before starting to work on that one). :)


About the local files, i think you misunderstood or i didn't explain well enough : what should be possible is to "lock" page access to local files, or a specific folder.
I mean, if you provide the html files for local and you don't want someone to add some external link in thoses files, can you tell mozilla to not try to get data from internet, with or without an external link?

For example in a game, maybe you would like to let the player access only to some local files relatives to the game and if the player modify the html files to redirect to external pages, it should not work.

I'm not a security specialist (i don't know much about security), but i feel like acessing any html page from a game could be dangerous?

Anyway, Thanks for Navi, it will be helpful :D
Chaster
OGRE Expert User
OGRE Expert User
Posts: 557
Joined: Wed May 05, 2004 3:19 pm
Location: Portland, OR, USA
Contact:

Post by Chaster »

Just had to add my Kudos here too.. Awesome work!

Chaster
User avatar
radioman
Greenskin
Posts: 132
Joined: Sun Dec 31, 2006 3:59 pm
Location: lithuania

Post by radioman »

..i try to use it, and a little problem in debug mode: http://www.divshare.com/image/full/726984-590

call stack: http://www.divshare.com/image/full/727006-7ba

there is link to mozila's source: http://mxr.mozilla.org/mozilla1.8/sourc ... o.cpp#3577

..if someone can figure what a hell is happening i'll be very happy ;}
peace & serenity
User avatar
tau
Silver Sponsor
Silver Sponsor
Posts: 413
Joined: Wed Feb 11, 2004 11:44 am
Location: Austin (that's kept wierd :))

Post by tau »

Good job! I'm gonna use it :)
Twitter: Tau Powered
User avatar
Zeal
Ogre Magi
Posts: 1260
Joined: Mon Aug 07, 2006 6:16 am
Location: Colorado Springs, CO USA

Post by Zeal »

Wow.

So I can create a GUI with a regular old HTML editor? How does the performance compare to a 'traditional' GUI? From what I understand, youre 'running' the GUI (in mozilla?) and just rendering the results to a texture? Isnt that a lot slower than using something like OpenGUI (which uses ogres materials/overlays directly)?

Heh im sure all the answers are in your tutorial/faq, im just too excited to read it (that video was really cool).

Either way, Amazing job.
User avatar
ajs15822
OGRE Expert User
OGRE Expert User
Posts: 570
Joined: Mon Jan 02, 2006 2:05 am
Location: Texas
x 2
Contact:

Post by ajs15822 »

radioman wrote:..i try to use it, and a little problem in debug mode: http://www.divshare.com/image/full/726984-590

call stack: http://www.divshare.com/image/full/727006-7ba

there is link to mozila's source: http://mxr.mozilla.org/mozilla1.8/sourc ... o.cpp#3577

..if someone can figure what a hell is happening i'll be very happy ;}
This is a bug in the Mozilla version used by LLMozLib, specifically: Bug 339504 - Local home page causes assertion: "preserved wrapper table not empty at shutdown".

Because NaviDemo uses local pages to display everything, when LLMozLib is shutdown, this bug is invoked. This bug is only apparent in the debug mode.
User avatar
ajs15822
OGRE Expert User
OGRE Expert User
Posts: 570
Joined: Mon Jan 02, 2006 2:05 am
Location: Texas
x 2
Contact:

Post by ajs15822 »

Klaim wrote:
It really wouldn't be that hard to put a Navi on something other than an Overlay (See the uBrowser Plane Demo for an example) but it would complicate mouse-picking.
Right, i know this problem. In my case it's not needed that the user can use the inputs while the display is not in front of the screen so i think it's not really a problem. It would be one if i needed to display the pages on something like Doom3 in-game interfaces.
I remember someone did provide the code to get the mouse coordinate from mesh data, not sure it was on Ogre forums ....

The Navi Library is very well-documented and most of the code is fairly understandable. If you do indeed modify it, however, please notify me of your changes so as to share them with the community.
I'll to that if nobody do it before me (as i have a lot of other features to implement before starting to work on that one). :)


About the local files, i think you misunderstood or i didn't explain well enough : what should be possible is to "lock" page access to local files, or a specific folder.
I mean, if you provide the html files for local and you don't want someone to add some external link in thoses files, can you tell mozilla to not try to get data from internet, with or without an external link?

For example in a game, maybe you would like to let the player access only to some local files relatives to the game and if the player modify the html files to redirect to external pages, it should not work.

I'm not a security specialist (i don't know much about security), but i feel like acessing any html page from a game could be dangerous?

Anyway, Thanks for Navi, it will be helpful :D
Ah, no-follow schemes, LLMozLib is totally capable of this, I was careless and didn't implement it into NaviManager just yet.

The next version of Navi (1.01) will be out in a little while and has this as well as a few updates (minor efficiency enhancements, const-correctness in the API, etc.)

*EDIT*: Actually LLMozLib's no-follow schemes are only for protocol prefix specifiers (e.g. http://, local://, etc.) which won't actually get links like "google.com".

I'll modify LLMozLib to allow no-follow schemes with wildcards or maybe even Regular Expressions if I feel up to it.
Last edited by ajs15822 on Fri May 25, 2007 3:09 am, edited 1 time in total.
User avatar
ajs15822
OGRE Expert User
OGRE Expert User
Posts: 570
Joined: Mon Jan 02, 2006 2:05 am
Location: Texas
x 2
Contact:

Post by ajs15822 »

Zeal wrote:Wow.

So I can create a GUI with a regular old HTML editor? How does the performance compare to a 'traditional' GUI? From what I understand, youre 'running' the GUI (in mozilla?) and just rendering the results to a texture? Isnt that a lot slower than using something like OpenGUI (which uses ogres materials/overlays directly)?

Heh im sure all the answers are in your tutorial/faq, im just too excited to read it (that video was really cool).

Either way, Amazing job.
Yes, you can write a GUI with almost any tool you would normally use to write a web page. To actually send and handle data to and from the application, you use a little Javascript to send/receive 'NaviData' (read the overview for more info).

Haha, slower? Navi does indeed use Ogre's overlays/textures directly and only 'updates' the texture when something has changed. So if your GUI doesn't change that much, it's like having a few static overlays on your screen!

If your GUI does change much (animated javascript/flash), you can limit the number of times per second Navi updates.

I just did some quick tests on my laptop @ 1024x768 using the NaviDemo:

Each Navi is a local html page rendered to a texture, masked with an alpha mask.

Average FPS of three Navis with world geometry on-screen: 60 FPS
Average FPS of no Navis with world geometry on-screen: 66 FPS

Average FPS of three Navis with no world geometry on-screen: 108 FPS
Average FPS of no Navis with no world geometry on-screen: 130 FPS

Not bad at all. :wink:
lodi
Greenskin
Posts: 103
Joined: Sat Jul 24, 2004 7:06 pm

Post by lodi »

This is amazing; I needed this so. I can't wait to get a chance to fire up my project and give navi a shot!

Thanks for the fantastic work!
Post Reply