Examples of OutputCapsule


Examples of com.jme3.export.OutputCapsule

    public Class<? extends Cell> getClassTag() {
        return this.getClass();
    }
   
  public void write(JmeExporter e) throws IOException {
    OutputCapsule capsule = e.getCapsule(this);
    capsule.write(id, "id", -1);
    capsule.write(m_CellPlane, "cellplane", null);
    capsule.write(m_Vertex, "vertex", null);
    capsule.write(m_CenterPoint, "center", null);
    capsule.write(m_Side, "sides", null);
//links are handled one level above in mesh
//    capsule.write(m_Link, "links", null);
    capsule.write(m_WallMidpoint, "midpoints", null);
    capsule.write(m_WallDistance, "distances", null)
  }
View Full Code Here

Examples of com.jme3.export.OutputCapsule

//    }
   
  // write out he cell array as it is
  // loop over all cells and for each cell write out the 3 link ids into the cell array for neighbors
  public void write(JmeExporter e) throws IOException {
    OutputCapsule capsule = e.getCapsule(this);
//    capsule.writeSavableArrayList(m_CellArray, "cellarray", null);
    capsule.write(mCellArray, "mCellArray", null);
    HashMap<Cell, Integer> tmp = new HashMap<Cell, Integer>();
   
    int[] links = new int[mCellArray.length*3];
   
    for(int i =0; i<mCellArray.length; i++)
      tmp.put(mCellArray[i], i);
   
    Cell c = null;
    for(int i =0,j=0; i<mCellArray.length; i++){
      c = mCellArray[i];
      links[j++]= (c.m_Link[0] != null?tmp.get(c.m_Link[0]):-1);
      links[j++]= (c.m_Link[1] != null?tmp.get(c.m_Link[1]):-1);
      links[j++]= (c.m_Link[2] != null?tmp.get(c.m_Link[2]):-1);
    }
    capsule.write(links, "links", null);
    tmp.clear();
  }
View Full Code Here

Examples of com.jme3.export.OutputCapsule

       defaultSet = input.readString("defaultSet", "");
  }

  @Override
  public void write(JmeExporter ex) throws IOException {
    OutputCapsule output = ex.getCapsule(this);
        output.write(primhand, "primhand", "");
        output.write(offhand, "offhand", "");
        output.write(offhandOptional, "offhandOptional", 0);
        output.write(animSet, "animSet", "");
        output.write(defaultSet, "defaultSet", "");
  }
View Full Code Here

Examples of com.jme3.export.OutputCapsule

    location = capsule.readString("location", "");
  }
  @Override
  public void write(JmeExporter ex) throws IOException {
    super.write(ex);
    OutputCapsule capsule = ex.getCapsule(this);
    capsule.write(location, "location", "");
  }
View Full Code Here

Examples of com.jme3.export.OutputCapsule

//        initialize();
    }

  @Override
    public void write(JmeExporter ex) throws IOException {
        OutputCapsule output = ex.getCapsule(this);
        output.write(name, "name", "");
//        output.write(parts.keySet().toArray(new String[0]), "part_keys", null);
//        output.write(parts.values().toArray(new String[0]), "part_values", null);
    }
View Full Code Here

Examples of com.jme3.export.OutputCapsule

    }

    @Override
    public void write(JmeExporter ex) throws IOException {
        super.write(ex);
        OutputCapsule oc = ex.getCapsule(this);
        oc.write(distance, "distance", IArea.TERRAIN_SIZE);
    }
View Full Code Here

Examples of com.jme3.export.OutputCapsule

        control.spatial.addControl(control);
        return control;
  }
  @Override
  public void write(JmeExporter ex) throws IOException {
    OutputCapsule oc = ex.getCapsule(this);
    oc.write(enabled, "enabled", true);
    oc.write(spatial, "spatial", null);
  }
View Full Code Here

Examples of com.jme3.export.OutputCapsule

     *
     * @param ex the exporter
     * @throws IOException
     */
    public void write(JmeExporter ex) throws IOException {
        OutputCapsule oc = (OutputCapsule) ex.getCapsule(this);
        oc.write(name, "name", "");
        String[] str = new String[shadersLanguage.size()];
        oc.write(shadersLanguage.toArray(str), "shadersLanguage", null);
        oc.write(shadersPath.toArray(str), "shadersPath", null);
        oc.write(type, "type", null);
        oc.writeSavableArrayList((ArrayList) inputs, "inputs", new ArrayList<ShaderNodeVariable>());
        oc.writeSavableArrayList((ArrayList) outputs, "inputs", new ArrayList<ShaderNodeVariable>());
    }
View Full Code Here

Examples of com.jme3.export.OutputCapsule

    }

    @Override
    public void write(JmeExporter ex) throws IOException {
        super.write(ex);
        OutputCapsule oc = ex.getCapsule(this);
        oc.write(enabled, "enabled", true);
        oc.write(applyLocal, "applyLocalPhysics", false);
        oc.write(spatial, "spatial", null);
    }
View Full Code Here

Examples of com.jme3.export.OutputCapsule

    }

    @Override
    public void write(JmeExporter ex) throws IOException{
        super.write(ex);
        OutputCapsule oc = ex.getCapsule(this);
        oc.write(fragName, "fragment_name", null);
        oc.write(vertLanguage, "language", null);
        oc.write(fragLanguage, "frag_language", null);
    }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.