All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.jogamp.oculusvr.ovrEyeRenderDesc Maven / Gradle / Ivy

The newest version!
/* !---- DO NOT EDIT: This file autogenerated by com/jogamp/gluegen/JavaEmitter.java on Sat Oct 10 03:31:13 CEST 2015 ----! */


package com.jogamp.oculusvr;

import java.nio.*;

import com.jogamp.gluegen.runtime.*;
import com.jogamp.common.os.*;
import com.jogamp.common.nio.*;
import jogamp.common.os.MachineDataInfoRuntime;

import com.jogamp.oculusvr.*;
import java.security.AccessController;
import java.security.PrivilegedAction;

public class ovrEyeRenderDesc {

  StructAccessor accessor;

  private static final int mdIdx = MachineDataInfoRuntime.getStatic().ordinal();
  private final MachineDataInfo md;

  private static final int[] ovrEyeRenderDesc_size = new int[] { 56 /* ARM_MIPS_32 */, 56 /* X86_32_UNIX */, 56 /* X86_32_MACOS */, 56 /* PPC_32_UNIX */, 56 /* SPARC_32_SUNOS */, 56 /* X86_32_WINDOWS */, 56 /* LP64_UNIX */, 56 /* X86_64_WINDOWS */  };
  private static final int[] Eye_offset = new int[] { 0 /* ARM_MIPS_32 */, 0 /* X86_32_UNIX */, 0 /* X86_32_MACOS */, 0 /* PPC_32_UNIX */, 0 /* SPARC_32_SUNOS */, 0 /* X86_32_WINDOWS */, 0 /* LP64_UNIX */, 0 /* X86_64_WINDOWS */ };
//private static final int[] Eye_size = new int[] { 4 /* ARM_MIPS_32 */, 4 /* X86_32_UNIX */, 4 /* X86_32_MACOS */, 4 /* PPC_32_UNIX */, 4 /* SPARC_32_SUNOS */, 4 /* X86_32_WINDOWS */, 4 /* LP64_UNIX */, 4 /* X86_64_WINDOWS */  };
  private static final int[] Fov_offset = new int[] { 4 /* ARM_MIPS_32 */, 4 /* X86_32_UNIX */, 4 /* X86_32_MACOS */, 4 /* PPC_32_UNIX */, 4 /* SPARC_32_SUNOS */, 4 /* X86_32_WINDOWS */, 4 /* LP64_UNIX */, 4 /* X86_64_WINDOWS */ };
  private static final int[] Fov_size = new int[] { 16 /* ARM_MIPS_32 */, 16 /* X86_32_UNIX */, 16 /* X86_32_MACOS */, 16 /* PPC_32_UNIX */, 16 /* SPARC_32_SUNOS */, 16 /* X86_32_WINDOWS */, 16 /* LP64_UNIX */, 16 /* X86_64_WINDOWS */  };
  private static final int[] DistortedViewport_offset = new int[] { 20 /* ARM_MIPS_32 */, 20 /* X86_32_UNIX */, 20 /* X86_32_MACOS */, 20 /* PPC_32_UNIX */, 20 /* SPARC_32_SUNOS */, 20 /* X86_32_WINDOWS */, 20 /* LP64_UNIX */, 20 /* X86_64_WINDOWS */ };
  private static final int[] DistortedViewport_size = new int[] { 16 /* ARM_MIPS_32 */, 16 /* X86_32_UNIX */, 16 /* X86_32_MACOS */, 16 /* PPC_32_UNIX */, 16 /* SPARC_32_SUNOS */, 16 /* X86_32_WINDOWS */, 16 /* LP64_UNIX */, 16 /* X86_64_WINDOWS */  };
  private static final int[] PixelsPerTanAngleAtCenter_offset = new int[] { 36 /* ARM_MIPS_32 */, 36 /* X86_32_UNIX */, 36 /* X86_32_MACOS */, 36 /* PPC_32_UNIX */, 36 /* SPARC_32_SUNOS */, 36 /* X86_32_WINDOWS */, 36 /* LP64_UNIX */, 36 /* X86_64_WINDOWS */ };
  private static final int[] PixelsPerTanAngleAtCenter_size = new int[] { 8 /* ARM_MIPS_32 */, 8 /* X86_32_UNIX */, 8 /* X86_32_MACOS */, 8 /* PPC_32_UNIX */, 8 /* SPARC_32_SUNOS */, 8 /* X86_32_WINDOWS */, 8 /* LP64_UNIX */, 8 /* X86_64_WINDOWS */  };
  private static final int[] HmdToEyeViewOffset_offset = new int[] { 44 /* ARM_MIPS_32 */, 44 /* X86_32_UNIX */, 44 /* X86_32_MACOS */, 44 /* PPC_32_UNIX */, 44 /* SPARC_32_SUNOS */, 44 /* X86_32_WINDOWS */, 44 /* LP64_UNIX */, 44 /* X86_64_WINDOWS */ };
  private static final int[] HmdToEyeViewOffset_size = new int[] { 12 /* ARM_MIPS_32 */, 12 /* X86_32_UNIX */, 12 /* X86_32_MACOS */, 12 /* PPC_32_UNIX */, 12 /* SPARC_32_SUNOS */, 12 /* X86_32_WINDOWS */, 12 /* LP64_UNIX */, 12 /* X86_64_WINDOWS */  };

  public static int size() {
    return ovrEyeRenderDesc_size[mdIdx];
  }

  public static ovrEyeRenderDesc create() {
    return create(Buffers.newDirectByteBuffer(size()));
  }

  public static ovrEyeRenderDesc create(java.nio.ByteBuffer buf) {
      return new ovrEyeRenderDesc(buf);
  }

  ovrEyeRenderDesc(java.nio.ByteBuffer buf) {
    md = MachineDataInfo.StaticConfig.values()[mdIdx].md;
    accessor = new StructAccessor(buf);
  }

  public java.nio.ByteBuffer getBuffer() {
    return accessor.getBuffer();
  }

  /** Setter for native field Eye: CType[(EnumType) typedef 'ovrEyeType', size [fixed true, lnx64 4], [const[type , false], enum  [const ovrEyeType_] {4: [ovrEye_Left = [0, [int: 0]], [ovrEye_Right = [1, [int: 1]], [ovrEye_Count = [2, [int: 2]], [ovrEye_EnumSize = [0x7fffffff, [int: 2147483647]], }, int]] */
  public ovrEyeRenderDesc setEye(int val) {
    accessor.setIntAt(Eye_offset[mdIdx], val);
    return this;
  }

  /** Getter for native field Eye: CType[(EnumType) typedef 'ovrEyeType', size [fixed true, lnx64 4], [const[type , false], enum  [const ovrEyeType_] {4: [ovrEye_Left = [0, [int: 0]], [ovrEye_Right = [1, [int: 1]], [ovrEye_Count = [2, [int: 2]], [ovrEye_EnumSize = [0x7fffffff, [int: 2147483647]], }, int]] */
  public int getEye() {
    return accessor.getIntAt(Eye_offset[mdIdx]);
  }

  /** Getter for native field Fov: CType[(StructType) typedef 'ovrFovPort', size [fixed false, lnx64 16], [const[false], struct{ovrFovPort_: 4, }]] */
  public ovrFovPort getFov() {
    return ovrFovPort.create( accessor.slice( Fov_offset[mdIdx], Fov_size[mdIdx] ) );
 }

  /** Getter for native field DistortedViewport: CType[(StructType) typedef 'ovrRecti', size [fixed false, lnx64 16], [const[false], struct{ovrRecti_: 2, }]] */
  public ovrRecti getDistortedViewport() {
    return ovrRecti.create( accessor.slice( DistortedViewport_offset[mdIdx], DistortedViewport_size[mdIdx] ) );
 }

  /** Getter for native field PixelsPerTanAngleAtCenter: CType[(StructType) typedef 'ovrVector2f', size [fixed false, lnx64 8], [const[false], struct{ovrVector2f_: 2, }]] */
  public ovrVector2f getPixelsPerTanAngleAtCenter() {
    return ovrVector2f.create( accessor.slice( PixelsPerTanAngleAtCenter_offset[mdIdx], PixelsPerTanAngleAtCenter_size[mdIdx] ) );
 }

  /** Getter for native field HmdToEyeViewOffset: CType[(StructType) typedef 'ovrVector3f', size [fixed false, lnx64 12], [const[false], struct{ovrVector3f_: 3, }]] */
  public ovrVector3f getHmdToEyeViewOffset() {
    return ovrVector3f.create( accessor.slice( HmdToEyeViewOffset_offset[mdIdx], HmdToEyeViewOffset_size[mdIdx] ) );
 }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy