Search Results for

    Show / Hide Table of Contents

    Class MemStorage

    Represents a growing memory storage.

    Inheritance
    Object
    CVHandle
    MemStorage
    Namespace: OpenCV.Net
    Assembly: OpenCV.Net.dll
    Syntax
    public class MemStorage : CVHandle

    Constructors

    | Improve this Doc View Source

    MemStorage()

    Initializes a new instance of the MemStorage class.

    Declaration
    public MemStorage()
    | Improve this Doc View Source

    MemStorage(MemStorage)

    Initializes a new instance of the MemStorage class that will borrow its memory blocks from the specified parent storage.

    Declaration
    public MemStorage(MemStorage parent)
    Parameters
    Type Name Description
    MemStorage parent

    The parent memory storage.

    | Improve this Doc View Source

    MemStorage(Int32)

    Initializes a new instance of the MemStorage class with the specified blockSize.

    Declaration
    public MemStorage(int blockSize)
    Parameters
    Type Name Description
    Int32 blockSize

    The size of storage blocks, in bytes.

    Methods

    | Improve this Doc View Source

    Alloc(UIntPtr)

    Allocates a memory buffer in a storage block.

    Declaration
    public IntPtr Alloc(UIntPtr size)
    Parameters
    Type Name Description
    UIntPtr size

    The size of the memory block, in bytes.

    Returns
    Type Description
    IntPtr

    A pointer to the newly allocated memory block.

    | Improve this Doc View Source

    AllocString(String)

    Allocates a text string in a storage block.

    Declaration
    public IntPtr AllocString(string value)
    Parameters
    Type Name Description
    String value

    The string to be copied to the storage.

    Returns
    Type Description
    IntPtr

    The pointer to the copy of the string in storage.

    | Improve this Doc View Source

    Clear()

    Clears the memory storage. If the storage has a parent, the method returns all memory blocks to the parent.

    Declaration
    public void Clear()
    | Improve this Doc View Source

    ReleaseHandle()

    Executes the code required to free the native MemStorage handle.

    Declaration
    protected override bool ReleaseHandle()
    Returns
    Type Description
    Boolean

    true if the handle is released successfully; otherwise, in the event of a catastrophic failure, false.

    | Improve this Doc View Source

    RestorePosition(MemStoragePos)

    Restores the memory storage position.

    Declaration
    public void RestorePosition(MemStoragePos pos)
    Parameters
    Type Name Description
    MemStoragePos pos

    The new position of the storage top.

    | Improve this Doc View Source

    SavePosition()

    Saves the memory storage position.

    Declaration
    public MemStoragePos SavePosition()
    Returns
    Type Description
    MemStoragePos

    The current position of the storage top.

    • Improve this Doc
    • View Source
    In This Article
    Back to top Generated by DocFX