org.lwjglb.engine.graph.Mesh.getMaterial()方法的使用及代码示例

x33g5p2x  于2022-01-25 转载在 其他  
字(7.1k)|赞(0)|评价(0)|浏览(93)

本文整理了Java中org.lwjglb.engine.graph.Mesh.getMaterial()方法的一些代码示例,展示了Mesh.getMaterial()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Mesh.getMaterial()方法的具体详情如下:
包路径:org.lwjglb.engine.graph.Mesh
类名称:Mesh
方法名:getMaterial

Mesh.getMaterial介绍

暂无

代码示例

代码示例来源:origin: lwjglgamedev/lwjglbook

public Hud(String statusText) throws Exception {
  this.statusTextItem = new TextItem(statusText, FONT_TEXTURE, FONT_COLS, FONT_ROWS);
  this.statusTextItem.getMesh().getMaterial().setAmbientColour(new Vector4f(1, 1, 1, 1));
  gameItems = new GameItem[]{statusTextItem};
}

代码示例来源:origin: lwjglgamedev/lwjglbook

public Hud(String statusText) throws Exception {
  FontTexture fontTexture = new FontTexture(FONT, CHARSET);
  this.statusTextItem = new TextItem(statusText, fontTexture);
  this.statusTextItem.getMesh().getMaterial().setAmbientColour(new Vector4f(0.5f, 0.5f, 0.5f, 10f));
  // Create list that holds the items that compose the HUD
  gameItems = new GameItem[]{statusTextItem};
}

代码示例来源:origin: lwjglgamedev/lwjglbook

public Hud(String statusText) throws Exception {
  FontTexture fontTexture = new FontTexture(FONT, CHARSET);
  this.statusTextItem = new TextItem(statusText, fontTexture);
  this.statusTextItem.getMesh().getMaterial().setAmbientColour(new Vector4f(0.5f, 0.5f, 0.5f, 10f));
  // Create list that holds the items that compose the HUD
  gameItems = new GameItem[]{statusTextItem};
}

代码示例来源:origin: lwjglgamedev/lwjglbook

public Particle(Mesh mesh, Vector3f speed, long ttl, long updateTextureMillis) {
  super(mesh);
  this.speed = new Vector3f(speed);
  this.ttl = ttl;
  this.updateTextureMillis = updateTextureMillis;
  this.currentAnimTimeMillis = 0;
  Texture texture = this.getMesh().getMaterial().getTexture();
  this.animFrames = texture.getNumCols() * texture.getNumRows();
}

代码示例来源:origin: lwjglgamedev/lwjglbook

public Particle(Mesh mesh, Vector3f speed, long ttl, long updateTextureMillis) {
  super(mesh);
  this.speed = new Vector3f(speed);
  this.ttl = ttl;
  this.updateTextureMillis = updateTextureMillis;
  this.currentAnimTimeMillis = 0;
  Texture texture = this.getMesh().getMaterial().getTexture();
  this.animFrames = texture.getNumCols() * texture.getNumRows();
}

代码示例来源:origin: lwjglgamedev/lwjglbook

public Hud(String statusText) throws Exception {
  FontTexture fontTexture = new FontTexture(FONT, CHARSET);
  this.statusTextItem = new TextItem(statusText, fontTexture);
  this.statusTextItem.getMesh().getMaterial().setAmbientColour(new Vector4f(0.5f, 0.5f, 0.5f, 10f));
  // Create list that holds the items that compose the HUD
  gameItems = new GameItem[]{statusTextItem};
}

代码示例来源:origin: lwjglgamedev/lwjglbook

public Particle(Mesh mesh, Vector3f speed, long ttl, long updateTextureMillis) {
  super(mesh);
  this.speed = new Vector3f(speed);
  this.ttl = ttl;
  this.updateTextureMillis = updateTextureMillis;
  this.currentAnimTimeMillis = 0;
  Texture texture = this.getMesh().getMaterial().getTexture();
  this.animFrames = texture.getNumCols() * texture.getNumRows();
}

代码示例来源:origin: lwjglgamedev/lwjglbook

public Particle(Mesh mesh, Vector3f speed, long ttl, long updateTextureMillis) {
  super(mesh);
  this.speed = new Vector3f(speed);
  this.ttl = ttl;
  this.updateTextureMillis = updateTextureMillis;
  this.currentAnimTimeMillis = 0;
  Texture texture = this.getMesh().getMaterial().getTexture();
  this.animFrames = texture.getNumCols() * texture.getNumRows();
}

代码示例来源:origin: lwjglgamedev/lwjglbook

public Hud(String statusText) throws Exception {
  FontTexture fontTexture = new FontTexture(FONT, CHARSET);
  this.statusTextItem = new TextItem(statusText, fontTexture);
  this.statusTextItem.getMesh().getMaterial().setAmbientColour(new Vector4f(0.5f, 0.5f, 0.5f, 10f));
  // Create list that holds the items that compose the HUD
  gameItems = new GameItem[]{statusTextItem};
}

代码示例来源:origin: lwjglgamedev/lwjglbook

public Particle(Mesh mesh, Vector3f speed, long ttl, long updateTextureMillis) {
  super(mesh);
  this.speed = new Vector3f(speed);
  this.ttl = ttl;
  this.updateTextureMillis = updateTextureMillis;
  this.currentAnimTimeMillis = 0;
  Texture texture = this.getMesh().getMaterial().getTexture();
  this.animFrames = texture.getNumCols() * texture.getNumRows();
}

代码示例来源:origin: lwjglgamedev/lwjglbook

public Particle(Mesh mesh, Vector3f speed, long ttl, long updateTextureMillis) {
  super(mesh);
  this.speed = new Vector3f(speed);
  this.ttl = ttl;
  this.updateTextureMillis = updateTextureMillis;
  this.currentAnimTimeMillis = 0;
  Texture texture = this.getMesh().getMaterial().getTexture();
  this.animFrames = texture.getNumCols() * texture.getNumRows();
}

代码示例来源:origin: lwjglgamedev/lwjglbook

public Hud(String statusText) throws Exception {
  FontTexture fontTexture = new FontTexture(FONT, CHARSET);
  this.statusTextItem = new TextItem(statusText, fontTexture);
  this.statusTextItem.getMesh().getMaterial().setAmbientColour(new Vector4f(0.5f, 0.5f, 0.5f, 10f));
  // Create list that holds the items that compose the HUD
  gameItems = new GameItem[]{statusTextItem};
}

代码示例来源:origin: lwjglgamedev/lwjglbook

public Particle(Mesh mesh, Vector3f speed, long ttl, long updateTextureMillis) {
  super(mesh);
  this.speed = new Vector3f(speed);
  this.ttl = ttl;
  this.updateTextureMillis = updateTextureMillis;
  this.currentAnimTimeMillis = 0;
  Texture texture = this.getMesh().getMaterial().getTexture();
  this.animFrames = texture.getNumCols() * texture.getNumRows();
}

代码示例来源:origin: lwjglgamedev/lwjglbook

public Hud(String statusText) throws Exception {
  FontTexture fontTexture = new FontTexture(FONT, CHARSET);
  this.statusTextItem = new TextItem(statusText, fontTexture);
  this.statusTextItem.getMesh().getMaterial().setAmbientColour(new Vector4f(0.5f, 0.5f, 0.5f, 10f));
  // Create list that holds the items that compose the HUD
  gameItems = new GameItem[]{statusTextItem};
}

代码示例来源:origin: lwjglgamedev/lwjglbook

public Particle(Mesh mesh, Vector3f speed, long ttl, long updateTextureMillis) {
  super(mesh);
  this.speed = new Vector3f(speed);
  this.ttl = ttl;
  this.updateTextureMillis = updateTextureMillis;
  this.currentAnimTimeMillis = 0;
  Texture texture = this.getMesh().getMaterial().getTexture();
  this.animFrames = texture.getNumCols() * texture.getNumRows();
}

代码示例来源:origin: lwjglgamedev/lwjglbook

public Hud(String statusText) throws Exception {
  FontTexture fontTexture = new FontTexture(FONT, CHARSET);
  this.statusTextItem = new TextItem(statusText, fontTexture);
  this.statusTextItem.getMesh().getMaterial().setAmbientColour(new Vector4f(0.5f, 0.5f, 0.5f, 10f));
  // Create list that holds the items that compose the HUD
  gameItems = new GameItem[]{statusTextItem};
}

代码示例来源:origin: lwjglgamedev/lwjglbook

public Particle(Mesh mesh, Vector3f speed, long ttl, long updateTextureMillis) {
  super(mesh);
  this.speed = new Vector3f(speed);
  this.ttl = ttl;
  this.updateTextureMillis = updateTextureMillis;
  this.currentAnimTimeMillis = 0;
  Texture texture = this.getMesh().getMaterial().getTexture();
  this.animFrames = texture.getNumCols() * texture.getNumRows();
}

代码示例来源:origin: lwjglgamedev/lwjglbook

public Particle(Mesh mesh, Vector3f speed, long ttl, long updateTextureMillis) {
  super(mesh);
  this.speed = new Vector3f(speed);
  this.ttl = ttl;
  this.updateTextureMillis = updateTextureMillis;
  this.currentAnimTimeMillis = 0;
  Texture texture = this.getMesh().getMaterial().getTexture();
  this.animFrames = texture.getNumCols() * texture.getNumRows();
}

代码示例来源:origin: lwjglgamedev/lwjglbook

public void setText(String text) {
    this.text = text;
    Texture texture = this.getMesh().getMaterial().getTexture();
    this.getMesh().deleteBuffers();
    this.setMesh(buildMesh(texture, numCols, numRows));
  }
}

代码示例来源:origin: lwjglgamedev/lwjglbook

public void setText(String text) {
    this.text = text;
    Texture texture = this.getMesh().getMaterial().getTexture();
    this.getMesh().deleteBuffers();
    this.setMesh(buildMesh(texture, numCols, numRows));
  }
}

相关文章