当前位置: 首页>>代码示例>>Java>>正文


Java GL11.glRotatef方法代码示例

本文整理汇总了Java中org.lwjgl.opengl.GL11.glRotatef方法的典型用法代码示例。如果您正苦于以下问题:Java GL11.glRotatef方法的具体用法?Java GL11.glRotatef怎么用?Java GL11.glRotatef使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在org.lwjgl.opengl.GL11的用法示例。


在下文中一共展示了GL11.glRotatef方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: renderGL

import org.lwjgl.opengl.GL11; //导入方法依赖的package包/类
/**
 * Render the GL scene, this isn't efficient and if you know 
 * OpenGL I'm assuming you can see why. If not, you probably
 * don't want to use this feature anyway
 */
public void renderGL() {		
	FloatBuffer pos = BufferUtils.createFloatBuffer(4);
	pos.put(new float[] { 5.0f, 5.0f, 10.0f, 0.0f}).flip();
	FloatBuffer red = BufferUtils.createFloatBuffer(4);
	red.put(new float[] { 0.8f, 0.1f, 0.0f, 1.0f}).flip();

	GL11.glLight(GL11.GL_LIGHT0, GL11.GL_POSITION, pos);
	GL11.glEnable(GL11.GL_LIGHT0);

	GL11.glEnable(GL11.GL_CULL_FACE);
	GL11.glEnable(GL11.GL_DEPTH_TEST);
	GL11.glEnable(GL11.GL_LIGHTING);
	
	GL11.glMatrixMode(GL11.GL_PROJECTION);
	GL11.glLoadIdentity();
	float h = (float) 600 / (float) 800;
	GL11.glFrustum(-1.0f, 1.0f, -h, h, 5.0f, 60.0f);
	GL11.glMatrixMode(GL11.GL_MODELVIEW);
	GL11.glLoadIdentity();	
	GL11.glTranslatef(0.0f, 0.0f, -40.0f);	
	GL11.glRotatef(rot,0,1,1);		
	
	GL11.glMaterial(GL11.GL_FRONT, GL11.GL_AMBIENT_AND_DIFFUSE, red);
	gear(0.5f, 2.0f, 2.0f, 10, 0.7f);
}
 
开发者ID:j-dong,项目名称:trashjam2017,代码行数:31,代码来源:SlickCallableTest.java

示例2: renderWithRotation

import org.lwjgl.opengl.GL11; //导入方法依赖的package包/类
@Override
public void renderWithRotation(float scale)
{
	if (!this.isHidden)
	{
		if (this.showModel)
		{
			if (!this.compiled)
			{
				this.compileDisplayList(scale);
			}

			GL11.glPushMatrix();
			GL11.glTranslatef(this.rotationPointX * scale, this.rotationPointY * scale, this.rotationPointZ * scale);

			if (this.rotateAngleY != 0.0F)
			{
				GL11.glRotatef(this.rotateAngleY * 57.29578F, 0.0F, 1.0F, 0.0F);
			}

			if (this.rotateAngleX != 0.0F)
			{
				GL11.glRotatef(this.rotateAngleX * 57.29578F, 1.0F, 0.0F, 0.0F);
			}

			if (this.rotateAngleZ != 0.0F)
			{
				GL11.glRotatef(this.rotateAngleZ * 57.29578F, 0.0F, 0.0F, 1.0F);
			}

			GL11.glCallList(this.displayList);
			GL11.glPopMatrix();
		}
	}
}
 
开发者ID:crazysnailboy,项目名称:Halloween,代码行数:36,代码来源:ModelRendererPyramid.java

示例3: render

import org.lwjgl.opengl.GL11; //导入方法依赖的package包/类
public void render(double size, float partialTicks) {
    double renderRotationAngle = oldRotationAngle + (rotationAngle - oldRotationAngle) * partialTicks;
    BufferBuilder wr = Tessellator.getInstance().getBuffer();

    GL11.glPushMatrix();
    GL11.glEnable(GL12.GL_RESCALE_NORMAL);

    // GL11.glLineWidth((float)size * 20F);
    GL11.glEnable(GL11.GL_LINE_SMOOTH);

    GL11.glRotatef((float) renderRotationAngle, 0, 0, 1);
    for (int j = 0; j < 2; j++) {
        wr.begin(GL11.GL_TRIANGLE_STRIP, DefaultVertexFormats.POSITION);
        for (int i = 0; i < PneumaticCraftUtils.circlePoints / 4; i++) {
            wr.pos(PneumaticCraftUtils.cos[i] * size, PneumaticCraftUtils.sin[i] * size, 0).endVertex();
            wr.pos(PneumaticCraftUtils.cos[i] * (size + 0.1D), PneumaticCraftUtils.sin[i] * (size + 0.1D), 0).endVertex();
        }
        Tessellator.getInstance().draw();

        if (renderAsTagged) {
            GL11.glColor4d(1, 0, 0, 1);
            wr.begin(GL11.GL_LINE_LOOP, DefaultVertexFormats.POSITION);
            for (int i = 0; i < PneumaticCraftUtils.circlePoints / 4; i++) {
                wr.pos(PneumaticCraftUtils.cos[i] * size, PneumaticCraftUtils.sin[i] * size, 0).endVertex();
            }
            for (int i = PneumaticCraftUtils.circlePoints / 4 - 1; i >= 0; i--) {
                wr.pos(PneumaticCraftUtils.cos[i] * (size + 0.1D), PneumaticCraftUtils.sin[i] * (size + 0.1D), 0).endVertex();
            }
            Tessellator.getInstance().draw();
            GL11.glColor4d(1, 1, 0, 0.5);
        }

        GL11.glRotatef(180, 0, 0, 1);
    }

    GL11.glDisable(GL11.GL_LINE_SMOOTH);
    GL11.glDisable(GL12.GL_RESCALE_NORMAL);
    GL11.glPopMatrix();
}
 
开发者ID:TeamPneumatic,项目名称:pnc-repressurized,代码行数:40,代码来源:RenderTargetCircle.java

示例4: func_22017_a

import org.lwjgl.opengl.GL11; //导入方法依赖的package包/类
protected void func_22017_a(EntityPlayer entityplayer, float f, float f1, float f2)
{
    if(entityplayer.isEntityAlive() && entityplayer.isPlayerSleeping())
    {
        GL11.glRotatef(entityplayer.getBedOrientationInDegrees(), 0.0F, 1.0F, 0.0F);
        GL11.glRotatef(getDeathMaxRotation(entityplayer), 0.0F, 0.0F, 1.0F);
        GL11.glRotatef(270F, 0.0F, 1.0F, 0.0F);
    } else
    {
        super.rotateCorpse(entityplayer, f, f1, f2);
    }
}
 
开发者ID:jd-lang,项目名称:betaexpansion,代码行数:13,代码来源:RenderPlayer.java

示例5: render

import org.lwjgl.opengl.GL11; //导入方法依赖的package包/类
@Override
public void render(TileEntityAphorismTile te, double x, double y, double z, float partialTicks, int destroyStage, float alpha) {
    GL11.glPushMatrix();
    GL11.glTranslatef((float) x + 0.5F, (float) y + 1.5F, (float) z + 0.5F);
    GL11.glScalef(1.0F, -1F, -1F);
    PneumaticCraftUtils.rotateMatrixByMetadata(te.getBlockMetadata());
    GL11.glTranslatef(0, 1, 0.5F - BBConstants.APHORISM_TILE_THICKNESS - 0.01F);
    String[] textLines = te.getTextLines();
    int lineWidth = getMaxLineWidth(textLines);  // TODO we don't need to calculate this every single tick
    int lineHeight = 10 * textLines.length;
    float textScale = Math.min(14 / 16F / lineWidth, 14 / 16F / lineHeight);
    GL11.glScalef(textScale, textScale, textScale);
    GL11.glRotatef(te.textRotation * 90, 0, 0, 1);
    int editedLine = -1;

    if (FMLClientHandler.instance().getClient().currentScreen instanceof GuiAphorismTile) {
        GuiAphorismTile gui = (GuiAphorismTile) FMLClientHandler.instance().getClient().currentScreen;
        if (gui.tile == te && (gui.updateCounter & 0x0f) < 8) {
            editedLine = gui.cursorY;
        }
    }

    FontRenderer f = Minecraft.getMinecraft().getRenderManager().getFontRenderer();
    for (int i = 0; i < textLines.length; i++) {
        String textLine = textLines[i];
        if (editedLine == i) textLine = ">" + textLine + "<";
        f.drawString(textLine, -f.getStringWidth(textLine) / 2, -(textLines.length * 10) / 2 + i * 10 + 1, 0xFF000000);
    }

    GL11.glPopMatrix();
}
 
开发者ID:TeamPneumatic,项目名称:pnc-repressurized,代码行数:32,代码来源:RenderAphorismTile.java

示例6: postRender

import org.lwjgl.opengl.GL11; //导入方法依赖的package包/类
public void postRender(float f)
{
    if(field_1402_i)
    {
        return;
    }
    if(!showModel)
    {
        return;
    }
    if(!compiled)
    {
        compileDisplayList(f);
    }
    if(rotateAngleX != 0.0F || rotateAngleY != 0.0F || rotateAngleZ != 0.0F)
    {
        GL11.glTranslatef(rotationPointX * f, rotationPointY * f, rotationPointZ * f);
        if(rotateAngleZ != 0.0F)
        {
            GL11.glRotatef(rotateAngleZ * 57.29578F, 0.0F, 0.0F, 1.0F);
        }
        if(rotateAngleY != 0.0F)
        {
            GL11.glRotatef(rotateAngleY * 57.29578F, 0.0F, 1.0F, 0.0F);
        }
        if(rotateAngleX != 0.0F)
        {
            GL11.glRotatef(rotateAngleX * 57.29578F, 1.0F, 0.0F, 0.0F);
        }
    } else
    if(rotationPointX != 0.0F || rotationPointY != 0.0F || rotationPointZ != 0.0F)
    {
        GL11.glTranslatef(rotationPointX * f, rotationPointY * f, rotationPointZ * f);
    }
}
 
开发者ID:jd-lang,项目名称:betaexpansion,代码行数:36,代码来源:ModelRenderer.java

示例7: preCelestialRotate

import org.lwjgl.opengl.GL11; //导入方法依赖的package包/类
public static void preCelestialRotate()
{
    setUpPosition();
    GL11.glRotatef(sunPathRotation * 1.0F, 0.0F, 0.0F, 1.0F);
    checkGLError("preCelestialRotate");
}
 
开发者ID:SkidJava,项目名称:BaseClient,代码行数:7,代码来源:Shaders.java

示例8: renderGust

import org.lwjgl.opengl.GL11; //导入方法依赖的package包/类
private void renderGust() {
    byte b0 = 0;
    //float f2 = 0.0F;
    //float f3 = 0.5F;
    //float f4 = (0 + b0 * 10) / 16.0F;
    // float f5 = (5 + b0 * 10) / 16.0F;
    float f6 = 0.0F;
    float f7 = 0.15625F;
    float f8 = (5 + b0 * 10) / 16.0F;
    float f9 = (10 + b0 * 10) / 16.0F;
    float f10 = 0.05625F;
    GL11.glEnable(GL12.GL_RESCALE_NORMAL);
    GL11.glEnable(GL11.GL_BLEND);
    GL11.glBlendFunc(GL11.GL_SRC_ALPHA, GL11.GL_ONE_MINUS_SRC_ALPHA);

    GL11.glRotatef(45.0F, 1.0F, 0.0F, 0.0F);
    GL11.glScalef(f10, f10, f10);
    GL11.glTranslatef(-4.0F, 0.0F, 0.0F);
    GL11.glNormal3f(f10, 0.0F, 0.0F);
    BufferBuilder wr = Tessellator.getInstance().getBuffer();
    wr.begin(GL11.GL_QUADS, DefaultVertexFormats.POSITION_TEX);

    wr.pos(-7.0D, -2.0D, -2.0D).tex(f6, f8).endVertex();
    wr.pos(-7.0D, -2.0D, 2.0D).tex(f7, f8).endVertex();
    wr.pos(-7.0D, 2.0D, 2.0D).tex(f7, f9).endVertex();
    wr.pos(-7.0D, 2.0D, -2.0D).tex(f6, f9).endVertex();

    double start = 0d;
    double end = 1 / 16d;
    wr.pos(-7.0D, -2.0D, -2.0D).tex(start, start).endVertex();
    wr.pos(-7.0D, -2.0D, 2.0D).tex(start, end).endVertex();
    wr.pos(-7.0D, 2.0D, 2.0D).tex(end, end).endVertex();
    wr.pos(-7.0D, 2.0D, -2.0D).tex(end, start).endVertex();
    Tessellator.getInstance().draw();
    GL11.glNormal3f(-f10, 0.0F, 0.0F);

    wr.begin(GL11.GL_QUADS, DefaultVertexFormats.POSITION_TEX);
    wr.pos(-7.0D, 2.0D, -2.0D).tex(f6, f8).endVertex();
    wr.pos(-7.0D, 2.0D, 2.0D).tex(f7, f8).endVertex();
    wr.pos(-7.0D, -2.0D, 2.0D).tex(f7, f9).endVertex();
    wr.pos(-7.0D, -2.0D, -2.0D).tex(f6, f9).endVertex();
    Tessellator.getInstance().draw();

}
 
开发者ID:TeamPneumatic,项目名称:pnc-repressurized,代码行数:45,代码来源:RenderEntityVortex.java

示例9: renderEntity

import org.lwjgl.opengl.GL11; //导入方法依赖的package包/类
private void renderEntity(int p_147046_0_, int p_147046_1_, float scale, float p_147046_3_, float p_147046_4_, float z, float rotate, EntityLivingBase p_147046_5_) {
	
	GL11.glEnable(2903);
	GL11.glPushMatrix();
	GL11.glTranslatef((float) p_147046_0_, (float) p_147046_1_, z);//50.0F
	GL11.glScalef((-scale), scale, scale);
	GL11.glRotatef(180.0F, 0.0F, 0.0F, 1.0F);
	
	float var6 = p_147046_5_.renderYawOffset;
	float var7 = p_147046_5_.rotationYaw;
	float var8 = p_147046_5_.rotationPitch;
	float var9 = p_147046_5_.prevRotationYawHead;
	float var10 = p_147046_5_.rotationYawHead;
	
	RenderHelper.enableStandardItemLighting();

	GL11.glRotatef(-((float) Math.atan((double) (p_147046_4_ / 40.0F))) * 20.0F, 1.0F, 0.0F, 0.0F);
	
	p_147046_5_.posX = p_147046_5_.posY = p_147046_5_.posZ = 0;
	p_147046_5_.renderYawOffset = (float) Math.atan((double) (p_147046_3_ / 40.0F)) * rotate;
	p_147046_5_.rotationYaw = (float) Math.atan((double) (p_147046_3_ / 40.0F)) * 40.0F;
	p_147046_5_.rotationPitch = -((float) Math.atan((double) (p_147046_4_ / 40.0F))) * 20.0F;
	p_147046_5_.rotationYawHead = (float) Math.atan((double) (p_147046_3_ / 40.0F)) * rotate;
	p_147046_5_.prevRotationYawHead = 360f ;
	
	RenderManager.instance.playerViewY = 180.0F;
	
	RenderManager.instance.renderEntityWithPosYaw(p_147046_5_, 0.0D, 0.0D, 0.0D, 0.0F, 1.0F);
	
	p_147046_5_.renderYawOffset = var6;
	p_147046_5_.rotationYaw = var7;
	p_147046_5_.rotationPitch = var8;
	p_147046_5_.prevRotationYawHead = var9;
	p_147046_5_.rotationYawHead = var10;
	
	GL11.glPopMatrix();
	
	RenderHelper.disableStandardItemLighting();
	
	GL11.glDisable(2903);

	OpenGlHelper.setActiveTexture(OpenGlHelper.lightmapTexUnit);
	
	GL11.glDisable(3553);
	
	OpenGlHelper.setActiveTexture(OpenGlHelper.defaultTexUnit);
}
 
开发者ID:Pishka,项目名称:MineDonate,代码行数:48,代码来源:GuiItemEntryOfEntityMerch.java

示例10: glRotatef

import org.lwjgl.opengl.GL11; //导入方法依赖的package包/类
/**
 * @see org.newdawn.slick.opengl.renderer.SGL#glRotatef(float, float, float, float)
 */
public void glRotatef(float angle, float x, float y, float z) {
	GL11.glRotatef(angle, x, y, z);
}
 
开发者ID:imaTowan,项目名称:Towan,代码行数:7,代码来源:ImmediateModeOGLRenderer.java

示例11: doRender

import org.lwjgl.opengl.GL11; //导入方法依赖的package包/类
@Override
public void doRender(EntityRocket entity, double x, double y, double z, float yaw, float partialTick) {
	GL11.glPushMatrix();
	GL11.glTranslatef((float) x, (float) y, (float) z);
	GL11.glColor4f(0.7F, 0.7F, 0.7F, 1F);
	GL11.glRotatef(entity.prevRotationYaw + (entity.rotationYaw - entity.prevRotationYaw) * partialTick - 90.0F,
			0.0F, 1.0F, 0.0F);
	GL11.glRotatef(entity.prevRotationPitch + (entity.rotationPitch - entity.prevRotationPitch) * partialTick, 0.0F,
			0.0F, 1.0F);

	bindEntityTexture(entity);

	// GL11.glTranslatef((float)entity.posX, (float)entity.posY,
	// entity.posZ);
	if (((EntityProjectileBase) entity).getCritical() == 2) {
		GlStateManager.disableTexture2D();
		GlStateManager.disableLighting();
		ClientProxy.setColor(TF2Util.getTeamColor(((EntityProjectileBase) entity).shootingEntity), 1f, 0f, 0f, 1f);
		model.render(entity, 0F, 0F, 0.0F, 0.0F, 0.0F, 0.0625F);
		GL11.glColor4f(1.0F, 1.0F, 1.0F, 1F);
		GlStateManager.enableTexture2D();
		GlStateManager.enableLighting();
	} else
		model.render(entity, 0F, 0F, 0.0F, 0.0F, 0.0F, 0.0625F);

	/*
	 * GL11.glScalef(1.5f, 1.5f, 1.5f); GL11.glEnable(GL11.GL_BLEND);
	 * //GL11.glDisable(GL11.GL_ALPHA_TEST); OpenGlHelper.glBlendFunc(770,
	 * 771, 1, 0);
	 * 
	 * char c0 = 61680; int j = c0 % 65536; int k = c0 / 65536;
	 * OpenGlHelper.setLightmapTextureCoords(OpenGlHelper.lightmapTexUnit,
	 * (float)j / 1.0F, (float)k / 1.0F);
	 * 
	 * model.render(entity, 0F, 0F, 0.0F, 0.0F, 0.0F, 0.0625F);
	 * GL11.glDisable(GL11.GL_BLEND); // GL11.glEnable(GL11.GL_ALPHA_TEST);
	 */
	GL11.glColor4f(1F, 1F, 1F, 1F);
	GL11.glPopMatrix();
	/*
	 * IIcon iicon = TF2EventBusListener.pelletIcon;
	 * 
	 * if (iicon != null) { GL11.glPushMatrix();
	 * GL11.glTranslatef((float)x,(float) y,(float) z);
	 * GL11.glEnable(GL12.GL_RESCALE_NORMAL); GL11.glScalef(0.5F, 0.5F,
	 * 0.5F); this.bindTexture(TextureMap.locationItemsTexture); Tessellator
	 * tessellator = Tessellator.instance;
	 * 
	 * float f = iicon.getMinU(); float f1 = iicon.getMaxU(); float f2 =
	 * iicon.getMinV(); float f3 = iicon.getMaxV(); float f4 = 1.0F; float
	 * f5 = 0.5F; float f6 = 0.25F; GL11.glRotatef(180.0F -
	 * this.renderManager.playerViewY, 0.0F, 1.0F, 0.0F);
	 * GL11.glRotatef(-this.renderManager.playerViewX, 1.0F, 0.0F, 0.0F);
	 * tessellator.startDrawingQuads(); tessellator.setNormal(0.0F, 1.0F,
	 * 0.0F); tessellator.addVertexWithUV((double)(0.0F - f5), (double)(0.0F
	 * - f6), 0.0D, (double)f, (double)f3);
	 * tessellator.addVertexWithUV((double)(f4 - f5), (double)(0.0F - f6),
	 * 0.0D, (double)f1, (double)f3);
	 * tessellator.addVertexWithUV((double)(f4 - f5), (double)(f4 - f6),
	 * 0.0D, (double)f1, (double)f2);
	 * tessellator.addVertexWithUV((double)(0.0F - f5), (double)(f4 - f6),
	 * 0.0D, (double)f, (double)f2); tessellator.draw();
	 * GL11.glDisable(GL12.GL_RESCALE_NORMAL); GL11.glPopMatrix();
	 * 
	 * }
	 */

}
 
开发者ID:rafradek,项目名称:Mods,代码行数:69,代码来源:RenderRocket.java

示例12: renderEntityOnFire

import org.lwjgl.opengl.GL11; //导入方法依赖的package包/类
private void renderEntityOnFire(Entity entity, double d, double d1, double d2, 
        float f)
{
    GL11.glDisable(2896 /*GL_LIGHTING*/);
    int i = Block.fire.blockIndexInTexture;
    int j = (i & 0xf) << 4;
    int k = i & 0xf0;
    float f1 = (float)j / 256F;
    float f3 = ((float)j + 15.99F) / 256F;
    float f5 = (float)k / 256F;
    float f7 = ((float)k + 15.99F) / 256F;
    GL11.glPushMatrix();
    GL11.glTranslatef((float)d, (float)d1, (float)d2);
    float f9 = entity.width * 1.4F;
    GL11.glScalef(f9, f9, f9);
    loadTexture("/terrain.png");
    Tessellator tessellator = Tessellator.instance;
    float f10 = 0.5F;
    float f11 = 0.0F;
    float f12 = entity.height / f9;
    float f13 = (float)(entity.posY - entity.boundingBox.minY);
    GL11.glRotatef(-renderManager.playerViewY, 0.0F, 1.0F, 0.0F);
    GL11.glTranslatef(0.0F, 0.0F, -0.3F + (float)(int)f12 * 0.02F);
    GL11.glColor4f(1.0F, 1.0F, 1.0F, 1.0F);
    float f14 = 0.0F;
    int l = 0;
    tessellator.startDrawingQuads();
    while(f12 > 0.0F) 
    {
        float f2;
        float f4;
        float f6;
        float f8;
        if(l % 2 == 0)
        {
            f2 = (float)j / 256F;
            f4 = ((float)j + 15.99F) / 256F;
            f6 = (float)k / 256F;
            f8 = ((float)k + 15.99F) / 256F;
        } else
        {
            f2 = (float)j / 256F;
            f4 = ((float)j + 15.99F) / 256F;
            f6 = (float)(k + 16) / 256F;
            f8 = ((float)(k + 16) + 15.99F) / 256F;
        }
        if((l / 2) % 2 == 0)
        {
            float f15 = f4;
            f4 = f2;
            f2 = f15;
        }
        tessellator.addVertexWithUV(f10 - f11, 0.0F - f13, f14, f4, f8);
        tessellator.addVertexWithUV(-f10 - f11, 0.0F - f13, f14, f2, f8);
        tessellator.addVertexWithUV(-f10 - f11, 1.4F - f13, f14, f2, f6);
        tessellator.addVertexWithUV(f10 - f11, 1.4F - f13, f14, f4, f6);
        f12 -= 0.45F;
        f13 -= 0.45F;
        f10 *= 0.9F;
        f14 += 0.03F;
        l++;
    }
    tessellator.draw();
    GL11.glPopMatrix();
    GL11.glEnable(2896 /*GL_LIGHTING*/);
}
 
开发者ID:jd-lang,项目名称:betaexpansion,代码行数:67,代码来源:Render.java

示例13: glRotatef

import org.lwjgl.opengl.GL11; //导入方法依赖的package包/类
public static void glRotatef(float angle, float x, float y, float z) {
	GL11.glRotatef(angle, x, y, z);
}
 
开发者ID:Moudoux,项目名称:EMC,代码行数:4,代码来源:IGL11.java

示例14: render

import org.lwjgl.opengl.GL11; //导入方法依赖的package包/类
public void render(EntityProjectileSharpStone entity, double x, double y, double z, float par8, float par9)
{
	bindEntityTexture(entity);
	GL11.glPushMatrix();
	GL11.glTranslatef((float)x, (float)y, (float)z);
	GL11.glRotatef(entity.prevRotationYaw + (entity.rotationYaw - entity.prevRotationYaw) * par9 - 90.0F, 0.0F, 1.0F, 0.0F);
	GL11.glRotatef(entity.prevRotationPitch + (entity.rotationPitch - entity.prevRotationPitch) * par9, 0.0F, 0.0F, 1.0F);
	Tessellator tessellator = Tessellator.instance;
	float fx1 = 0.0F;
	float fx2 = 8 / 32.0F;
	float fy1 = 0.0F;
	float fy2 = 8 / 32.0F;

	float f10 = 0.05625F;

	GL11.glEnable(GL12.GL_RESCALE_NORMAL);

	GL11.glRotatef(45.0F, 1.0F, 0.0F, 0.0F);
	GL11.glScalef(f10, f10, f10);
	GL11.glTranslatef(-4.0F, 0.0F, 0.0F);

	for (int i = 0; i < 2; ++i)
	{
		GL11.glRotatef(180.0F, 1.0F, 0.0F, 0.0F);
		GL11.glNormal3f(0.0F, 0.0F, f10);
		tessellator.startDrawingQuads();
		tessellator.addVertexWithUV(-2.0D, -2.0D, 0.0D, fx1, fy1);
		tessellator.addVertexWithUV(2.0D, -2.0D, 0.0D, fx2, fy1);
		tessellator.addVertexWithUV(2.0D, 2.0D, 0.0D, fx2, fy2);
		tessellator.addVertexWithUV(-2.0D, 2.0D, 0.0D, fx1, fy2);
		tessellator.draw();
	}

	for (int i = 0; i < 2; ++i)
	{
		GL11.glRotatef(180.0F, 1.0F, 0.0F, 0.0F);
		GL11.glNormal3f(0.0F, 0.0F, f10);
		tessellator.startDrawingQuads();
		tessellator.addVertexWithUV(0.0D, -2.0D, -2.0D, fx1, fy1);
		tessellator.addVertexWithUV(0.0D, -2.0D, 2.0D, fx2, fy1);
		tessellator.addVertexWithUV(0.0D, 2.0D, 2.0D, fx2, fy2);
		tessellator.addVertexWithUV(0.0D, 2.0D, -2.0D, fx1, fy2);
		tessellator.draw();
	}
	
	
	GL11.glDisable(GL12.GL_RESCALE_NORMAL);
	GL11.glPopMatrix();
}
 
开发者ID:Wahazar,项目名称:TFCPrimitiveTech,代码行数:50,代码来源:RenderSharpStone.java

示例15: preCelestialRotate

import org.lwjgl.opengl.GL11; //导入方法依赖的package包/类
public static void preCelestialRotate()
{
    GL11.glRotatef(sunPathRotation * 1.0F, 0.0F, 0.0F, 1.0F);
    checkGLError("preCelestialRotate");
}
 
开发者ID:sudofox,项目名称:Backmemed,代码行数:6,代码来源:Shaders.java


注:本文中的org.lwjgl.opengl.GL11.glRotatef方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。