當前位置: 首頁>>代碼示例>>Java>>正文


Java PixmapIO.readCIM方法代碼示例

本文整理匯總了Java中com.badlogic.gdx.graphics.PixmapIO.readCIM方法的典型用法代碼示例。如果您正苦於以下問題:Java PixmapIO.readCIM方法的具體用法?Java PixmapIO.readCIM怎麽用?Java PixmapIO.readCIM使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在com.badlogic.gdx.graphics.PixmapIO的用法示例。


在下文中一共展示了PixmapIO.readCIM方法的4個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。

示例1: prepare

import com.badlogic.gdx.graphics.PixmapIO; //導入方法依賴的package包/類
@Override
public void prepare () {
    if (isPrepared) throw new GdxRuntimeException("Already prepared");
    if (pixmap == null) {
        if (file.extension().equals("cim"))
            pixmap = PixmapIO.readCIM(file);
        else
            pixmap = ensurePot(new Pixmap(file));
        width = pixmap.getWidth();
        height = pixmap.getHeight();
        if (format == null) format = pixmap.getFormat();
    }
    
    applyFilter( pixmap );
    
    isPrepared = true;
}
 
開發者ID:Inari-Soft,項目名稱:inari-firefly-libGDX,代碼行數:18,代碼來源:FilteredTextureData.java

示例2: prepare

import com.badlogic.gdx.graphics.PixmapIO; //導入方法依賴的package包/類
public void prepare()
{
  if (this.isPrepared)
    throw new GdxRuntimeException("Already prepared");
  if (this.pixmap == null)
    if (!this.file.extension().equals("cim"))
      break label96;
  label96: for (this.pixmap = PixmapIO.readCIM(this.file); ; this.pixmap = ensurePot(new Pixmap(this.file)))
  {
    this.width = this.pixmap.getWidth();
    this.height = this.pixmap.getHeight();
    if (this.format == null)
      this.format = this.pixmap.getFormat();
    this.isPrepared = true;
    return;
  }
}
 
開發者ID:isnuryusuf,項目名稱:ingress-indonesia-dev,代碼行數:18,代碼來源:FileTextureData.java

示例3: prepare

import com.badlogic.gdx.graphics.PixmapIO; //導入方法依賴的package包/類
@Override
public void prepare () {
	if (isPrepared) throw new GdxRuntimeException("Already prepared");
	if (pixmap == null) {
		if (file.extension().equals("cim"))
			pixmap = PixmapIO.readCIM(file);
		else
			pixmap = ensurePot(new Pixmap(file));
		width = pixmap.getWidth();
		height = pixmap.getHeight();
		if (format == null) format = pixmap.getFormat();
	}
	isPrepared = true;
}
 
開發者ID:basherone,項目名稱:libgdxcn,代碼行數:15,代碼來源:FileTextureData.java

示例4: loadAsync

import com.badlogic.gdx.graphics.PixmapIO; //導入方法依賴的package包/類
public void loadAsync(AssetManager paramAssetManager, String paramString, TextureLoader.TextureParameter paramTextureParameter)
{
  if ((paramTextureParameter == null) || ((paramTextureParameter != null) && (paramTextureParameter.textureData == null)))
  {
    this.texture = null;
    boolean bool = false;
    Pixmap.Format localFormat = null;
    if (paramTextureParameter != null)
    {
      localFormat = paramTextureParameter.format;
      bool = paramTextureParameter.genMipMaps;
      this.texture = paramTextureParameter.texture;
    }
    FileHandle localFileHandle = resolve(paramString);
    if (!paramString.contains(".etc1"))
    {
      if (paramString.contains(".cim"));
      for (Pixmap localPixmap = PixmapIO.readCIM(localFileHandle); ; localPixmap = new Pixmap(localFileHandle))
      {
        this.data = new FileTextureData(localFileHandle, localPixmap, localFormat, bool);
        return;
      }
    }
    this.data = new ETC1TextureData(localFileHandle, bool);
    return;
  }
  this.data = paramTextureParameter.textureData;
  if (!this.data.isPrepared())
    this.data.prepare();
  this.texture = paramTextureParameter.texture;
}
 
開發者ID:isnuryusuf,項目名稱:ingress-indonesia-dev,代碼行數:32,代碼來源:TextureLoader.java


注:本文中的com.badlogic.gdx.graphics.PixmapIO.readCIM方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。