Skip to main content

History: Miyagi

Preview of version: 13

thumb|overview of controls
Miyagi stands for: Miyagi Is Yet Another Graphical user Interface

It can only be used by MOGRE (.NET), not by Ogre itself (C++) code.

Forum icon question2.gif For bug reports or feature requests please use this bug tracker.


Download:
Miyagi 1.2.0 (code, binary, sample application)

The documentation is in the Help directory.
Plus there is a sample with source code.



Controls

  • Button
  • CheckBox
  • ComboBox
  • DialogBox
  • DropDownList
  • Expander
  • FlowLayoutPanel
  • Label
  • ListBox
  • Panel
  • PictureBox
  • ProgressBar (horizontal and vertical)
  • RadioButton
  • RenderBox
  • Slider (horizontal and vertical)
  • TabControl
  • TableLayoutPanel
  • TextBox


Additional features

  • Import from / export to {LEX()}XML{LEX} file
  • 3D Gui
  • Scripting via Boo, C#, JScript, Lua, Nemerle, IronPython and VB.Net





Code snippets


Miyagi and MOIS


Miyagi currently relies on MOIS for mouse and keyboard input.

You have to create a Mois.Mouse and Mois.Keyboard (that's done by the 'CreateInput' method in the sample).
And then either supply them as a parameter in 'GuiManager.Singleton.Initialize'
e.g.:

Copy to clipboard
GuiManager.Singleton.Initialize(1024, 768, MySceneManager, MyCamera, MyMouse, MyKeyboard, true);



or set GuiManager.Singleton.Mouse / GuiManager.Singleton.Keyboard directly.

And you have to capture the devices in your program's main loop (for instance in the 'FrameStarted' event handler).

Copy to clipboard
MyKeyboard.Capture(); MyMouse.Capture();




MOIS note 2

After creating Mois.Mouse set this:

Copy to clipboard
MOIS.MouseState_NativePtr state = mouse.MouseState; state.width = (int)renderWindow.Width; state.height = (int)renderWindow.Height;





Mouse visibility and debugging


Problem:
While debugging in Visual Studio (after an exception) the mouse pointer is not visible.

Solution:
Set MOIS to non-exclusive mode when application was started in Debug mode.

Copy to clipboard
MOIS.ParamList pl = new MOIS.ParamList(); IntPtr windowHnd; this.window.GetCustomAttribute("WINDOW", out windowHnd); pl.Insert("WINDOW", windowHnd.ToString()); #if DEBUG pl.Insert("w32_mouse", "DISCL_NONEXCLUSIVE"); pl.Insert("w32_mouse", "DISCL_FOREGROUND"); #endif this.inputManager = MOIS.InputManager.CreateInputSystem(pl);




Note of user Beauty:
Add more snippets, starting from this forum post.
http://www.ogre3d.org/addonforums/viewtopic.php?f=8&t=9025&start=30



See also


Miyagi related:

  • SetMousePosition - Miyagi code snippet to set mouse position on given coordinates (until embedded on main code)


Common:

History

Information Version
Mon 29 of Oct, 2012 10:30 GMT-0000 smiley80 cleanup 32
Sat 02 of Jun, 2012 13:37 GMT-0000 smiley80 31
Tue 17 of Apr, 2012 07:19 GMT-0000 Aralox 30
Fri 13 of Apr, 2012 00:30 GMT-0000 Beauty added further link for game Dunno (Gui code) 29
Fri 13 of Apr, 2012 00:14 GMT-0000 Beauty added link to example (game Dunno) 28
Wed 11 of Apr, 2012 19:57 GMT-0000 Beauty added link to example project 27
Fri 30 of Mar, 2012 14:27 GMT-0000 Beauty added "forum topic deleted" note 26
Thu 29 of Mar, 2012 13:01 GMT-0000 Aralox 25
Thu 29 of Mar, 2012 12:43 GMT-0000 Aralox Added links about skin creation 24
Thu 29 of Mar, 2012 12:43 GMT-0000 Aralox Added links about skin creation 23
Thu 29 of Mar, 2012 12:43 GMT-0000 Aralox Added links about skin creation 22
Mon 14 of Nov, 2011 09:44 GMT-0000 smiley80 21
Sun 31 of Jul, 2011 22:51 GMT-0000 jacmoe 20
Sat 19 of Feb, 2011 12:20 GMT-0000 smiley80 added link to example code 19
Fri 18 of Feb, 2011 22:23 GMT-0000 Beauty added note about where to find example code 18
Sat 12 of Feb, 2011 00:28 GMT-0000 smiley80 no, that's the MediaWiki FAQ 17
Sat 12 of Feb, 2011 00:11 GMT-0000 Beauty removed "common" subtitle, because it's not needed anymore 16
Fri 11 of Feb, 2011 23:47 GMT-0000 Beauty added tiny link (I'm happy that I didn't yet searched the whole forum thread for useful code snippets) 15
Fri 11 of Feb, 2011 14:33 GMT-0000 smiley80 removed code snippets; updated links 14
Fri 11 of Feb, 2011 01:19 GMT-0000 Beauty added section "code snippets" + increazed headline size for better overview 13
Fri 11 of Feb, 2011 00:17 GMT-0000 Beauty RESTORE - the last change killed some lines of code (although it's not visible in the revision comparison) - maybe a tikiwiki bug? 12
Wed 09 of Feb, 2011 08:16 GMT-0000 smiley80 11
Sat 18 of Dec, 2010 19:22 GMT-0000 Beauty improved link list 10
Sat 18 of Dec, 2010 19:13 GMT-0000 Beauty added links 9
Mon 26 of Jul, 2010 08:47 GMT-0000 Beauty added note 8
  • «
  • 1 (current)
  • 2