Skip to content

ITexture#

Renderer-friendly image representation.

Header:#include <AUI/Render/ITexture.h>
CMake:aui_link(my_target PUBLIC aui::views)

Examples#

examples/app/game_of_life/src/main.cpp

Game of Life — Game of Life implementation that uses advanced large dynamic data rendering techniques such as ITexture, AImage to be GPU friendly. The computation is performed in AThreadPool.

    }

private:
    _<Cells> mCells;
    _<ITexture> mTexture;

    void updateTexture() {
        if (!mTexture) {
            mTexture = ASurface::current()->getRenderingContext()->renderer().getNewTexture();
        }

Public Methods#

setImage#


virtual void ITexture::setImage(AImageView image)

Copies image to the texture image representation (i.e. to GPU memory).

Examples: