本文整理匯總了Java中net.minecraft.client.renderer.VertexBuffer.pos方法的典型用法代碼示例。如果您正苦於以下問題:Java VertexBuffer.pos方法的具體用法?Java VertexBuffer.pos怎麽用?Java VertexBuffer.pos使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類net.minecraft.client.renderer.VertexBuffer
的用法示例。
在下文中一共展示了VertexBuffer.pos方法的2個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。
示例1: drawTexturedModalRectZ
import net.minecraft.client.renderer.VertexBuffer; //導入方法依賴的package包/類
public void drawTexturedModalRectZ(final float i, final float y, final int k, final int i1, final int j1, final int k1, final float zLevel) {
float f = 0.015625F;
float f1 = 0.03125F;
Tessellator tesselator = Tessellator.getInstance();
VertexBuffer vertexbuffer = tesselator.getBuffer();
vertexbuffer.begin(7, DefaultVertexFormats.POSITION_TEX);
/*
tesselator.getWorldRenderer().addVertexWithUV(i + 0, y + k1, zLevel, (k + 0) * f, (i1 + k1) * f1);
tesselator.getWorldRenderer().addVertexWithUV(i + j1, y + k1, zLevel, (k + j1) * f, (i1 + k1) * f1);
tesselator.getWorldRenderer().addVertexWithUV(i + j1, y + 0, zLevel, (k + j1) * f, (i1 + 0) * f1);
tesselator.getWorldRenderer().addVertexWithUV(i + 0, y + 0, zLevel, (k + 0) * f, (i1 + 0) * f1);
*/
vertexbuffer.pos(i + 0, y + k1, zLevel);
vertexbuffer.pos(i + j1, y + k1, zLevel);
vertexbuffer.pos(i + j1, y + 0, zLevel);
vertexbuffer.pos(i + 0, y + 0, zLevel);
tesselator.draw();
}
示例2: vector
import net.minecraft.client.renderer.VertexBuffer; //導入方法依賴的package包/類
private void vector(VertexBuffer vb, double x, double y, double z, double u, double v, double oU, double oV) {
vb.pos(x, y, z);
vb.tex(u + oU, v + oV);
vb.color(255, 255, 255, 255);
vb.endVertex();
}