VideoFormat.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 VideoFormat {
31  RGB(0),
32  BAYER(1),
33  IR_8BIT(2),
36  YUV_RGB(5),
37  YUV_RAW(6);
38 
39  private final int value;
40  private static final Map<Integer, VideoFormat> MAP = new HashMap<Integer, VideoFormat>(7);
41  static {
42  for(VideoFormat v : VideoFormat.values()) {
43  MAP.put(v.intValue(), v);
44  }
45  }
46 
47  private VideoFormat(int value) {
48  this.value = value;
49  }
50 
51  public int intValue() {
52  return value;
53  }
54 
55  public static VideoFormat fromInt(int value) {
56  return MAP.get(value);
57  }
58 }
static VideoFormat fromInt(int value)


libfreenect
Author(s): Hector Martin, Josh Blake, Kyle Machulis, OpenKinect community
autogenerated on Thu Jun 6 2019 19:25:38