ryerrabelli / jmonkeyengine

Automatically exported from code.google.com/p/jmonkeyengine
0 stars 0 forks source link

Material editor generates incorrect J3M files #377

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
What steps will reproduce the problem?
1. Create a J3M file
2. Upon trying to parse the file, an exception will be thrown (not provided).

What is the expected output? What do you see instead?
The issue is caused due to the "PolyOffset" statement in the J3M being 
incorrect:
"PolyOffset 0.0" - this is not a proper PolyOffset statement. A proper 
PolyOffset statement consists of two floats, one for factor and another for 
units. See javadoc:
http://jmonkeyengine.org/javadoc/com/jme3/material/RenderState.html#setPolyOffse
t(float, float)

Original issue reported on code.google.com by ShadowIs...@gmail.com on 1 Aug 2011 at 4:03

GoogleCodeExporter commented 8 years ago
You using an old version somehow? I fixed this afaik.

Original comment by normen667 on 1 Aug 2011 at 4:51

GoogleCodeExporter commented 8 years ago
Actually there was an issue when reading back the j3m file. The reader was 
assuming one value after the name of the variable.Since poly offset has 2, one 
was missing. 
So the field was initialized with incorrect value, resulting in an incorrect 
file when saving back.

Original comment by remy.bou...@gmail.com on 1 Aug 2011 at 10:41