Package org.freedesktop.gstreamer.video
Class VideoGLTextureUploadMeta
java.lang.Object
io.github.jwharm.javagi.base.ProxyInstance
org.freedesktop.gstreamer.video.VideoGLTextureUploadMeta
- All Implemented Interfaces:
Proxy
Extra buffer metadata for uploading a buffer to an OpenGL texture
ID. The caller of gst_video_gl_texture_upload_meta_upload() must
have OpenGL set up and call this from a thread where it is valid
to upload something to an OpenGL texture.
-
Constructor Summary
ConstructorDescriptionAllocate a new VideoGLTextureUploadMeta.VideoGLTextureUploadMeta
(Arena arena) Allocate a new VideoGLTextureUploadMeta.VideoGLTextureUploadMeta
(MemorySegment address) Create a VideoGLTextureUploadMeta proxy instance for the provided memory address.VideoGLTextureUploadMeta
(Meta meta, VideoGLTextureOrientation textureOrientation, int nTextures, VideoGLTextureType[] textureType, Buffer buffer, VideoGLTextureUpload upload, MemorySegment userData, BoxedCopyFunc userDataCopy, BoxedFreeFunc userDataFree) Allocate a new VideoGLTextureUploadMeta with the fields set to the provided values.VideoGLTextureUploadMeta
(Meta meta, VideoGLTextureOrientation textureOrientation, int nTextures, VideoGLTextureType[] textureType, Buffer buffer, VideoGLTextureUpload upload, MemorySegment userData, BoxedCopyFunc userDataCopy, BoxedFreeFunc userDataFree, Arena arena) Allocate a new VideoGLTextureUploadMeta with the fields set to the provided values. -
Method Summary
Modifier and TypeMethodDescriptionstatic MetaInfo
getInfo()
static MemoryLayout
The memory layout of the native struct.Read the value of the fieldbuffer
.readMeta()
Read the value of the fieldmeta
.int
Read the value of the fieldn_textures
.Read the value of the fieldtexture_orientation
.Read the value of the fieldtexture_type
.Read the value of the fieldupload
.Read the value of the fielduser_data
.Read the value of the fielduser_data_copy
.Read the value of the fielduser_data_free
.boolean
upload
(MemorySegment textureId) Uploads the buffer which owns the meta to a specific texture ID.void
writeBuffer
(Buffer buffer) Write a value in the fieldbuffer
.void
Write a value in the fieldmeta
.void
writeNTextures
(int nTextures) Write a value in the fieldn_textures
.void
writeTextureOrientation
(VideoGLTextureOrientation textureOrientation) Write a value in the fieldtexture_orientation
.void
writeTextureType
(VideoGLTextureType[] textureType, Arena _arena) Write a value in the fieldtexture_type
.void
writeUpload
(VideoGLTextureUpload upload, Arena _arena) Write a value in the fieldupload
.void
writeUserData
(MemorySegment userData) Write a value in the fielduser_data
.void
writeUserDataCopy
(BoxedCopyFunc userDataCopy, Arena _arena) Write a value in the fielduser_data_copy
.void
writeUserDataFree
(BoxedFreeFunc userDataFree, Arena _arena) Write a value in the fielduser_data_free
.Methods inherited from class io.github.jwharm.javagi.base.ProxyInstance
equals, handle, hashCode
-
Constructor Details
-
VideoGLTextureUploadMeta
Create a VideoGLTextureUploadMeta proxy instance for the provided memory address.- Parameters:
address
- the memory address of the native object
-
VideoGLTextureUploadMeta
Allocate a new VideoGLTextureUploadMeta.- Parameters:
arena
- to control the memory allocation scope
-
VideoGLTextureUploadMeta
public VideoGLTextureUploadMeta()Allocate a new VideoGLTextureUploadMeta. The memory is allocated withArena.ofAuto()
. -
VideoGLTextureUploadMeta
public VideoGLTextureUploadMeta(Meta meta, VideoGLTextureOrientation textureOrientation, int nTextures, VideoGLTextureType[] textureType, Buffer buffer, VideoGLTextureUpload upload, MemorySegment userData, BoxedCopyFunc userDataCopy, BoxedFreeFunc userDataFree, Arena arena) Allocate a new VideoGLTextureUploadMeta with the fields set to the provided values.- Parameters:
meta
- value for the fieldmeta
textureOrientation
- value for the fieldtextureOrientation
nTextures
- value for the fieldnTextures
textureType
- value for the fieldtextureType
buffer
- value for the fieldbuffer
upload
- value for the fieldupload
userData
- value for the fielduserData
userDataCopy
- value for the fielduserDataCopy
userDataFree
- value for the fielduserDataFree
arena
- to control the memory allocation scope
-
VideoGLTextureUploadMeta
public VideoGLTextureUploadMeta(Meta meta, VideoGLTextureOrientation textureOrientation, int nTextures, VideoGLTextureType[] textureType, Buffer buffer, VideoGLTextureUpload upload, MemorySegment userData, BoxedCopyFunc userDataCopy, BoxedFreeFunc userDataFree) Allocate a new VideoGLTextureUploadMeta with the fields set to the provided values. The memory is allocated withArena.ofAuto()
.- Parameters:
meta
- value for the fieldmeta
textureOrientation
- value for the fieldtextureOrientation
nTextures
- value for the fieldnTextures
textureType
- value for the fieldtextureType
buffer
- value for the fieldbuffer
upload
- value for the fieldupload
userData
- value for the fielduserData
userDataCopy
- value for the fielduserDataCopy
userDataFree
- value for the fielduserDataFree
-
-
Method Details
-
getMemoryLayout
The memory layout of the native struct.- Returns:
- the memory layout
-
readMeta
-
writeMeta
Write a value in the fieldmeta
.- Parameters:
meta
- The new value for the fieldmeta
-
readTextureOrientation
Read the value of the fieldtexture_orientation
.- Returns:
- The value of the field
texture_orientation
-
writeTextureOrientation
Write a value in the fieldtexture_orientation
.- Parameters:
textureOrientation
- The new value for the fieldtexture_orientation
-
readNTextures
public int readNTextures()Read the value of the fieldn_textures
.- Returns:
- The value of the field
n_textures
-
writeNTextures
public void writeNTextures(int nTextures) Write a value in the fieldn_textures
.- Parameters:
nTextures
- The new value for the fieldn_textures
-
readTextureType
Read the value of the fieldtexture_type
.- Returns:
- The value of the field
texture_type
-
writeTextureType
Write a value in the fieldtexture_type
.- Parameters:
textureType
- The new value for the fieldtexture_type
_arena
- to control the memory allocation scope
-
readBuffer
Read the value of the fieldbuffer
.- Returns:
- The value of the field
buffer
-
writeBuffer
Write a value in the fieldbuffer
.- Parameters:
buffer
- The new value for the fieldbuffer
-
readUpload
Read the value of the fieldupload
.- Returns:
- The value of the field
upload
-
writeUpload
Write a value in the fieldupload
.- Parameters:
upload
- The new value for the fieldupload
_arena
- to control the memory allocation scope
-
readUserData
Read the value of the fielduser_data
.- Returns:
- The value of the field
user_data
-
writeUserData
Write a value in the fielduser_data
.- Parameters:
userData
- The new value for the fielduser_data
-
readUserDataCopy
Read the value of the fielduser_data_copy
.- Returns:
- The value of the field
user_data_copy
-
writeUserDataCopy
Write a value in the fielduser_data_copy
.- Parameters:
userDataCopy
- The new value for the fielduser_data_copy
_arena
- to control the memory allocation scope
-
readUserDataFree
Read the value of the fielduser_data_free
.- Returns:
- The value of the field
user_data_free
-
writeUserDataFree
Write a value in the fielduser_data_free
.- Parameters:
userDataFree
- The new value for the fielduser_data_free
_arena
- to control the memory allocation scope
-
getInfo
-
upload
Uploads the buffer which owns the meta to a specific texture ID.- Parameters:
textureId
- the texture IDs to upload to- Returns:
true
if uploading succeeded,false
otherwise.
-