* Fixed issue where a model loaded from J3O would crash on render (thanks ghoust)
* Uniform.toString() now handles the case where name = null git-svn-id: https://jmonkeyengine.googlecode.com/svn/trunk@9497 75d07b2b-3a1a-0410-a2c5-0572b91ccdca
This commit is contained in:
parent
e8762bcf9d
commit
c373f70d01
@ -310,6 +310,7 @@ When arrays can be inserted in J3M files
|
||||
InputCapsule ic = im.getCapsule(this);
|
||||
type = ic.readEnum("varType", VarType.class, null);
|
||||
name = ic.readString("name", null);
|
||||
prefixedName = "m_" + name;
|
||||
ffBinding = ic.readEnum("ff_binding", FixedFuncBinding.class, null);
|
||||
switch (getVarType()) {
|
||||
case Boolean:
|
||||
|
@ -161,17 +161,15 @@ public class Uniform extends ShaderVariable {
|
||||
@Override
|
||||
public String toString(){
|
||||
StringBuilder sb = new StringBuilder();
|
||||
if (name != null){
|
||||
sb.append("Uniform[name=");
|
||||
sb.append(name);
|
||||
if (varType != null){
|
||||
sb.append(", type=");
|
||||
sb.append(varType);
|
||||
sb.append(", value=");
|
||||
sb.append(value);
|
||||
}else{
|
||||
sb.append(", value=<not set>");
|
||||
}
|
||||
sb.append("Uniform[name=");
|
||||
sb.append(name);
|
||||
if (varType != null){
|
||||
sb.append(", type=");
|
||||
sb.append(varType);
|
||||
sb.append(", value=");
|
||||
sb.append(value);
|
||||
}else{
|
||||
sb.append(", value=<not set>");
|
||||
}
|
||||
sb.append("]");
|
||||
return sb.toString();
|
||||
|
Loading…
x
Reference in New Issue
Block a user