Class NativeImageQueue

    Definition

    Namespace:
    Tizen.NUI
    Assembly:
    Tizen.NUI.dll

    NativeImageQueue is a class for displaying an image resource using queue.

    public class NativeImageQueue : NativeImageInterface
    Inheritance
    object
    Disposable
    RefObject
    NativeImageInterface
    NativeImageQueue
    Derived
    TbmQueueImageSource
    TbmQueueImageSource
    Examples
    NativeImageQueue queue = new NativeImageQueue(width, height, ColorFormat.BGRA8888);
    if(queue.CanDequeueBuffer())
    {
      var buffer = queue.DequeueBuffer(ref bufferWidth, ref bufferHeight, ref bufferStride);
    
      /* Use buffer */
    
      queue.EnqueueBuffer(buffer);
    }
    
    ImageUrl imageUrl = queue.GenerateUrl();
    ImageView view = new ImageView(imageUrl.ToString());

    Constructors

    View Source

    NativeImageQueue(uint, uint, uint, ColorFormat)

    Creates an initialized NativeImageQueue with queue count and size and color format.

    Declaration
    public NativeImageQueue(uint queueCount, uint width, uint height, NativeImageQueue.ColorFormat colorFormat)
    Parameters
    Type Name Description
    uint queueCount

    The number of queue count. Use system default value if it is 0.

    uint width

    A Width of queue.

    uint height

    A Height of queue.

    NativeImageQueue.ColorFormat colorFormat

    A color format of queue.

    View Source

    NativeImageQueue(uint, uint, ColorFormat)

    Creates an initialized NativeImageQueue with size and color format.

    Declaration
    public NativeImageQueue(uint width, uint height, NativeImageQueue.ColorFormat colorFormat)
    Parameters
    Type Name Description
    uint width

    A Width of queue.

    uint height

    A Height of queue.

    NativeImageQueue.ColorFormat colorFormat

    A color format of queue.

    Methods

    View Source

    CanDequeueBuffer()

    Checks if the buffer can be got from the queue.

    Declaration
    public bool CanDequeueBuffer()
    Returns
    Type Description
    bool

    True if the buffer can be got from the queue.

    View Source

    DequeueBuffer(ref int, ref int, ref int)

    Dequeue buffer from the queue.

    Declaration
    public IntPtr DequeueBuffer(ref int width, ref int height, ref int stride)
    Parameters
    Type Name Description
    int width

    A reference to the buffer's width.

    int height

    A reference to the buffer's height.

    int stride

    A reference to the buffer's stride.

    Returns
    Type Description
    IntPtr

    A handle of buffer.

    View Source

    EnqueueBuffer(IntPtr)

    Enqueue buffer to the queue.

    Declaration
    public bool EnqueueBuffer(IntPtr buffer)
    Parameters
    Type Name Description
    IntPtr buffer

    A Handle of buffer to be enqueued.

    Returns
    Type Description
    bool

    True if success.

    View Source

    GenerateUrl()

    Generate Url from native image queue.

    Declaration
    public override ImageUrl GenerateUrl()
    Returns
    Type Description
    ImageUrl

    The ImageUrl of NativeImageQueue.

    Overrides
    NativeImageInterface.GenerateUrl()
    Remarks

    This API should not be called at worker thread.

    View Source

    GenerateUrl(bool)

    Generate Url from native image queue with pre-multiplied by alpha information.

    Declaration
    public override ImageUrl GenerateUrl(bool preMultiplied)
    Parameters
    Type Name Description
    bool preMultiplied

    The raw pixel data pre-multiplied by alpha.

    Returns
    Type Description
    ImageUrl

    The ImageUrl of NativeImageQueue.

    Overrides
    NativeImageInterface.GenerateUrl(bool)
    Remarks

    This API should not be called at worker thread.

    View Source

    GetQueueCount()

    The number of queue.

    Declaration
    public uint GetQueueCount()
    Returns
    Type Description
    uint
    Remarks

    Hidden API: Only for inhouse or developing usage. The behavior and interface can be changed anytime.

    View Source

    ReleaseSwigCPtr(HandleRef)

    Declaration
    protected override void ReleaseSwigCPtr(System.Runtime.InteropServices.HandleRef swigCPtr)
    Parameters
    Type Name Description
    System.Runtime.InteropServices.HandleRef swigCPtr
    Overrides
    NativeImageInterface.ReleaseSwigCPtr(System.Runtime.InteropServices.HandleRef)
    Examples
    NativeImageQueue queue = new NativeImageQueue(width, height, ColorFormat.BGRA8888);
    if(queue.CanDequeueBuffer())
    {
      var buffer = queue.DequeueBuffer(ref bufferWidth, ref bufferHeight, ref bufferStride);
    
      /* Use buffer */
    
      queue.EnqueueBuffer(buffer);
    }
    
    ImageUrl imageUrl = queue.GenerateUrl();
    ImageView view = new ImageView(imageUrl.ToString());

    Extension Methods

    EXamlExtensions.LoadFromEXamlByRelativePath<T>(T, string)
    Extensions.LoadFromXaml<TXaml>(TXaml, string)
    Extensions.LoadFromXaml<TXaml>(TXaml, Type)
    Extensions.LoadFromXamlFile<TXaml>(TXaml, string)
    • View Source
    Back to top Copyright © 2016-2025 Samsung
    Generated by DocFX