// Path: src/main/java/com/pesegato/MonkeySheet/MonkeySheetAppState.java
// static Logger log = LoggerFactory.getLogger( MonkeySheetAppState.class );


import com.jme3.asset.AssetManager;
import com.jme3.material.Material;
import com.jme3.material.RenderState;
import com.jme3.math.ColorRGBA;
import com.jme3.renderer.RenderManager;
import com.jme3.renderer.ViewPort;
import com.jme3.scene.Geometry;
import com.jme3.scene.control.AbstractControl;
import com.jme3.texture.Texture;
import static com.pesegato.MonkeySheet.MonkeySheetAppState.log;
/*
 * To change this license header, choose License Headers in Project Properties.
 * To change this template file, choose Tools | Templates
 * and open the template in the editor.
 */
package com.pesegato.MonkeySheet;



/**
 * @author Pesegato
 */
public class MSMaterialControl extends AbstractControl {

    Material material;

    public String animation;
    public int position;
    MSSpriteControl msc;

    private float alphaValue = 1;
    private boolean flipped = false;
    private boolean grayScale = false;
    private float hueShift = 0;
    private ColorRGBA fogColor = ColorRGBA.Pink;
    private float fogIntensity = 0;

    public MSMaterialControl(AssetManager assetManager, Geometry geo, MSContainer msCont, MSControl msc) {
        material = new Material(assetManager, "MonkeySheet/MatDefs/Anim.j3md");
        Texture[] sheetsX = new Texture[msCont.sheets.length];
        for (int i = 0; i < msCont.sheets.length; i++) {
            long start = System.currentTimeMillis();
            long end;
            System.out.println("MonkeySheet: Now loading " + msCont.sheets[i]);
            sheetsX[i] = assetManager.loadTexture(msCont.sheets[i]);
            end = System.currentTimeMillis();
// Path: src/main/java/com/pesegato/MonkeySheet/MonkeySheetAppState.java
// static Logger log = LoggerFactory.getLogger( MonkeySheetAppState.class );


// Path: src/main/java/com/pesegato/MonkeySheet/MSMaterialControl.java
import com.jme3.asset.AssetManager;
import com.jme3.material.Material;
import com.jme3.material.RenderState;
import com.jme3.math.ColorRGBA;
import com.jme3.renderer.RenderManager;
import com.jme3.renderer.ViewPort;
import com.jme3.scene.Geometry;
import com.jme3.scene.control.AbstractControl;
import com.jme3.texture.Texture;
import static com.pesegato.MonkeySheet.MonkeySheetAppState.log;

/*
 * To change this license header, choose License Headers in Project Properties.
 * To change this template file, choose Tools | Templates
 * and open the template in the editor.
 */
package com.pesegato.MonkeySheet;



/**
 * @author Pesegato
 */
public class MSMaterialControl extends AbstractControl {

    Material material;

    public String animation;
    public int position;
    MSSpriteControl msc;

    private float alphaValue = 1;
    private boolean flipped = false;
    private boolean grayScale = false;
    private float hueShift = 0;
    private ColorRGBA fogColor = ColorRGBA.Pink;
    private float fogIntensity = 0;

    public MSMaterialControl(AssetManager assetManager, Geometry geo, MSContainer msCont, MSControl msc) {
        material = new Material(assetManager, "MonkeySheet/MatDefs/Anim.j3md");
        Texture[] sheetsX = new Texture[msCont.sheets.length];
        for (int i = 0; i < msCont.sheets.length; i++) {
            long start = System.currentTimeMillis();
            long end;
            System.out.println("MonkeySheet: Now loading " + msCont.sheets[i]);
            sheetsX[i] = assetManager.loadTexture(msCont.sheets[i]);
            end = System.currentTimeMillis();
            log.trace("loaded {}", (end - start));