NiftyGUI not working properly on OpenGL 1

Recently upgraded from stable #9 to #11 - after fixing the asset loading everything worked fine again, until I tried running my project on my netbook which forces jME to use OpenGL 1 since 3 isn’t supported and 2 lags like hell (integrated graphics chip…).



Buttons don’t have a background anymore, but show their text just fine. The built-in console doesn’t display anything at all. Not sure about other elements since we don’t use anything else yet.

Both elements still work as expected though. It also worked fine on stable #9.



OpenGL 1: http://i.imgur.com/Cmz8T.png

OpenGL 2/3/4: http://i.imgur.com/7I50Q.png



Test case to reproduce: http://pastebin.com/Rsgt3tFF (just the default TestNiftyGui example forced to OpenGL 1)

It should be displaying the orange background behind the text, but it isn’t.

2 Likes

I have the same issue with NiftyGui:



http://i.imgur.com/6xlKm.png





Nifty Code:

[xml]

<?xml version=“1.0” encoding=“UTF-8”?>

<nifty xmlns=“http://nifty-gui.sourceforge.net/nifty-1.3.xsd

xmlns:xsi=“http://www.w3.org/2001/XMLSchema-instance

xsi:schemaLocation=“http://nifty-gui.sourceforge.net/nifty-1.3.xsd http://nifty-gui.sourceforge.net/nifty-1.3.xsd”>

<useStyles filename=“nifty-default-styles.xml” />

<useControls filename=“nifty-default-controls.xml” />



<screen id=“start” controller=“com.editor.EditorGui”>

<layer childLayout=“center”>

<panel width=“150px” height=“70%” align=“left” valign=“center” childLayout=“vertical” backgroundColor="#2222" padding=“10” >

<panel height=“30px” backgroundColor="#2222" padding=“10”>

<!-- add your content here -->

</panel>



<panel height=“21px” align=“center” childLayout=“vertical”>

<control id=“button1” name=“button” label=“but1” visibleToMouse=“true”>

<interact onClick=“printGo()”/>

</control>

</panel>



<panel height=“21px” align=“center” childLayout=“vertical”>

<control id=“button2” name=“button” label=“but2” visibleToMouse=“true”>

<interact onClick=“printGo()”/>

</control>

</panel>



<panel height=“21px” align=“center” childLayout=“vertical”>

<control id=“button3” name=“button” label=“but3” visibleToMouse=“true”>

<interact onClick=“printGo()”/>

</control>

</panel>



<panel height=“21px” align=“center” childLayout=“vertical”>

<control id=“button4” name=“button” label=“but4” visibleToMouse=“true”>

<interact onClick=“printGo()”/>

</control>

</panel>



</panel>



</layer>

</screen>

</nifty>

[/xml]





Was this patch applied to JME? http://hub.jmonkeyengine.org/groups/contribution-depot-jme3/forum/topic/a-tiny-fix-for-the-niftygui-with-lwjgl_opengl1/

I’d really like this to be fixed too

Me too. It worked in the jME3 version that was current while beta game contest.