Package org.lwjgl.nanovg
Class NSVGPath
- java.lang.Object
-
- org.lwjgl.system.Pointer.Default
-
- org.lwjgl.system.Struct
-
- org.lwjgl.nanovg.NSVGPath
-
- All Implemented Interfaces:
org.lwjgl.system.Pointer
public class NSVGPath extends org.lwjgl.system.StructMember documentation
pts– cubic bezier points:x0,y0, [cpx1,cpx1,cpx2,cpy2,x1,y1], ...npts– total number of bezier pointsclosed– flag indicating if shapes should be treated as closedbounds– tight bounding box of the shape[minx,miny,maxx,maxy]next– pointer to next path, orNULLif last element
Layout
struct NSVGpath { float * pts; int npts; char closed; float bounds[4];NSVGpath* next; }
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classNSVGPath.BufferAn array ofNSVGPathstructs.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description java.nio.FloatBufferbounds()Returns aFloatBufferview of theboundsfield.floatbounds(int index)Returns the value at the specified index of theboundsfield.byteclosed()Returns the value of theclosedfield.static NSVGPathcreate(long address)Returns a newNSVGPathinstance for the specified memory address.static NSVGPath.Buffercreate(long address, int capacity)Create aNSVGPath.Bufferinstance at the specified memory.static NSVGPathcreateSafe(long address)static NSVGPath.BuffercreateSafe(long address, int capacity)static java.nio.FloatBuffernbounds(long struct)Unsafe version ofbounds().static floatnbounds(long struct, int index)Unsafe version ofbounds.static bytenclosed(long struct)Unsafe version ofclosed().NSVGPathnext()Returns aNSVGPathview of the struct pointed to by thenextfield.static NSVGPathnnext(long struct)Unsafe version ofnext().static intnnpts(long struct)Unsafe version ofnpts().intnpts()Returns the value of thenptsfield.static java.nio.FloatBuffernpts(long struct)Unsafe version ofpts.java.nio.FloatBufferpts()Returns aFloatBufferview of the data pointed to by theptsfield.intsizeof()
-
-
-
Constructor Detail
-
NSVGPath
public NSVGPath(java.nio.ByteBuffer container)
Creates aNSVGPathinstance at the current position of the specifiedByteBuffercontainer. Changes to the buffer's content will be visible to the struct instance and vice versa.The created instance holds a strong reference to the container object.
-
-
Method Detail
-
sizeof
public int sizeof()
- Specified by:
sizeofin classorg.lwjgl.system.Struct
-
pts
public java.nio.FloatBuffer pts()
Returns aFloatBufferview of the data pointed to by theptsfield.
-
npts
public int npts()
Returns the value of thenptsfield.
-
closed
public byte closed()
Returns the value of theclosedfield.
-
bounds
public java.nio.FloatBuffer bounds()
Returns aFloatBufferview of theboundsfield.
-
bounds
public float bounds(int index)
Returns the value at the specified index of theboundsfield.
-
create
public static NSVGPath create(long address)
Returns a newNSVGPathinstance for the specified memory address.
-
createSafe
@Nullable public static NSVGPath createSafe(long address)
-
create
public static NSVGPath.Buffer create(long address, int capacity)
Create aNSVGPath.Bufferinstance at the specified memory.- Parameters:
address- the memory addresscapacity- the buffer capacity
-
createSafe
@Nullable public static NSVGPath.Buffer createSafe(long address, int capacity)
-
npts
public static java.nio.FloatBuffer npts(long struct)
Unsafe version ofpts.
-
nnpts
public static int nnpts(long struct)
Unsafe version ofnpts().
-
nclosed
public static byte nclosed(long struct)
Unsafe version ofclosed().
-
nbounds
public static java.nio.FloatBuffer nbounds(long struct)
Unsafe version ofbounds().
-
nbounds
public static float nbounds(long struct, int index)Unsafe version ofbounds.
-
-