FreeWRL / FreeX3D 4.3.0
FreeWRLRendererInfo.java
1package sai;
2import org.web3d.x3d.sai.*;
3import java.util.*;
4
5public class FreeWRLRendererInfo {
6 private static HashMap renderingProperties;
7
8 static {
9 renderingProperties = new HashMap();
10
11 renderingProperties.put("Shading", "Phong");
12 renderingProperties.put("MaxTextureSize", "1024x1024");
13 renderingProperties.put("TextureUnits", new Integer(1));
14 renderingProperties.put("AntiAliased", new Boolean(true));
15 renderingProperties.put("ColorDepth", new Integer(64));
16 renderingProperties.put("TextureMemory", new Float(1024.0));
17 }
18
19 public static void setRenderingProperty(String key, Object value) {
20 if (!renderingProperties.containsKey(key)) {
21 System.out.println("Attempted to add invalid key " + key + " to rendering Properties table. Key rejected.");
22 } else {
23 renderingProperties.remove(key);
24 renderingProperties.put(key, value);
25 }
26 }
27
28 public static Object getRenderingProperty(String key) {
29 return renderingProperties.get(key);
30 }
31
32 public static Map getRenderingProperties() {
33 return renderingProperties;
34 }
35}
36
Definition Viewer.h:139