Editor: jMonkeyBuilder

Seems like a lot of changes for just keeping track of what the best version is.

OK, I will separate this pull request.

I meant even just that fixā€¦ splitting out into a whole separate list class, resorting every time, etcā€¦ seemed like a lot to do just to keep track of the ā€œbest oneā€. Just trying to figure out if itā€™s justified or not.

Yeah I agree itā€™s bit too much, Iā€™m gonna look into it.
For now to work around your issue just use

renderManager.setPreferredLightMode(LightMode.SinglePassAndImageBased);

This will select the glsl150 for the PBR shader,no need to reverse every j3md in the engine.

1 Like

and it breaks other shaders :smiley:

sighā€¦ thatā€™s what happens when you fork master repo and use experimental stuffs on it.
This whole LWJGL3 thing has not been thought through and you guys are just poking aroundā€¦

Iā€™m making changes in the engine so that the shaders have proper glsl version. Then you can revert all your commits and just rebase on master

1 Like

but it helps us with testing lwjgl3, I think the lwjgl3 is future of jme3. :wink:

1 Like

Sometimes it helps to step back to see the big picture and try to actually make things right.
I know you are all trying to help and that we are not completely responsive in the core team due to our real life schedule, but these kind of things really need to go through the core teamā€¦ because itā€™sā€¦core changes.

4 Likes

I am going to make several small PRs with changes like thisā€¦

Alright these 2 changes should fix your issues

you have to revert your changes on the engine j3md though

Great! Thanks :slight_smile:

ver. 0.9.1
-Add some settings to setting dialog.
-Added shift+ctrl value scrolling.
-Added environments folder to settings dialog.
-Started implementing a scene editor.
-Updated jME libraries.
-Implemented layers in a scene editor.
-Implemented scene states editing and provided API to support custom states.
-Integrated lighting and sky states from SimFX library.
-Implemented user data editing.
-Added some performance optimizations with jME render inside JavaFX.

1 Like

Sadly ver. 0.9.1 crashes while startingā€¦
Ver 0.9.0 worked fine for me. I have a Intel HD 4000, Windows 10 and no special driver installed.
I get his log when I try to launch it. Do you need any additional information or should I create an issue on bitbucket?
It looks like an error I had while trying PBR on ubuntu. But Iā€™m not sure.

~/AppData/Local/jME3-SpaceShift-Editor
$ ./jM*
Jan 20, 2017 10:49:56 PM java.util.prefs.WindowsPreferences <init>
WARNUNG: Could not open/create prefs root node Software\JavaSoft\Prefs at root 0x80000002. Windows RegCreateKeyEx(...) returned error code 5.
INFO 22:49:57:024 Editor: OS: Windows 10
INFO 22:49:57:111 ExecutorManager: initialized.
INFO 22:49:57:158 ClassPathScanner: scanning libs\jME\jme3-core-3.2.0.jar
INFO 22:49:57:349 ClassPathScanner: scanning libs\jME\jme3-effects-3.2.0.jar
INFO 22:49:57:368 ClassPathScanner: scanning libs\extensions\toneg0d\tonegod.emitter-2.0.jar
INFO 22:49:57:397 ClassPathScanner: scanning C:\Users\Jan\AppData\Local\jME3-SpaceShift-Editor\app\libs\jME\jme3-core-3.2.0.jar
INFO 22:49:57:458 ClassPathScanner: scanning C:\Users\Jan\AppData\Local\jME3-SpaceShift-Editor\app\libs\jME\jme3-effects-3.2.0.jar
INFO 22:49:57:472 ClassPathScanner: scanning C:\Users\Jan\AppData\Local\jME3-SpaceShift-Editor\app\libs\extensions\toneg0d\tonegod.emitter-2.0.jar
INFO 22:49:57:479 ClassPathScanner: scanned for 1710 classes and 464 resources.
Jan 20, 2017 10:49:57 PM com.jme3.renderer.opengl.GLRenderer updateShaderSourceData
WARNUNG: Bad compile of:
1       #version 150 core
2       #define FRAGMENT_SHADER 1
3       #extension GL_ARB_texture_multisample : enable
4       // -- begin import Common/ShaderLib/MultiSample.glsllib --
5
6       uniform int m_NumSamples;
7       uniform int m_NumSamplesDepth;
8
9       #ifdef RESOLVE_MS
10          #define COLORTEXTURE sampler2DMS
11      #else
12          #define COLORTEXTURE sampler2D
13      #endif
14
15      #ifdef RESOLVE_DEPTH_MS
16          #define DEPTHTEXTURE sampler2DMS
17      #else
18          #define DEPTHTEXTURE sampler2D
19      #endif
20
21      // NOTE: Only define multisample functions if multisample is available
22      #if defined(GL_ARB_texture_multisample)
23      vec4 textureFetch(in sampler2DMS tex,in vec2 texC, in int numSamples){
24            ivec2 iTexC = ivec2(texC * vec2(textureSize(tex)));
25            vec4 color = vec4(0.0);
26            for (int i = 0; i < numSamples; i++){
27               color += texelFetch(tex, iTexC, i);
28            }
29            return color / float(numSamples);
30      }
31
32      vec4 fetchTextureSample(in sampler2DMS tex,in vec2 texC,in int sampleId){
33          ivec2 iTexC = ivec2(texC * vec2(textureSize(tex)));
34          return texelFetch(tex, iTexC, sampleId);
35      }
36
37      vec4 getColor(in sampler2DMS tex, in vec2 texC){
38            return textureFetch(tex, texC, m_NumSamples);
39      }
40
41      vec4 getColorSingle(in sampler2DMS tex, in vec2 texC){
42          ivec2 iTexC = ivec2(texC * vec2(textureSize(tex)));
43          return texelFetch(tex, iTexC, 0);
44      }
45
46      vec4 getDepth(in sampler2DMS tex,in vec2 texC){
47            return textureFetch(tex,texC,m_NumSamplesDepth);
48      }
49
50      #endif
51
52      vec4 fetchTextureSample(in sampler2D tex,in vec2 texC,in int sampleId){
53          return texture2D(tex,texC);
54      }
55
56      vec4 getColor(in sampler2D tex, in vec2 texC){
57          return texture2D(tex,texC);
58      }
59
60      vec4 getColorSingle(in sampler2D tex, in vec2 texC){
61          return texture2D(tex, texC);
62      }
63
64      vec4 getDepth(in sampler2D tex,in vec2 texC){
65          return texture2D(tex,texC);
66      }
67
68      // -- end import Common/ShaderLib/MultiSample.glsllib --
69
70      uniform COLORTEXTURE m_Texture;
71      uniform vec4 m_Color;
72      in vec2 texCoord;
73      out vec4 fragColor;
74
75      void main() {
76            vec4 texVal = getColor(m_Texture, texCoord);
77            fragColor = texVal * m_Color;
78      }

WARNING 22:49:57:634 Editor: com.jme3.renderer.RendererException: compile error in: ShaderSource[name=Common/MatDefs/Post/Overlay15.frag, defines, type=Fragment, language=GLSL150]
ERROR: 0:53: 'texture2D' : function is removed in Forward Compatibile context
ERROR: 0:53: 'texture2D' : no matching overloaded function found (using implicit conversion)
ERROR: 0:57: 'texture2D' : function is removed in Forward Compatibile context
ERROR: 0:57: 'texture2D' : no matching overloaded function found (using implicit conversion)
ERROR: 0:61: 'texture2D' : function is removed in Forward Compatibile context
ERROR: 0:61: 'texture2D' : no matching overloaded function found (using implicit conversion)
ERROR: 0:65: 'texture2D' : function is removed in Forward Compatibile context
ERROR: 0:65: 'texture2D' : no matching overloaded function found (using implicit conversion)
ERROR: 0:76: 'm_Texture' : undeclared identifier
ERROR: 0:76: 'texCoord' : undeclared identifier
ERROR: 0:76: 'getColor' : no matching overloaded function found (using implicit conversion)
ERROR: 0:76: '=' :  cannot convert from 'const float' to '4-component vector of float'
ERROR: 0:77: 'fragColor' : undeclared identifier
ERROR: 0:77: 'm_Color' : undeclared identifier
ERROR: 0:77: 'assign' :  cannot convert from '4-component vector of float' to 'float'


        at com.jme3.renderer.opengl.GLRenderer.updateShaderSourceData(GLRenderer.java:1244)
        at com.jme3.renderer.opengl.GLRenderer.updateShaderData(GLRenderer.java:1271)
        at com.jme3.renderer.opengl.GLRenderer.setShader(GLRenderer.java:1335)
        at com.jme3.material.logic.DefaultTechniqueDefLogic.render(DefaultTechniqueDefLogic.java:94)
        at com.jme3.material.Technique.render(Technique.java:166)
        at com.jme3.material.Material.render(Material.java:970)
        at com.jme3.renderer.RenderManager.renderGeometry(RenderManager.java:616)
        at com.jme3.post.FilterPostProcessor.renderProcessing(FilterPostProcessor.java:218)
        at com.jme3.post.FilterPostProcessor.renderFilterChain(FilterPostProcessor.java:301)
        at com.jme3.post.FilterPostProcessor.postFrame(FilterPostProcessor.java:320)
        at com.jme3.renderer.RenderManager.renderViewPort(RenderManager.java:1111)
        at com.jme3.renderer.RenderManager.render(RenderManager.java:1154)
        at com.jme3.app.SimpleApplication.update(SimpleApplication.java:253)
        at com.jme3x.jfx.injfx.JmeToJFXApplication.update(JmeToJFXApplication.java:21)
        at com.ss.editor.Editor.update(Unknown Source)
        at com.jme3.system.lwjgl.LwjglWindow.runLoop(LwjglWindow.java:524)
        at com.jme3.system.lwjgl.LwjglWindow.run(LwjglWindow.java:607)
        at com.jme3.system.lwjgl.LwjglWindow.create(LwjglWindow.java:445)
        at com.jme3x.jfx.injfx.JmeOffscreenSurfaceContext.create(JmeOffscreenSurfaceContext.java:202)
        at com.jme3.app.LegacyApplication.start(LegacyApplication.java:463)
        at com.jme3.app.LegacyApplication.start(LegacyApplication.java:424)
        at com.jme3.app.SimpleApplication.start(SimpleApplication.java:125)
        at com.ss.editor.Editor.start(Unknown Source)
        at java.lang.Thread.run(Thread.java:745)

log4j:WARN No appenders could be found for logger (org.apache.http.impl.conn.PoolingHttpClientConnectionManager).
log4j:WARN Please initialize the log4j system properly.
Exception in thread "JavaFX Application Thread" java.lang.IllegalStateException: Shutdown in progress
        at java.lang.ApplicationShutdownHooks.add(ApplicationShutdownHooks.java:66)
        at java.lang.Runtime.addShutdownHook(Runtime.java:211)
        at com.sun.javafx.font.PrismFontFactory.lambda$addFileCloserHook$247(PrismFontFactory.java:1428)
        at java.security.AccessController.doPrivileged(Native Method)
        at com.sun.javafx.font.PrismFontFactory.addFileCloserHook(PrismFontFactory.java:1417)
        at com.sun.javafx.font.PrismFontFactory.loadEmbeddedFont(PrismFontFactory.java:1546)
        at com.sun.javafx.font.PrismFontLoader.loadFont(PrismFontLoader.java:99)
        at javafx.scene.text.Font.loadFont(Font.java:400)
        at com.sun.javafx.css.StyleManager.loadStylesheetUnPrivileged(StyleManager.java:1109)
        at com.sun.javafx.css.StyleManager.loadStylesheet(StyleManager.java:917)
        at com.sun.javafx.css.StyleManager.processStylesheets(StyleManager.java:1538)
        at com.sun.javafx.css.StyleManager.gatherSceneStylesheets(StyleManager.java:1607)
        at com.sun.javafx.css.StyleManager.findMatchingStyles(StyleManager.java:1645)
        at javafx.scene.CssStyleHelper.createStyleHelper(CssStyleHelper.java:111)
        at javafx.scene.Node.reapplyCss(Node.java:8983)
        at javafx.scene.Node.impl_reapplyCSS(Node.java:8946)
        at javafx.scene.Node.invalidatedScenes(Node.java:854)
        at javafx.scene.Node.setScenes(Node.java:919)
        at javafx.scene.Parent$1.onChanged(Parent.java:269)
        at com.sun.javafx.collections.TrackableObservableList.lambda$new$19(TrackableObservableList.java:45)
        at com.sun.javafx.collections.ListListenerHelper$Generic.fireValueChangedEvent(ListListenerHelper.java:329)
        at com.sun.javafx.collections.ListListenerHelper.fireValueChangedEvent(ListListenerHelper.java:73)
        at javafx.collections.ObservableListBase.fireChange(ObservableListBase.java:233)
        at javafx.collections.ListChangeBuilder.commit(ListChangeBuilder.java:482)
        at javafx.collections.ListChangeBuilder.endChange(ListChangeBuilder.java:541)AL lib: (EE) alc_cleanup: 1 device not closed

Thanks for your great work by the way

Ha looks like this one is an issue in the engine.
gonna check

1 Like

@javasabr I fixed it. could you throw another release ? :stuck_out_tongue:

1 Like

@nehon I will make a hotfix release :smiley:

@janvonpichowski I have updated the build on the yandex.disk

@javasabr have you considering making an Ubuntu ppa? I find frequent manual updating kinda annoying. Otherwise great work!

I have updated the builds of editors on yandex.disk.

I have no experiences with it, but I think I will try it late.