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


Java AsynchronousAssetLoader.getDependencies方法代码示例

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


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

示例1: call

import com.badlogic.gdx.assets.loaders.AsynchronousAssetLoader; //导入方法依赖的package包/类
/** Loads parts of the asset asynchronously if the loader is an {@link AsynchronousAssetLoader}. */
@Override
public Void call () throws Exception {
	AsynchronousAssetLoader asyncLoader = (AsynchronousAssetLoader)loader;
	if (dependenciesLoaded == false) {
		dependencies = asyncLoader.getDependencies(assetDesc.fileName, resolve(loader, assetDesc), assetDesc.params);
		if (dependencies != null) {
			manager.injectDependencies(assetDesc.fileName, dependencies);
		} else {
			// if we have no dependencies, we load the async part of the task immediately.
			asyncLoader.loadAsync(manager, assetDesc.fileName, resolve(loader, assetDesc), assetDesc.params);
			asyncDone = true;
		}
	} else {
		asyncLoader.loadAsync(manager, assetDesc.fileName, resolve(loader, assetDesc), assetDesc.params);
	}
	return null;
}
 
开发者ID:basherone,项目名称:libgdxcn,代码行数:19,代码来源:AssetLoadingTask.java

示例2: call

import com.badlogic.gdx.assets.loaders.AsynchronousAssetLoader; //导入方法依赖的package包/类
public Void call()
{
  AsynchronousAssetLoader localAsynchronousAssetLoader = (AsynchronousAssetLoader)this.loader;
  if (!this.dependenciesLoaded)
  {
    this.dependencies = localAsynchronousAssetLoader.getDependencies(this.assetDesc.fileName, this.assetDesc.params);
    if (this.dependencies != null)
    {
      Iterator localIterator = this.dependencies.iterator();
      while (localIterator.hasNext())
      {
        AssetDescriptor localAssetDescriptor = (AssetDescriptor)localIterator.next();
        this.manager.injectDependency(this.assetDesc.fileName, localAssetDescriptor);
      }
    }
    localAsynchronousAssetLoader.loadAsync(this.manager, this.assetDesc.fileName, this.assetDesc.params);
    this.asyncDone = true;
  }
  while (true)
  {
    return null;
    localAsynchronousAssetLoader.loadAsync(this.manager, this.assetDesc.fileName, this.assetDesc.params);
  }
}
 
开发者ID:isnuryusuf,项目名称:ingress-indonesia-dev,代码行数:25,代码来源:AssetLoadingTask.java


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