FEDERAÇÃO SIGMA

Federação das sociedades independentes de cyber ciência, tecnologia e engenharia, cybercultistas e tecnocráticas, da América Latina.

afxRaster

afxRaster

In Qwadro, what you know as being textures/images in other APIs is called raster, a special type of buffer which handles formatted image data stored in VRAM. Qwadro rasters are row-major unidimensional, bidimensional or tridimensional matrices of cells. Raster cells are memory-addressable pixels/texels (or pixel block) arranged laterally in rows/scanlines, vertically in columns of rows/scanlines, and layers (or slices, when 3D), for each level of detail.

Rasters are used for various purposes across Qwadro, mainly for video bufferization and sampling (texturing). Due to its VRAM-backed storage, any manipulation require command submission into a draw execution queue and careful synchronization while waiting for queue completation.

Basically, afxRaster is for Qwadro what textures/images are for OpenGL, Vulkan (VkImage) and Direct3D.

API

To get the draw context a raster relies on, call:

AVX afxDrawContext AfxGetRasterContext(afxRaster ras);

To get the number of bits per pixel (BPP) for a raster, call:

AVX afxNat AfxGetRasterBpp(afxRaster ras);

To get the number of downscaled samples (mipmaps) of a raster, call:

AVX afxNat AfxCountRasterLods(afxRaster ras);

To get the number of layers of a raster, call:

AVX afxNat AfxCountRasterLayers(afxRaster ras);

To get the number of upscaled samples of a raster, call:

AVX afxNat AfxCountRasterSamples(afxRaster ras);

To get the usage bitmask for a raster, call:

AVX afxRasterUsage AfxGetRasterUsage(afxRaster ras);

To get the flags bitmask of a raster, call:

AVX afxRasterFlags AfxGetRasterFlags(afxRaster ras);

To get the cell/texel/pixel format of a raster data, call:

AVX afxPixelFormat AfxGetRasterFormat(afxRaster ras);

To get the extent for computed for a given LOD of a raster, call:

AVX void AfxGetRasterExtent(afxRaster ras, afxNat lodIdx, afxWhd whd);

 

Auto-translate »