Examples of AssetManager


Examples of com.badlogic.gdx.assets.AssetManager

  private AssetManager assetManager;
 
  @Inject
  public TextureAssetManager(TextureDefinitions textureDefinitions)
  {
    assetManager = new AssetManager();
   
    for (TextureDefinition textureDefinition : textureDefinitions.getDefinitions())
    {
      assetManager.load(textureDefinition.getPath(), Texture.class);
    }
View Full Code Here

Examples of com.badlogic.gdx.assets.AssetManager

  private AssetManager assetManager;
 
  @Inject
  public SoundAssetManager(SoundDefinitions soundDefinitions)
  {
    assetManager = new AssetManager();
   
    for (SoundDefinition soundDefinition : soundDefinitions.getDefinitions())
    {
      assetManager.load(soundDefinition.getPath(), Sound.class);
    }
View Full Code Here

Examples of com.badlogic.gdx.assets.AssetManager

    super("Flame");
    MathUtils.random = new RandomXS128();
    particleSystem = ParticleSystem.get();
    effect = new ParticleEffect();
    particleSystem.add(effect);
    assetManager = new AssetManager();
    assetManager.setErrorListener(this);
    assetManager.setLoader(ParticleEffect.class, new ParticleEffectLoader(new InternalFileHandleResolver()));
    controllersData = new Array<ControllerData>();
   
    lwjglCanvas = new LwjglCanvas(renderer = new AppRenderer());
View Full Code Here

Examples of com.badlogic.gdx.assets.AssetManager

    }

    public final void init(String moduleName) {
        Detonator.INSTANCE.currentModuleID = moduleName;

        manager = new AssetManager();
    }
View Full Code Here

Examples of com.jme3.asset.AssetManager

    private void setColor(Node node, ColorRGBA color){
  for(int i = 0; i < node.getQuantity(); i++){
      Spatial spatial = node.getChild(i);
      if(spatial instanceof Geometry){
                //Material material = new Material();
                AssetManager assetManager = JmeSystem.newAssetManager(Thread.currentThread().getContextClassLoader().getResource("com/jme3/asset/Desktop.cfg"));
                Material material = new Material(assetManager, "Common/MatDefs/Misc/SolidColor.j3md");
                material.setColor("m_Color",color);
                //Material geomMaterial = ((Geometry)spatial).getMaterial();
                spatial.setMaterial(material);
                System.out.println("Spatial: "+spatial.getName());
View Full Code Here

Examples of com.jme3.asset.AssetManager

     * Sets the color of the geometries of the children and home.
     * Note, this is a recursive method.
     * @param node the node that contains children
     **/
    private void setColor(Geometry geometry, ColorRGBA color){
        AssetManager assetManager = JmeSystem.newAssetManager(Thread.currentThread().getContextClassLoader().getResource("com/jme3/asset/Desktop.cfg"));
        Material material = new Material(assetManager, "Common/MatDefs/Misc/SolidColor.j3md");
        material.setColor("m_Color",color);
        geometry.setMaterial(material);
        System.out.println("Spatial: "+geometry.getName());
    }
View Full Code Here

Examples of com.jme3.asset.AssetManager

public class TestAnimLoad
{
    public static void main(String[] args)
    {
        // create the geometry and attach it
      AssetManager assetMan = new DesktopAssetManager(true);
      AnimData aData = (AnimData) assetMan.loadAsset("ready_idle.anim.xml");
      if(aData.anims.size() == 1)
        aData.anims.get(0).getName();

    }
View Full Code Here

Examples of com.jme3.asset.AssetManager

//        texture.setScale( new Vector3f( 1, -1, 1 ) );
//        ts.setTexture( texture );
//        this.setRenderState( ts );


        AssetManager assetManager = JmeSystem.newAssetManager(Thread.currentThread().getContextClassLoader().getResource("com/jme3/asset/Desktop.cfg"));
        Material mat = new Material(assetManager, "Common/MatDefs/Misc/Unshaded.j3md");
        mat.setTransparent(true);
        mat.getAdditionalRenderState().setBlendMode(com.jme3.material.RenderState.BlendMode.Alpha);
        mat.selectTechnique("Default",renderer);
        mat.getActiveTechnique().getDef().setLightMode(LightMode.Disable);
View Full Code Here

Examples of com.jme3.asset.AssetManager

    return ret;
  }


  public void addSkyDome(){
    AssetManager assetManager = Singleton.get().getAssetManager().getJmeAssetMan();
   
    if(sky == null)
      sky = SkyFactory.createSky(Singleton.get().getAssetManager().getJmeAssetMan(),"models/textures/sky_povray1.jpg", true);
        Singleton.get().getSceneManager().changeCharNode(sky,Action.ADD);
       
View Full Code Here

Examples of com.jme3.asset.AssetManager

   
    skyLight = new DirectionalLight();
    skyLight.setColor(new ColorRGBA(1f, 1f, 1f, 1f));
    Singleton.get().getSceneManager().changeRootLight(skyLight, Action.ADD);
   
    AssetManager assetManager = Singleton.get().getAssetManager().getJmeAssetMan();
    com.l2client.util.SkyDome skyControl = new com.l2client.util.SkyDome(assetManager, cam);
    skyControl.setUseCalendar(false);
    skyControl.setSun(skyLight);
    skyControl.setControlSun(true);
    skyControl.setTimeOffset(timeOffset);
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.