/**
* Recalcula la multitextura generando la textura en el render indicado.
*/
protected void calculeMultitexture(N3Render render) {
if (!textures.isEmpty()) {
N3Texture2D texture = (N3Texture2D) textures.elementAt(0);
byte[] data = texture.getData();
for (int i = 0; i < textures.size(); i++) {
N3Texture2D texture2 = (N3Texture2D) textures.elementAt(i);
blend(data, texture2.getData(), texture2.getAlpha());
}
try {
texture_calc = new N3Texture2D(scene, name + "_multitext");
texture_calc.genTexture(data, texture.getDataFormat(),
texture.getWidth(), texture.getHeight(), render);
active_texture = texture_calc;
} catch (N3NameException ne) {
System.out