rfw2d
    Preparing search index...

    Class ArrayBufferCache

    Keeps a cache of ArrayBuffers. Buffers are sized to a power of two. Only one buffer exists for any size at a time. It does not create new buffers for the same size.

    Index

    Constructors

    Methods

    Constructors

    Methods

    • Get a buffer for the given size.

      Parameters

      • bytes: number

        Minimum number of bytes. Will be rounded up to the next highest power of two

      Returns ArrayBuffer

      The ArrayBuffer for the rounded size