Stitcher.java 文件源码

java
阅读 14 收藏 0 点赞 0 评论 0

项目:RuneCraftery 作者:
public void doStitch()
{
    StitchHolder[] astitchholder = (StitchHolder[])this.setStitchHolders.toArray(new StitchHolder[this.setStitchHolders.size()]);
    Arrays.sort(astitchholder);
    StitchHolder[] astitchholder1 = astitchholder;
    int i = astitchholder.length;

    for (int j = 0; j < i; ++j)
    {
        StitchHolder stitchholder = astitchholder1[j];

        if (!this.allocateSlot(stitchholder))
        {
            String s = String.format("Unable to fit: %s - size: %dx%d - Maybe try a lowerresolution texturepack?", new Object[] {stitchholder.getAtlasSprite().getIconName(), Integer.valueOf(stitchholder.getAtlasSprite().getIconWidth()), Integer.valueOf(stitchholder.getAtlasSprite().getIconHeight())});
            throw new StitcherException(stitchholder, s);
        }
    }

    if (this.forcePowerOf2)
    {
        this.currentWidth = this.getCeilPowerOf2(this.currentWidth);
        this.currentHeight = this.getCeilPowerOf2(this.currentHeight);
    }
}
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号