Java 类net.minecraft.client.renderer.texture.TextureManager 实例源码

项目:Metalworks    文件:Util.java   
@SideOnly(Side.CLIENT)
public static void renderItemInWorld(ItemStack stack){
    if(!stack.isEmpty()){
        Minecraft mc = Minecraft.getMinecraft();
        RenderItem renderer = mc.getRenderItem();
        TextureManager manager = mc.getTextureManager();

        IBakedModel model = renderer.getItemModelWithOverrides(stack, null, null);

        manager.bindTexture(TextureMap.LOCATION_BLOCKS_TEXTURE);
        manager.getTexture(TextureMap.LOCATION_BLOCKS_TEXTURE).setBlurMipmap(false, false);
        GlStateManager.enableRescaleNormal();
        GlStateManager.enableBlend();
        GlStateManager.pushMatrix();
        model = ForgeHooksClient.handleCameraTransforms(model, ItemCameraTransforms.TransformType.FIXED, false);
        renderer.renderItem(stack, model);
        GlStateManager.cullFace(GlStateManager.CullFace.BACK);
        GlStateManager.popMatrix();
        GlStateManager.disableRescaleNormal();
        GlStateManager.disableBlend();
        manager.bindTexture(TextureMap.LOCATION_BLOCKS_TEXTURE);
        manager.getTexture(TextureMap.LOCATION_BLOCKS_TEXTURE).restoreLastBlurMipmap();
    }
}
项目:DecompiledMinecraft    文件:EffectRenderer.java   
public EffectRenderer(World worldIn, TextureManager rendererIn)
{
    this.worldObj = worldIn;
    this.renderer = rendererIn;

    for (int i = 0; i < 4; ++i)
    {
        this.fxLayers[i] = new List[2];

        for (int j = 0; j < 2; ++j)
        {
            this.fxLayers[i][j] = Lists.newArrayList();
        }
    }

    this.registerVanillaParticles();
}
项目:DecompiledMinecraft    文件:TileEntityRendererDispatcher.java   
public void cacheActiveRenderInfo(World worldIn, TextureManager textureManagerIn, FontRenderer fontrendererIn, Entity entityIn, float partialTicks)
{
    if (this.worldObj != worldIn)
    {
        this.setWorld(worldIn);
    }

    this.renderEngine = textureManagerIn;
    this.entity = entityIn;
    this.fontRenderer = fontrendererIn;
    this.entityYaw = entityIn.prevRotationYaw + (entityIn.rotationYaw - entityIn.prevRotationYaw) * partialTicks;
    this.entityPitch = entityIn.prevRotationPitch + (entityIn.rotationPitch - entityIn.prevRotationPitch) * partialTicks;
    this.entityX = entityIn.lastTickPosX + (entityIn.posX - entityIn.lastTickPosX) * (double)partialTicks;
    this.entityY = entityIn.lastTickPosY + (entityIn.posY - entityIn.lastTickPosY) * (double)partialTicks;
    this.entityZ = entityIn.lastTickPosZ + (entityIn.posZ - entityIn.lastTickPosZ) * (double)partialTicks;
}
项目:BaseClient    文件:ShadersTex.java   
static void updateTextureMinMagFilter()
{
    TextureManager texturemanager = Minecraft.getMinecraft().getTextureManager();
    ITextureObject itextureobject = texturemanager.getTexture(TextureMap.locationBlocksTexture);

    if (itextureobject != null)
    {
        MultiTexID multitexid = itextureobject.getMultiTexID();
        GlStateManager.bindTexture(multitexid.base);
        GL11.glTexParameteri(GL11.GL_TEXTURE_2D, GL11.GL_TEXTURE_MIN_FILTER, Shaders.texMinFilValue[Shaders.configTexMinFilB]);
        GL11.glTexParameteri(GL11.GL_TEXTURE_2D, GL11.GL_TEXTURE_MAG_FILTER, Shaders.texMagFilValue[Shaders.configTexMagFilB]);
        GlStateManager.bindTexture(multitexid.norm);
        GL11.glTexParameteri(GL11.GL_TEXTURE_2D, GL11.GL_TEXTURE_MIN_FILTER, Shaders.texMinFilValue[Shaders.configTexMinFilN]);
        GL11.glTexParameteri(GL11.GL_TEXTURE_2D, GL11.GL_TEXTURE_MAG_FILTER, Shaders.texMagFilValue[Shaders.configTexMagFilN]);
        GlStateManager.bindTexture(multitexid.spec);
        GL11.glTexParameteri(GL11.GL_TEXTURE_2D, GL11.GL_TEXTURE_MIN_FILTER, Shaders.texMinFilValue[Shaders.configTexMinFilS]);
        GL11.glTexParameteri(GL11.GL_TEXTURE_2D, GL11.GL_TEXTURE_MAG_FILTER, Shaders.texMagFilValue[Shaders.configTexMagFilS]);
        GlStateManager.bindTexture(0);
    }
}
项目:BaseClient    文件:CustomItemProperties.java   
public float getTextureHeight(TextureManager p_getTextureHeight_1_)
{
    if (this.textureHeight <= 0)
    {
        if (this.textureLocation != null)
        {
            ITextureObject itextureobject = p_getTextureHeight_1_.getTexture(this.textureLocation);
            int i = itextureobject.getGlTextureId();
            int j = GlStateManager.getBoundTexture();
            GlStateManager.bindTexture(i);
            this.textureHeight = GL11.glGetTexLevelParameteri(GL11.GL_TEXTURE_2D, 0, GL11.GL_TEXTURE_HEIGHT);
            GlStateManager.bindTexture(j);
        }

        if (this.textureHeight <= 0)
        {
            this.textureHeight = 16;
        }
    }

    return (float)this.textureHeight;
}
项目:Backmemed    文件:CustomItemProperties.java   
public float getTextureWidth(TextureManager p_getTextureWidth_1_)
{
    if (this.textureWidth <= 0)
    {
        if (this.textureLocation != null)
        {
            ITextureObject itextureobject = p_getTextureWidth_1_.getTexture(this.textureLocation);
            int i = itextureobject.getGlTextureId();
            int j = GlStateManager.getBoundTexture();
            GlStateManager.bindTexture(i);
            this.textureWidth = GL11.glGetTexLevelParameteri(GL11.GL_TEXTURE_2D, 0, GL11.GL_TEXTURE_WIDTH);
            GlStateManager.bindTexture(j);
        }

        if (this.textureWidth <= 0)
        {
            this.textureWidth = 16;
        }
    }

    return (float)this.textureWidth;
}
项目:BaseClient    文件:EffectRenderer.java   
public EffectRenderer(World worldIn, TextureManager rendererIn)
{
    this.worldObj = worldIn;
    this.renderer = rendererIn;

    for (int i = 0; i < 4; ++i)
    {
        this.fxLayers[i] = new List[2];

        for (int j = 0; j < 2; ++j)
        {
            this.fxLayers[i][j] = Lists.newArrayList();
        }
    }

    this.registerVanillaParticles();
}
项目:BaseClient    文件:RenderItem.java   
public RenderItem(TextureManager textureManager, ModelManager modelManager)
{
    this.textureManager = textureManager;
    Config.setModelManager(modelManager);

    if (Reflector.ItemModelMesherForge_Constructor.exists())
    {
        this.itemModelMesher = (ItemModelMesher)Reflector.newInstance(Reflector.ItemModelMesherForge_Constructor, new Object[] {modelManager});
    }
    else
    {
        this.itemModelMesher = new ItemModelMesher(modelManager);
    }

    this.registerItems();
}
项目:CustomWorldGen    文件:ParticleManager.java   
public ParticleManager(World worldIn, TextureManager rendererIn)
{
    this.worldObj = worldIn;
    this.renderer = rendererIn;

    for (int i = 0; i < 4; ++i)
    {
        this.fxLayers[i] = new ArrayDeque[2];

        for (int j = 0; j < 2; ++j)
        {
            this.fxLayers[i][j] = Queues.newArrayDeque();
        }
    }

    this.registerVanillaParticles();
}
项目:BaseClient    文件:EffectRenderer.java   
public EffectRenderer(World worldIn, TextureManager rendererIn)
{
    this.worldObj = worldIn;
    this.renderer = rendererIn;

    for (int i = 0; i < 4; ++i)
    {
        this.fxLayers[i] = new List[2];

        for (int j = 0; j < 2; ++j)
        {
            this.fxLayers[i][j] = Lists.newArrayList();
        }
    }

    this.registerVanillaParticles();
}
项目:BaseClient    文件:TileEntityRendererDispatcher.java   
public void cacheActiveRenderInfo(World worldIn, TextureManager textureManagerIn, FontRenderer fontrendererIn, Entity entityIn, float partialTicks)
{
    if (this.worldObj != worldIn)
    {
        this.setWorld(worldIn);
    }

    this.renderEngine = textureManagerIn;
    this.entity = entityIn;
    this.fontRenderer = fontrendererIn;
    this.entityYaw = entityIn.prevRotationYaw + (entityIn.rotationYaw - entityIn.prevRotationYaw) * partialTicks;
    this.entityPitch = entityIn.prevRotationPitch + (entityIn.rotationPitch - entityIn.prevRotationPitch) * partialTicks;
    this.entityX = entityIn.lastTickPosX + (entityIn.posX - entityIn.lastTickPosX) * (double)partialTicks;
    this.entityY = entityIn.lastTickPosY + (entityIn.posY - entityIn.lastTickPosY) * (double)partialTicks;
    this.entityZ = entityIn.lastTickPosZ + (entityIn.posZ - entityIn.lastTickPosZ) * (double)partialTicks;
}
项目:Backmemed    文件:CustomItemProperties.java   
public float getTextureHeight(TextureManager p_getTextureHeight_1_)
{
    if (this.textureHeight <= 0)
    {
        if (this.textureLocation != null)
        {
            ITextureObject itextureobject = p_getTextureHeight_1_.getTexture(this.textureLocation);
            int i = itextureobject.getGlTextureId();
            int j = GlStateManager.getBoundTexture();
            GlStateManager.bindTexture(i);
            this.textureHeight = GL11.glGetTexLevelParameteri(GL11.GL_TEXTURE_2D, 0, GL11.GL_TEXTURE_HEIGHT);
            GlStateManager.bindTexture(j);
        }

        if (this.textureHeight <= 0)
        {
            this.textureHeight = 16;
        }
    }

    return (float)this.textureHeight;
}
项目:PowerProbe    文件:PowerOverlayRender.java   
private void render(EntityPlayerSP player, float partialTicks) {
  double x = player.lastTickPosX + (player.posX - player.lastTickPosX) * partialTicks;
  double y = player.lastTickPosY + (player.posY - player.lastTickPosY) * partialTicks;
  double z = player.lastTickPosZ + (player.posZ - player.lastTickPosZ) * partialTicks;

  TextureManager tm = Minecraft.getMinecraft().renderEngine;
  GL11.glPushAttrib(GL11.GL_ALL_ATTRIB_BITS);
  GL11.glPushMatrix();
  GL11.glColor4f(1.0f, 1.0f, 1.0f, 0.3f);
  GL11.glEnable(GL11.GL_BLEND);
  GlStateManager.blendFunc(GlStateManager.SourceFactor.SRC_ALPHA, GlStateManager.DestFactor.ONE_MINUS_SRC_ALPHA);
  if (areaOverlays != null) {
    for (PowerOverlayData overlay : areaOverlays) {
      drawIconVectors(x, y, z, tm, overlay);
    }
  }
  drawIconVectors(x, y, z, tm, cursorOverlay);
  GL11.glPopMatrix();
  GL11.glPopAttrib();
}
项目:PowerProbe    文件:PowerOverlayRender.java   
private void drawIconVectors(double x, double y, double z, TextureManager tm, PowerOverlayData overlay) {
  if (overlay == null || overlay.pos == null || overlay.power < 1) {
    return;
  }
  VertexBuffer vb;
  tm.bindTexture(ICONS_TEXTURE);
  vb = Tessellator.getInstance().getBuffer();
  vb.begin(GL11.GL_QUADS, DefaultVertexFormats.POSITION_TEX_COLOR);
  vb.setTranslation(-x, -y, -z);

  if (overlay.power > 0) {
    renderVectors(vb, overlay.pos, TEXTURE_OFFSETS[0],
        overlay.strongPowered ? TEXTURE_OFFSETS[0] : TEXTURE_OFFSETS[1]);
  }
  vb.setTranslation(0, 0, 0);
  Tessellator.getInstance().draw();
}
项目:uniquecrops    文件:PageImage.java   
@Override
public void draw() {

    super.draw();

    TextureManager render = mc.renderEngine;
    render.bindTexture(resource);

    GlStateManager.enableBlend();
    GlStateManager.blendFunc(GL11.GL_SRC_ALPHA, GL11.GL_ONE_MINUS_SRC_ALPHA);
    GlStateManager.color(1F, 1F, 1F, 1F);
    int k = (gui.width - gui.WIDTH) / 2;
    gui.drawTexturedModalRect(k + 5, 5, 0, 0, gui.WIDTH, gui.HEIGHT);
    gui.drawCenteredString(mc.fontRendererObj, text, drawX + 60, drawY + 150, Color.gray.getRGB());
    GlStateManager.disableBlend();
}
项目:uniquecrops    文件:PageTitle.java   
@Override
public void draw() {

    super.draw();
    if (this.title != null) {

        TextureManager render = mc.renderEngine;
        render.bindTexture(resource);

        GlStateManager.enableBlend();
        GlStateManager.blendFunc(GL11.GL_SRC_ALPHA, GL11.GL_ONE_MINUS_SRC_ALPHA);
        GlStateManager.color(1F, 1F, 1F, 1F);
        int k = (gui.width - gui.WIDTH) / 2;
        gui.drawTexturedModalRect(k, 5, 0, 0, gui.WIDTH, gui.HEIGHT);
        drawSplitStringWithShadow(I18n.format(this.title), drawX + 10, drawY + 140, this.wordWrap, Color.gray.getRGB());
        gui.drawCenteredString(mc.fontRendererObj, "-by " + gui.reader.getName(), drawX + 60, drawY + 155, Color.lightGray.getRGB());
        GlStateManager.disableBlend();
    }
}
项目:Backmemed    文件:ShadersTex.java   
static void updateTextureMinMagFilter()
{
    TextureManager texturemanager = Minecraft.getMinecraft().getTextureManager();
    ITextureObject itextureobject = texturemanager.getTexture(TextureMap.LOCATION_BLOCKS_TEXTURE);

    if (itextureobject != null)
    {
        MultiTexID multitexid = itextureobject.getMultiTexID();
        GlStateManager.bindTexture(multitexid.base);
        GL11.glTexParameteri(GL11.GL_TEXTURE_2D, GL11.GL_TEXTURE_MIN_FILTER, Shaders.texMinFilValue[Shaders.configTexMinFilB]);
        GL11.glTexParameteri(GL11.GL_TEXTURE_2D, GL11.GL_TEXTURE_MAG_FILTER, Shaders.texMagFilValue[Shaders.configTexMagFilB]);
        GlStateManager.bindTexture(multitexid.norm);
        GL11.glTexParameteri(GL11.GL_TEXTURE_2D, GL11.GL_TEXTURE_MIN_FILTER, Shaders.texMinFilValue[Shaders.configTexMinFilN]);
        GL11.glTexParameteri(GL11.GL_TEXTURE_2D, GL11.GL_TEXTURE_MAG_FILTER, Shaders.texMagFilValue[Shaders.configTexMagFilN]);
        GlStateManager.bindTexture(multitexid.spec);
        GL11.glTexParameteri(GL11.GL_TEXTURE_2D, GL11.GL_TEXTURE_MIN_FILTER, Shaders.texMinFilValue[Shaders.configTexMinFilS]);
        GL11.glTexParameteri(GL11.GL_TEXTURE_2D, GL11.GL_TEXTURE_MAG_FILTER, Shaders.texMagFilValue[Shaders.configTexMagFilS]);
        GlStateManager.bindTexture(0);
    }
}
项目:CustomWorldGen    文件:TileEntityRendererDispatcher.java   
public void prepare(World p_190056_1_, TextureManager p_190056_2_, FontRenderer p_190056_3_, Entity p_190056_4_, RayTraceResult p_190056_5_, float p_190056_6_)
{
    if (this.worldObj != p_190056_1_)
    {
        this.setWorld(p_190056_1_);
    }

    this.renderEngine = p_190056_2_;
    this.entity = p_190056_4_;
    this.fontRenderer = p_190056_3_;
    this.cameraHitResult = p_190056_5_;
    this.entityYaw = p_190056_4_.prevRotationYaw + (p_190056_4_.rotationYaw - p_190056_4_.prevRotationYaw) * p_190056_6_;
    this.entityPitch = p_190056_4_.prevRotationPitch + (p_190056_4_.rotationPitch - p_190056_4_.prevRotationPitch) * p_190056_6_;
    this.entityX = p_190056_4_.lastTickPosX + (p_190056_4_.posX - p_190056_4_.lastTickPosX) * (double)p_190056_6_;
    this.entityY = p_190056_4_.lastTickPosY + (p_190056_4_.posY - p_190056_4_.lastTickPosY) * (double)p_190056_6_;
    this.entityZ = p_190056_4_.lastTickPosZ + (p_190056_4_.posZ - p_190056_4_.lastTickPosZ) * (double)p_190056_6_;
}
项目:Backmemed    文件:SkinManager.java   
public SkinManager(TextureManager textureManagerInstance, File skinCacheDirectory, MinecraftSessionService sessionService)
{
    this.textureManager = textureManagerInstance;
    this.skinCacheDir = skinCacheDirectory;
    this.sessionService = sessionService;
    this.skinCacheLoader = CacheBuilder.newBuilder().expireAfterAccess(15L, TimeUnit.SECONDS).<GameProfile, Map<Type, MinecraftProfileTexture>>build(new CacheLoader<GameProfile, Map<Type, MinecraftProfileTexture>>()
    {
        public Map<Type, MinecraftProfileTexture> load(GameProfile p_load_1_) throws Exception
        {
            try
            {
                return Minecraft.getMinecraft().getSessionService().getTextures(p_load_1_, false);
            }
            catch (Throwable var3)
            {
                return Maps.<Type, MinecraftProfileTexture>newHashMap();
            }
        }
    });
}
项目:Backmemed    文件:RenderItem.java   
public RenderItem(TextureManager p_i46552_1_, ModelManager p_i46552_2_, ItemColors p_i46552_3_)
{
    this.textureManager = p_i46552_1_;
    this.modelManager = p_i46552_2_;

    if (Reflector.ItemModelMesherForge_Constructor.exists())
    {
        this.itemModelMesher = (ItemModelMesher)Reflector.newInstance(Reflector.ItemModelMesherForge_Constructor, new Object[] {p_i46552_2_});
    }
    else
    {
        this.itemModelMesher = new ItemModelMesher(p_i46552_2_);
    }

    this.registerItems();
    this.itemColors = p_i46552_3_;
}
项目:Bewitchment    文件:ParticleBubble.java   
private ParticleBubble(TextureManager textureManagerIn, World world, double x, double y, double z, int rgb) {
    super(world, x, y, z, 0, 0, 0);
    this.textureManager = textureManagerIn;
    this.motionX *= 0.009999999776482582D;
    this.motionY = 0.1D * 0.20000000298023224D + (Math.random() * 2.0D - 1.0D) * 0.019999999552965164D;
    this.motionZ *= 0.009999999776482582D;

    this.particleScale *= 0.025F;
    this.particleMaxAge = 2;
    rgb = new Color(rgb, false).brighter().brighter().brighter().brighter().hashCode();
    float r = (rgb >>> 16 & 0xFF) / 256.0F;
    float g = (rgb >>> 8 & 0xFF) / 256.0F;
    float b = (rgb & 0xFF) / 256.0F;
    setRBGColorF(r, g, b);
}
项目:Metalworks    文件:InterfaceCrusher.java   
@SideOnly(Side.CLIENT)
@Override
public void drawBackground(TileCrusher tile, GuiMachine<TileCrusher> gui, TextureManager texture, int guiLeft, int guiTop, int mouseX, int mouseY, float partialTicks) {
    texture.bindTexture(LOC);
    gui.drawTexturedModalRect(guiLeft, guiTop, 0, 0, gui.getXSize(), gui.getYSize());
    if(tile.maxBurn > 0){
        int i = (int) ((tile.burn / (tile.maxBurn  * 1.0F)) * 25.0F);
        gui.drawTexturedModalRect(guiLeft + 83, guiTop + 25, 0, 74, 30, 25 - i);
    }
}
项目:Metalworks    文件:InterfaceDuster.java   
@SideOnly(Side.CLIENT)
@Override
public void drawBackground(TileDuster tile, GuiMachine<TileDuster> gui, TextureManager texture, int guiLeft, int guiTop, int mouseX, int mouseY, float partialTicks) {
    texture.bindTexture(LOC);
    gui.drawTexturedModalRect(guiLeft, guiTop, 0, 0, gui.getXSize(), gui.getYSize());
    if(tile.maxBurn > 0){
        int i = (int) ((tile.burn / (tile.maxBurn  * 1.0F)) * 25.0F);
        gui.drawTexturedModalRect(guiLeft + 73, guiTop + 29, 176, 0, 30, 25 - i);
    }
}
项目:Metalworks    文件:InterfaceBlastFurnace.java   
@SideOnly(Side.CLIENT)
@Override
public void drawBackground(TileBlastFurnace tile, GuiMachine<TileBlastFurnace> gui, TextureManager texture, int guiLeft, int guiTop, int mouseX, int mouseY, float partialTicks) {
    texture.bindTexture(LOC);
    gui.drawTexturedModalRect(guiLeft, guiTop, 0, 0, gui.getXSize(), gui.getYSize());
    if(tile.maxBurn > 0){
        int i = (int) ((tile.burnLeft / (tile.maxBurn  * 1.0F)) * 26);
        gui.drawTexturedModalRect(guiLeft + 68, guiTop + 29, 180, 0, 43, 26 - i);
    }
}
项目:DecompiledMinecraft    文件:EntityLargeExplodeFX.java   
protected EntityLargeExplodeFX(TextureManager renderEngine, World worldIn, double xCoordIn, double yCoordIn, double zCoordIn, double p_i1213_9_, double p_i1213_11_, double p_i1213_13_)
{
    super(worldIn, xCoordIn, yCoordIn, zCoordIn, 0.0D, 0.0D, 0.0D);
    this.theRenderEngine = renderEngine;
    this.field_70584_aq = 6 + this.rand.nextInt(4);
    this.particleRed = this.particleGreen = this.particleBlue = this.rand.nextFloat() * 0.6F + 0.4F;
    this.field_70582_as = 1.0F - (float)p_i1213_9_ * 0.5F;
}
项目:DecompiledMinecraft    文件:EntityFootStepFX.java   
protected EntityFootStepFX(TextureManager currentFootStepsIn, World worldIn, double xCoordIn, double yCoordIn, double zCoordIn)
{
    super(worldIn, xCoordIn, yCoordIn, zCoordIn, 0.0D, 0.0D, 0.0D);
    this.currentFootSteps = currentFootStepsIn;
    this.motionX = this.motionY = this.motionZ = 0.0D;
    this.footstepMaxAge = 200;
}
项目:DecompiledMinecraft    文件:ShaderGroup.java   
public ShaderGroup(TextureManager p_i1050_1_, IResourceManager p_i1050_2_, Framebuffer p_i1050_3_, ResourceLocation p_i1050_4_) throws JsonException, IOException, JsonSyntaxException
{
    this.resourceManager = p_i1050_2_;
    this.mainFramebuffer = p_i1050_3_;
    this.field_148036_j = 0.0F;
    this.field_148037_k = 0.0F;
    this.mainFramebufferWidth = p_i1050_3_.framebufferWidth;
    this.mainFramebufferHeight = p_i1050_3_.framebufferHeight;
    this.shaderGroupName = p_i1050_4_.toString();
    this.resetProjectionMatrix();
    this.parseGroup(p_i1050_1_, p_i1050_4_);
}
项目:DecompiledMinecraft    文件:SkinManager.java   
public SkinManager(TextureManager textureManagerInstance, File skinCacheDirectory, MinecraftSessionService sessionService)
{
    this.textureManager = textureManagerInstance;
    this.skinCacheDir = skinCacheDirectory;
    this.sessionService = sessionService;
    this.skinCacheLoader = CacheBuilder.newBuilder().expireAfterAccess(15L, TimeUnit.SECONDS).<GameProfile, Map<Type, MinecraftProfileTexture>>build(new CacheLoader<GameProfile, Map<Type, MinecraftProfileTexture>>()
    {
        public Map<Type, MinecraftProfileTexture> load(GameProfile p_load_1_) throws Exception
        {
            return Minecraft.getMinecraft().getSessionService().getTextures(p_load_1_, false);
        }
    });
}
项目:DecompiledMinecraft    文件:ResourcePackRepository.java   
public void bindTexturePackIcon(TextureManager textureManagerIn)
{
    if (this.locationTexturePackIcon == null)
    {
        this.locationTexturePackIcon = textureManagerIn.getDynamicTextureLocation("texturepackicon", new DynamicTexture(this.texturePackIcon));
    }

    textureManagerIn.bindTexture(this.locationTexturePackIcon);
}
项目:DecompiledMinecraft    文件:TileEntitySpecialRenderer.java   
protected void bindTexture(ResourceLocation location)
{
    TextureManager texturemanager = this.rendererDispatcher.renderEngine;

    if (texturemanager != null)
    {
        texturemanager.bindTexture(location);
    }
}
项目:CustomWorldGen    文件:TileEntitySpecialRenderer.java   
protected void bindTexture(ResourceLocation location)
{
    TextureManager texturemanager = this.rendererDispatcher.renderEngine;

    if (texturemanager != null)
    {
        texturemanager.bindTexture(location);
    }
}
项目:BaseClient    文件:ShadersTex.java   
public static void bindTextureMapForUpdateAndRender(TextureManager tm, ResourceLocation resLoc)
{
    TextureMap texturemap = (TextureMap)tm.getTexture(resLoc);
    Shaders.atlasSizeX = texturemap.atlasWidth;
    Shaders.atlasSizeY = texturemap.atlasHeight;
    bindTextures(updatingTex = texturemap.getMultiTexID());
}
项目:BaseClient    文件:PlayerItemModel.java   
public void render(ModelBiped p_render_1_, AbstractClientPlayer p_render_2_, float p_render_3_, float p_render_4_)
{
    TextureManager texturemanager = Config.getTextureManager();

    if (this.usePlayerTexture)
    {
        texturemanager.bindTexture(p_render_2_.getLocationSkin());
    }
    else if (this.textureLocation != null)
    {
        if (this.texture == null && this.textureImage != null)
        {
            this.texture = new DynamicTexture(this.textureImage);
            Minecraft.getMinecraft().getTextureManager().loadTexture(this.textureLocation, this.texture);
        }

        texturemanager.bindTexture(this.textureLocation);
    }
    else
    {
        texturemanager.bindTexture(this.locationMissing);
    }

    for (int i = 0; i < this.modelRenderers.length; ++i)
    {
        PlayerItemRenderer playeritemrenderer = this.modelRenderers[i];
        GlStateManager.pushMatrix();

        if (p_render_2_.isSneaking())
        {
            GlStateManager.translate(0.0F, 0.2F, 0.0F);
        }

        playeritemrenderer.render(p_render_1_, p_render_3_);
        GlStateManager.popMatrix();
    }
}
项目:BaseClient    文件:CustomSky.java   
public static void renderSky(World p_renderSky_0_, TextureManager p_renderSky_1_, float p_renderSky_2_, float p_renderSky_3_)
{
    if (worldSkyLayers != null)
    {
        if (Config.getGameSettings().renderDistanceChunks >= 8)
        {
            int i = p_renderSky_0_.provider.getDimensionId();

            if (i >= 0 && i < worldSkyLayers.length)
            {
                CustomSkyLayer[] acustomskylayer = worldSkyLayers[i];

                if (acustomskylayer != null)
                {
                    long j = p_renderSky_0_.getWorldTime();
                    int k = (int)(j % 24000L);

                    for (int l = 0; l < acustomskylayer.length; ++l)
                    {
                        CustomSkyLayer customskylayer = acustomskylayer[l];

                        if (customskylayer.isActive(p_renderSky_0_, k))
                        {
                            customskylayer.render(k, p_renderSky_2_, p_renderSky_3_);
                        }
                    }

                    Blender.clearBlend(p_renderSky_3_);
                }
            }
        }
    }
}
项目:CustomWorldGen    文件:ParticleFootStep.java   
protected ParticleFootStep(TextureManager currentFootStepsIn, World worldIn, double xCoordIn, double yCoordIn, double zCoordIn)
{
    super(worldIn, xCoordIn, yCoordIn, zCoordIn, 0.0D, 0.0D, 0.0D);
    this.currentFootSteps = currentFootStepsIn;
    this.motionX = 0.0D;
    this.motionY = 0.0D;
    this.motionZ = 0.0D;
    this.footstepMaxAge = 200;
}
项目:CustomWorldGen    文件:RenderItem.java   
public RenderItem(TextureManager p_i46552_1_, ModelManager p_i46552_2_, ItemColors p_i46552_3_)
{
    this.textureManager = p_i46552_1_;
    this.itemModelMesher = new net.minecraftforge.client.ItemModelMesherForge(p_i46552_2_);
    this.registerItems();
    this.itemColors = p_i46552_3_;
}
项目:BaseClient    文件:EntityFootStepFX.java   
protected EntityFootStepFX(TextureManager currentFootStepsIn, World worldIn, double xCoordIn, double yCoordIn, double zCoordIn)
{
    super(worldIn, xCoordIn, yCoordIn, zCoordIn, 0.0D, 0.0D, 0.0D);
    this.currentFootSteps = currentFootStepsIn;
    this.motionX = this.motionY = this.motionZ = 0.0D;
    this.footstepMaxAge = 200;
}
项目:BaseClient    文件:ShaderGroup.java   
public ShaderGroup(TextureManager p_i1050_1_, IResourceManager p_i1050_2_, Framebuffer p_i1050_3_, ResourceLocation p_i1050_4_) throws JsonException, IOException, JsonSyntaxException
{
    this.resourceManager = p_i1050_2_;
    this.mainFramebuffer = p_i1050_3_;
    this.field_148036_j = 0.0F;
    this.field_148037_k = 0.0F;
    this.mainFramebufferWidth = p_i1050_3_.framebufferWidth;
    this.mainFramebufferHeight = p_i1050_3_.framebufferHeight;
    this.shaderGroupName = p_i1050_4_.toString();
    this.resetProjectionMatrix();
    this.parseGroup(p_i1050_1_, p_i1050_4_);
}
项目:BaseClient    文件:SkinManager.java   
public SkinManager(TextureManager textureManagerInstance, File skinCacheDirectory, MinecraftSessionService sessionService)
{
    this.textureManager = textureManagerInstance;
    this.skinCacheDir = skinCacheDirectory;
    this.sessionService = sessionService;
    this.skinCacheLoader = CacheBuilder.newBuilder().expireAfterAccess(15L, TimeUnit.SECONDS).<GameProfile, Map<Type, MinecraftProfileTexture>>build(new CacheLoader<GameProfile, Map<Type, MinecraftProfileTexture>>()
    {
        public Map<Type, MinecraftProfileTexture> load(GameProfile p_load_1_) throws Exception
        {
            return Minecraft.getMinecraft().getSessionService().getTextures(p_load_1_, false);
        }
    });
}
项目:BaseClient    文件:ResourcePackRepository.java   
public void bindTexturePackIcon(TextureManager textureManagerIn)
{
    if (this.locationTexturePackIcon == null)
    {
        this.locationTexturePackIcon = textureManagerIn.getDynamicTextureLocation("texturepackicon", new DynamicTexture(this.texturePackIcon));
    }

    textureManagerIn.bindTexture(this.locationTexturePackIcon);
}