001/**
002 * Copyright (c) 2011, The University of Southampton and the individual contributors.
003 * All rights reserved.
004 *
005 * Redistribution and use in source and binary forms, with or without modification,
006 * are permitted provided that the following conditions are met:
007 *
008 *   *  Redistributions of source code must retain the above copyright notice,
009 *      this list of conditions and the following disclaimer.
010 *
011 *   *  Redistributions in binary form must reproduce the above copyright notice,
012 *      this list of conditions and the following disclaimer in the documentation
013 *      and/or other materials provided with the distribution.
014 *
015 *   *  Neither the name of the University of Southampton nor the names of its
016 *      contributors may be used to endorse or promote products derived from this
017 *      software without specific prior written permission.
018 *
019 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
020 * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
021 * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
022 * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR
023 * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
024 * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
025 * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
026 * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
027 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
028 * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
029 */
030package org.openimaj.hardware.kinect.freenect;
031import org.openimaj.hardware.kinect.freenect.libfreenectLibrary.freenect_tilt_status_code;
032import org.bridj.IntValuedEnum;
033import org.bridj.StructObject;
034import org.bridj.ann.Field;
035import org.bridj.ann.Library;
036/**
037 * <i>native declaration : /usr/include/stdint.h</i><br>
038 * This file was autogenerated by <a href="http://jnaerator.googlecode.com/">JNAerator</a>,<br>
039 * a tool written by <a href="http://ochafik.com/">Olivier Chafik</a> that <a href="http://code.google.com/p/jnaerator/wiki/CreditsAndLicense">uses a few opensource projects.</a>.<br>
040 * For help, please visit <a href="http://nativelibs4java.googlecode.com/">NativeLibs4Java</a> or <a href="http://bridj.googlecode.com/">BridJ</a> .
041 */
042@SuppressWarnings("all")
043@Library("freenect-combined") 
044public class freenect_raw_tilt_state extends StructObject {
045        public freenect_raw_tilt_state() {
046                super();
047        }
048        /// < Raw accelerometer data for X-axis, see FREENECT_COUNTS_PER_G for conversion
049        @Field(0) 
050        public short accelerometer_x() {
051                return this.io.getShortField(this, 0);
052        }
053        /// < Raw accelerometer data for X-axis, see FREENECT_COUNTS_PER_G for conversion
054        @Field(0) 
055        public freenect_raw_tilt_state accelerometer_x(short accelerometer_x) {
056                this.io.setShortField(this, 0, accelerometer_x);
057                return this;
058        }
059        /// < Raw accelerometer data for Y-axis, see FREENECT_COUNTS_PER_G for conversion
060        @Field(1) 
061        public short accelerometer_y() {
062                return this.io.getShortField(this, 1);
063        }
064        /// < Raw accelerometer data for Y-axis, see FREENECT_COUNTS_PER_G for conversion
065        @Field(1) 
066        public freenect_raw_tilt_state accelerometer_y(short accelerometer_y) {
067                this.io.setShortField(this, 1, accelerometer_y);
068                return this;
069        }
070        /// < Raw accelerometer data for Z-axis, see FREENECT_COUNTS_PER_G for conversion
071        @Field(2) 
072        public short accelerometer_z() {
073                return this.io.getShortField(this, 2);
074        }
075        /// < Raw accelerometer data for Z-axis, see FREENECT_COUNTS_PER_G for conversion
076        @Field(2) 
077        public freenect_raw_tilt_state accelerometer_z(short accelerometer_z) {
078                this.io.setShortField(this, 2, accelerometer_z);
079                return this;
080        }
081        /// < Raw tilt motor angle encoder information
082        @Field(3) 
083        public byte tilt_angle() {
084                return this.io.getByteField(this, 3);
085        }
086        /// < Raw tilt motor angle encoder information
087        @Field(3) 
088        public freenect_raw_tilt_state tilt_angle(byte tilt_angle) {
089                this.io.setByteField(this, 3, tilt_angle);
090                return this;
091        }
092        /**
093         * < State of the tilt motor (stopped, moving, etc...)<br>
094         * C type : freenect_tilt_status_code
095         */
096        @Field(4) 
097        public IntValuedEnum<freenect_tilt_status_code > tilt_status() {
098                return this.io.getEnumField(this, 4);
099        }
100        /**
101         * < State of the tilt motor (stopped, moving, etc...)<br>
102         * C type : freenect_tilt_status_code
103         */
104        @Field(4) 
105        public freenect_raw_tilt_state tilt_status(IntValuedEnum<freenect_tilt_status_code > tilt_status) {
106                this.io.setEnumField(this, 4, tilt_status);
107                return this;
108        }
109}