Copyright 2012 Mobialia
http://www.mobialia.com/
Permission is hereby granted, free of charge, to any person obtaining
a copy of this software and associated documentation files (the
"Software"), to ...
If you think the Android project jmini3d listed in this page is inappropriate, such as containing malicious code/tools or violating the copyright, please email info at java2s dot com, thanks.
Java Source Code
package jmini3d.demo;
/*fromwww.java2s.com*/import jmini3d.CubeMapTexture;
import jmini3d.Object3d;
import jmini3d.geometry.BoxGeometry;
import jmini3d.geometry.Geometry;
import jmini3d.material.Material;
publicclass EnvMapCubeScene extends ParentScene {
public EnvMapCubeScene() {
super("Cube with a cube map texture");
CubeMapTexture envMap = new CubeMapTexture(new String[]{"posx.png", "negx.png", "posy.png", "negy.png", "posz.png", "negz.png"});
Material material1 = new Material();
material1.color.setAll(0, 0, 0, 0);
material1.setEnvMap(envMap, 0);
material1.useEnvMapAsMap = true;
Geometry geometry = new BoxGeometry(1);
Object3d o3d = new Object3d(geometry, material1);
addChild(o3d);
}
}