Resolution.java
Go to the documentation of this file.
1 
25 package org.openkinect.freenect;
26 
27 import java.util.HashMap;
28 import java.util.Map;
29 
30 public enum Resolution {
31  LOW(0),
32  MEDIUM(1),
33  HIGH(2);
34 
35  private final int value;
36  private static final Map<Integer, Resolution> MAP = new HashMap<Integer, Resolution>(3);
37  static {
38  for(Resolution v : Resolution.values()) {
39  MAP.put(v.intValue(), v);
40  }
41  }
42 
43  private Resolution(int value) {
44  this.value = value;
45  }
46 
47  public int intValue() {
48  return value;
49  }
50 
51  public static Resolution fromInt(int value) {
52  return MAP.get(value);
53  }
54 }
static Resolution fromInt(int value)
Definition: Resolution.java:51


libfreenect
Author(s): Hector Martin, Josh Blake, Kyle Machulis, OpenKinect community
autogenerated on Mon Jun 10 2019 13:46:42