SoCpuBufferObject Class |
CPU buffer object class.
Namespace: OIV.Inventor.Devices
The SoCpuBufferObject type exposes the following members.
Name | Description | |
---|---|---|
![]() | SoCpuBufferObject | Default constructor. |
![]() | SoCpuBufferObject(SbNativeArrayByte) | Constructor that takes an existing block of CPU memory. |
![]() | SoCpuBufferObject(SbNativeArray) | Obsolete. Constructor that takes an existing block of CPU memory. |
Name | Description | |
---|---|---|
![]() | ClearInstance | This function clears the content of the buffer, it frees the memory if the mode was COPY. |
![]() | CreateInstance | Create a new buffer with the same properties as the current one. |
![]() ![]() | CreateInstanceT(T) |
Factory method to create an instance of SoCpuBufferObject from
an arbitrary managed array of value type.
|
![]() ![]() | CreateInstanceT(SbNativeArrayT) |
Factory method to create an instance of SoCpuBufferObject from
an arbitrary SbNativeArrayT.
|
![]() ![]() | CreateInstanceT(T, Int32) |
Factory method to create an instance of SoCpuBufferObject from
an arbitrary managed array of value type.
|
![]() | Dispose |
Releases all resources used by SoDisposable.
(Inherited from SoDisposable.) |
![]() | Equals | (Inherited from Object.) |
![]() | FillT |
Convenient method to fill an SoBufferObject with
a default value.
(Inherited from SoBufferObject.) |
![]() | GetContext | Returns the device context where this buffer is valid. |
![]() | GetHashCode |
Overrides GetHashCode().
(Inherited from SoNetBase.) |
![]() | GetLongMappingSize | Obsolete. Returns the size of the mapped area in bytes. |
![]() | GetLongMappingStartPosition | Obsolete. Returns the position in the source buffer mapped in this buffer. |
![]() | GetLongSize | Obsolete. Returns the size, in bytes, of the buffer object. |
![]() | GetMappedBufferObject | Returns a pointer to the buffer object which is mapped by the actual object. |
![]() | GetMappingAccessMode | Returns the access mode used for the buffer mapping. |
![]() | GetMappingSize | Returns the size of the mapped area in bytes. |
![]() | GetMappingStartPosition | Returns the position in the source buffer mapped in this buffer. |
![]() | GetSize | Returns the size, in bytes, of the buffer object. |
![]() | GetType | Gets the Type of the current instance. (Inherited from Object.) |
![]() | LockBuffer | Locks the buffer against concurrent calls from different threads. |
![]() | Map(SoBufferObjectAccessModes) | Map the buffer to a system memory address. |
![]() | Map(SoBufferObject, SoBufferObjectAccessModes) | Calls Map(targetBufferObject, accessMode, System.UInt64(0), System.Convert.ToUInt64(SO_BUFFER_SIZE_ALL)). |
![]() | Map(SoCpuBufferObject, SoBufferObjectAccessModes) | Calls Map(targetBufferObject, accessMode, System.UInt64(0), System.Convert.ToUInt64(SO_BUFFER_SIZE_ALL)). |
![]() | Map(SoGLBufferObject, SoBufferObjectAccessModes) | Calls Map(targetBufferObject, accessMode, System.UInt64(0), System.Convert.ToUInt64(SO_BUFFER_SIZE_ALL)). |
![]() | Map(SoBufferObject, SoBufferObjectAccessModes, UInt64) | Calls Map(targetBufferObject, accessMode, startPosition, System.Convert.ToUInt64(SO_BUFFER_SIZE_ALL)). |
![]() | Map(SoCpuBufferObject, SoBufferObjectAccessModes, UInt64) | Calls Map(targetBufferObject, accessMode, startPosition, System.Convert.ToUInt64(SO_BUFFER_SIZE_ALL)). |
![]() | Map(SoGLBufferObject, SoBufferObjectAccessModes, UInt64) | Calls Map(targetBufferObject, accessMode, startPosition, System.Convert.ToUInt64(SO_BUFFER_SIZE_ALL)). |
![]() | Map(SoBufferObject, SoBufferObjectAccessModes, UInt64, UInt64) | Map the current "source" buffer object into the specified "target" buffer object. |
![]() | Map(SoCpuBufferObject, SoBufferObjectAccessModes, UInt64, UInt64) | Map the current buffer object into the specified CPU buffer object. |
![]() | Map(SoGLBufferObject, SoBufferObjectAccessModes, UInt64, UInt64) | Map the current buffer object into the specified GL buffer object. |
![]() | Memcpy(SoBufferObject) | Calls Memcpy(sourceBufferObject, System.UInt64(0), System.UInt64(0), System.Convert.ToUInt64(SO_BUFFER_SIZE_ALL)). |
![]() | Memcpy(SoCpuBufferObject) | Calls Memcpy(sourceBufferObject, System.UInt64(0), System.UInt64(0), System.Convert.ToUInt64(SO_BUFFER_SIZE_ALL)). |
![]() | Memcpy(SoGLBufferObject) | Calls Memcpy(sourceBufferObject, System.UInt64(0), System.UInt64(0), System.Convert.ToUInt64(SO_BUFFER_SIZE_ALL)). |
![]() | Memcpy(SoBufferObject, UInt64) | Calls Memcpy(sourceBufferObject, destOffset, System.UInt64(0), System.Convert.ToUInt64(SO_BUFFER_SIZE_ALL)). |
![]() | Memcpy(SoCpuBufferObject, UInt64) | Calls Memcpy(sourceBufferObject, destOffset, System.UInt64(0), System.Convert.ToUInt64(SO_BUFFER_SIZE_ALL)). |
![]() | Memcpy(SoGLBufferObject, UInt64) | Calls Memcpy(sourceBufferObject, destOffset, System.UInt64(0), System.Convert.ToUInt64(SO_BUFFER_SIZE_ALL)). |
![]() | Memcpy(SoBufferObject, UInt64, UInt64) | Calls Memcpy(sourceBufferObject, destOffset, sourceOffset, System.Convert.ToUInt64(SO_BUFFER_SIZE_ALL)). |
![]() | Memcpy(SoCpuBufferObject, UInt64, UInt64) | Calls Memcpy(sourceBufferObject, destOffset, sourceOffset, System.Convert.ToUInt64(SO_BUFFER_SIZE_ALL)). |
![]() | Memcpy(SoGLBufferObject, UInt64, UInt64) | Calls Memcpy(sourceBufferObject, destOffset, sourceOffset, System.Convert.ToUInt64(SO_BUFFER_SIZE_ALL)). |
![]() | Memcpy(SoBufferObject, UInt64, UInt64, UInt64) | Copy data from the specified buffer object into this buffer object. |
![]() | Memcpy(SoCpuBufferObject, UInt64, UInt64, UInt64) | Copy data from the specified CPU buffer object into this buffer object. |
![]() | Memcpy(SoGLBufferObject, UInt64, UInt64, UInt64) | Copy data from the specified GL buffer object into this buffer object. |
![]() | Memset(IntPtr) | Calls Memset(value, System.Convert.ToUInt64(1), System.UInt64(0), System.Convert.ToUInt64(SO_BUFFER_SIZE_ALL)). |
![]() | Memset(IntPtr, UInt64) | Calls Memset(value, valueSize, System.UInt64(0), System.Convert.ToUInt64(SO_BUFFER_SIZE_ALL)). |
![]() | Memset(IntPtr, UInt64, UInt64) | Calls Memset(value, valueSize, offset, System.Convert.ToUInt64(SO_BUFFER_SIZE_ALL)). |
![]() | Memset(IntPtr, UInt64, UInt64, UInt64) | This function sets the contents of (or a portion of) this buffer object to the specified value. |
![]() | SetMappedBufferObject | This function is used when the instance of buffer object is used to map a buffer. |
![]() | SetMappingAccessMode | Sets the mapping mode used for the mapping of a buffer object. |
![]() | SetMappingZoneInformation | Stores information about the mapping in order to know the subset of the data mapped in the buffer. |
![]() | SetSize | Sets the size in bytes of the buffer object. |
![]() | ToString | Returns a string that represents the current object. (Inherited from Object.) |
![]() | UnlockBuffer | Unlocks the buffer object. |
![]() | Unmap | Unmap a buffer mapped to a system memory address. |
![]() | Unmap(SoBufferObject) | Unmap this buffer from the specified buffer object. |
![]() | Unmap(SoCpuBufferObject) | Unmap the specified CPU buffer object. |
![]() | Unmap(SoGLBufferObject) | Unmap the specified GL buffer object. |
Name | Description | |
---|---|---|
![]() | IsDisposable | ISafeDisposable interface implementation.
(Inherited from SoDisposable.) |
This class provides management functions for CPU memory buffers.
See SoBufferObject for general information about buffer objects.
See SoBufferedShape for an example of storing vertices in a CPU buffer.
Load data into a buffer object from an array in memory:
float[] vertices = new float[9 * 3] { 1.0f, 0.5f,0.0f, 0.0f, 1.0f,0.0f, -1.0f,0.5f,0.0f, -1.0f,-1.0f,0.0f, 1.0f,-1.0f,0.0f, 1.0f,0.0f,0.0f, -1.0f,0.0f,0.0f, -1.0f,-1.5f,0.0f, 1.0f,-1.5f,0.0f }; SbNativeArray<float> vertArray = new SbNativeArray<float>(vertices); SoCpuBufferObject vertBuf = new SoCpuBufferObject( (SbNativeArray<byte>)vertArray );
Access data stored in a buffer object.
SbNativeArray<byte> data = (SbNativeArray<byte>)cpuBuffer.Map( SoBufferObject.AccessModes.READ_ONLY ); byte value = data[0]; . . . cpuBuffer.Unmap();