本文整理汇总了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;
}
示例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);
}
}