public final class JCGLRG8UByteBuffered extends Object implements JCGLRG8UType
ByteBuffer based implementation of the JCGLRG8U packed type.| Modifier and Type | Method and Description |
|---|---|
int |
getG() |
int |
getR() |
static JCGLRG8UType |
newValue(ByteBuffer in_buffer,
com.io7m.jpra.runtime.java.JPRACursorByteReadableType in_pointer)
Construct a view of a type.
|
static JCGLRG8UType |
newValueWithOffset(ByteBuffer in_buffer,
com.io7m.jpra.runtime.java.JPRACursorByteReadableType in_pointer,
int in_base_offset)
Construct a view of a type.
|
void |
set(int r,
int g)
Set the value of all fields.
|
void |
setG(int x)
Set the value of the
g field. |
void |
setR(int x)
Set the value of the
r field. |
static int |
sizeInOctets() |
int |
sizeOctets() |
public static JCGLRG8UType newValueWithOffset(ByteBuffer in_buffer, com.io7m.jpra.runtime.java.JPRACursorByteReadableType in_pointer, int in_base_offset)
in_buffer - A byte bufferin_pointer - A cursorin_base_offset - The base offset from the cursorpublic static JCGLRG8UType newValue(ByteBuffer in_buffer, com.io7m.jpra.runtime.java.JPRACursorByteReadableType in_pointer)
in_buffer - A byte bufferin_pointer - A cursorpublic int sizeOctets()
sizeOctets in interface com.io7m.jpra.runtime.java.JPRAValueTypepublic static int sizeInOctets()
public int getR()
getR in interface JCGLRG8UReadableTyper fieldpublic void setR(int x)
JCGLRG8UWritableTyper field.
The 8 least significant bits of x will be used.setR in interface JCGLRG8UWritableTypex - The new valuepublic int getG()
getG in interface JCGLRG8UReadableTypeg fieldpublic void setG(int x)
JCGLRG8UWritableTypeg field.
The 8 least significant bits of x will be used.setG in interface JCGLRG8UWritableTypex - The new valuepublic void set(int r,
int g)
JCGLRG8UWritableTypeset in interface JCGLRG8UWritableTyper - The value for field rg - The value for field gCopyright © 2017 <code@io7m.com> http://io7m.com