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

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

The newest version!
/* !---- DO NOT EDIT: This file autogenerated by com/jogamp/gluegen/JavaEmitter.java on Sat Oct 10 03:31:12 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 ovrDistortionMesh {

  StructAccessor accessor;

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

  private static final int[] ovrDistortionMesh_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 */, 24 /* LP64_UNIX */, 24 /* X86_64_WINDOWS */  };
  private static final int[] pVertexData_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[] pVertexData_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 */, 8 /* LP64_UNIX */, 8 /* X86_64_WINDOWS */  };// JType[ovrDistortionVertex / 'ovrDistortionVertex', is[compound, ], descriptor 'LovrDistortionVertex;']
//private static final int[] pIndexData_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 */, 8 /* LP64_UNIX */, 8 /* X86_64_WINDOWS */ };
//private static final int[] pIndexData_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 */, 8 /* LP64_UNIX */, 8 /* X86_64_WINDOWS */  };// JType[ANON / NIL, primitivePointerType = SHORT, is[C-Primitive-Pointer, ], descriptor 'ANON_NIO']
  private static final int[] VertexCount_offset = 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 */, 16 /* LP64_UNIX */, 16 /* X86_64_WINDOWS */ };
//private static final int[] VertexCount_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[] IndexCount_offset = 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 */, 20 /* LP64_UNIX */, 20 /* X86_64_WINDOWS */ };
//private static final int[] IndexCount_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 */  };

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

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

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

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

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

  // SKIP setter for complex-pointer type in struct: ovrDistortionMesh.pVertexData: CType[(PointerType) 'ovrDistortionVertex *' -> (ovrDistortionVertex) * , size [fixed false, lnx64 8], [const[false], pointer*1]]

  /** Entry point to C language function: ovrDistortionVertex *  getPVertexData(ovrDistortionMesh * const  this0, const int32_t elem_offset)
, covering an array of length getVertexCount() */ private native ByteBuffer getPVertexData0(ByteBuffer jthis0, int elem_offset); /** Getter for native field pVertexData: CType[(PointerType) 'ovrDistortionVertex *' -> (ovrDistortionVertex) * , size [fixed false, lnx64 8], [const[false], pointer*1]], with array length of getVertexCount() */ public ovrDistortionVertex[] getPVertexData(final int offset, ovrDistortionVertex result[]) { final int arrayLength = getVertexCount(); if( offset + result.length > arrayLength ) { throw new IndexOutOfBoundsException("offset "+offset+" + result.length "+result.length+" > array-length "+arrayLength); }; final ByteBuffer source = getBuffer(); for(int index=0; index (unsigned unsigned short) * , size [fixed false, lnx64 8], [const[false], pointer*1]] /** Entry point to C language function: unsigned short * getPIndexData(ovrDistortionMesh * const this0, const int32_t arrayLength)
, covering an array of length getIndexCount() */ private native ByteBuffer getPIndexData0(ByteBuffer jthis0, int arrayLength); /** Getter for native field pIndexData: CType[(PointerType) 'short *' -> (unsigned unsigned short) * , size [fixed false, lnx64 8], [const[false], pointer*1]], with array length of getIndexCount() */ public ShortBuffer getPIndexData() { final int arrayLength = getIndexCount(); final ByteBuffer _res = getPIndexData0(getBuffer(), arrayLength); if (_res == null) return null; return Buffers.nativeOrder(_res).asShortBuffer(); } /** Setter for native field VertexCount: CType[(IntType) 'int', size [fixed false, lnx64 4], [const[false], int]] */ public ovrDistortionMesh setVertexCount(int val) { accessor.setIntAt(VertexCount_offset[mdIdx], val, md.intSizeInBytes()); return this; } /** Getter for native field VertexCount: CType[(IntType) 'int', size [fixed false, lnx64 4], [const[false], int]] */ public int getVertexCount() { return accessor.getIntAt(VertexCount_offset[mdIdx], md.intSizeInBytes()); } /** Setter for native field IndexCount: CType[(IntType) 'int', size [fixed false, lnx64 4], [const[false], int]] */ public ovrDistortionMesh setIndexCount(int val) { accessor.setIntAt(IndexCount_offset[mdIdx], val, md.intSizeInBytes()); return this; } /** Getter for native field IndexCount: CType[(IntType) 'int', size [fixed false, lnx64 4], [const[false], int]] */ public int getIndexCount() { return accessor.getIntAt(IndexCount_offset[mdIdx], md.intSizeInBytes()); } }




© 2015 - 2024 Weber Informatics LLC | Privacy Policy