* Converted terrain textures to JPG to reduce filesize

* Updated to latest nifty gui
 * Music player now uses duration property
 * TestSerialization ported to new SM

git-svn-id: https://jmonkeyengine.googlecode.com/svn/trunk@7520 75d07b2b-3a1a-0410-a2c5-0572b91ccdca
3.0
Sha..rd 14 years ago
parent c91d1d264a
commit e91fe8f541
  1. BIN
      engine/lib/niftygui/nifty-1.3-SNAPSHOT.jar
  2. BIN
      engine/lib/niftygui/nifty-default-controls-1.3-SNAPSHOT.jar
  3. BIN
      engine/lib/niftygui/nifty-examples-1.3-SNAPSHOT.jar
  4. BIN
      engine/lib/niftygui/nifty-style-black-1.3-SNAPSHOT.jar
  5. 6
      engine/src/test-data/Textures/Terrain/Rocky/Rocky.j3m
  6. BIN
      engine/src/test-data/Textures/Terrain/Rocky/RockyNormals.jpg
  7. BIN
      engine/src/test-data/Textures/Terrain/Rocky/RockyTexture.jpg
  8. BIN
      engine/src/test-data/Textures/Terrain/splat/grass_normal.jpg
  9. BIN
      engine/src/test-data/Textures/Terrain/splat/grass_normal.png
  10. 2
      engine/src/test/jme3test/audio/TestMusicPlayer.java
  11. 3
      engine/src/test/jme3test/awt/TestSafeCanvas.java
  12. 29
      engine/src/test/jme3test/network/TestSerialization.java

@ -1,7 +1,7 @@
Material Rock : Common/MatDefs/Light/Lighting.j3md {
MaterialParameters {
Shininess: 100000.0
DiffuseMap : Textures/Terrain/Rocky/RockyTexture.png
NormalMap : Textures/Terrain/Rocky/RockyNormals.png
Shininess: 32.0
DiffuseMap : Textures/Terrain/Rocky/RockyTexture.jpg
NormalMap : Textures/Terrain/Rocky/RockyNormals.jpg
}
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 230 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 440 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 208 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.9 MiB

@ -180,7 +180,7 @@ public class TestMusicPlayer extends javax.swing.JFrame {
final File selected = chooser.getSelectedFile();
OGGLoader loader = new OGGLoader();
AudioKey key = new AudioKey(selected.getName(), true);
AudioKey key = new AudioKey(selected.getName(), true, true);
try{
musicData = (AudioData) loader.load(new AssetInfo(null, key) {
@Override

@ -23,12 +23,13 @@ public class TestSafeCanvas extends SimpleApplication {
app.setPauseOnLostFocus(false);
app.setSettings(settings);
app.createCanvas();
app.startCanvas(true);
JmeCanvasContext context = (JmeCanvasContext) app.getContext();
Canvas canvas = context.getCanvas();
canvas.setSize(settings.getWidth(), settings.getHeight());
app.startCanvas(true);
Thread.sleep(3000);

@ -32,10 +32,13 @@
package jme3test.network;
import com.jme3.network.connection.Client;
import com.jme3.network.connection.Server;
import com.jme3.network.events.MessageAdapter;
import com.jme3.network.message.Message;
import com.jme3.network.AbstractMessage;
import com.jme3.network.Client;
import com.jme3.network.HostedConnection;
import com.jme3.network.Message;
import com.jme3.network.MessageListener;
import com.jme3.network.Network;
import com.jme3.network.Server;
import com.jme3.network.serializing.Serializable;
import com.jme3.network.serializing.Serializer;
import java.io.IOException;
@ -46,7 +49,7 @@ import java.util.HashMap;
import java.util.List;
import java.util.Map;
public class TestSerialization extends MessageAdapter {
public class TestSerialization implements MessageListener<HostedConnection> {
@Serializable
public static class SomeObject {
@ -64,6 +67,7 @@ public class TestSerialization extends MessageAdapter {
return val;
}
@Override
public String toString(){
return "SomeObject[val="+val+"]";
}
@ -76,7 +80,7 @@ public class TestSerialization extends MessageAdapter {
}
@Serializable
public static class TestSerializationMessage extends Message {
public static class TestSerializationMessage extends AbstractMessage {
boolean z;
byte b;
@ -128,9 +132,8 @@ public class TestSerialization extends MessageAdapter {
}
}
@Override
public void messageReceived(Message msg){
TestSerializationMessage cm = (TestSerializationMessage) msg;
public void messageReceived(HostedConnection source, Message m) {
TestSerializationMessage cm = (TestSerializationMessage) m;
System.out.println(cm.z);
System.out.println(cm.b);
System.out.println(cm.c);
@ -151,16 +154,16 @@ public class TestSerialization extends MessageAdapter {
Serializer.registerClass(SomeObject.class);
Serializer.registerClass(TestSerializationMessage.class);
Server server = new Server(5110, 5110);
Server server = Network.createServer( 5110 );
server.start();
Client client = new Client("localhost", 5110, 5110);
Client client = Network.connectToServer( "localhost", 5110 );
client.start();
Thread.sleep(100);
server.addMessageListener(new TestSerialization(), TestSerializationMessage.class);
client.send(new TestSerializationMessage(true));
Thread.sleep(10000);
}
}

Loading…
Cancel
Save