Hardware product and feature information

These query functions can be used to identify the product and its key features and to get VGLite driver information.

Enumerations for product and feature queries

This section describes enumerations used for product and feature queries.

vg_lite_feature_t enumeration

The following feature values may be queried for availability in compatible hardware. (expanded March 2023 to support additional hardware for driver V4)

Used in information function: vg_lite_query_feature.

vg_lite_feature_t string values

Description

gcFEATURE_BIT_VG_16PIXELS_ALIGN

Require 16 pixels aligned for the input pixel buffer

gcFEATURE_BIT_VG_24BIT

RGB888 or RGBA5658 formats support

gcFEATURE_BIT_VG_24BIT_PLANAR

24-bit planar format support

gcFEATURE_BIT_VG_AYUV_INPUT

AYUV input format support

gcFEATURE_BIT_VG_BORDER_CULLING

Border culling support

gcFEATURE_BIT_VG_COLOR_KEY

Color key support.

gcFEATURE_BIT_VG_COLOR_TRANSFORMATION

Color transform support.

gcFEATURE_BIT_VG_DEC_COMPRESS

DEC compression format output support

gcFEATURE_BIT_VG_DITHER

Dither support

gcFEATURE_BIT_VG_DOUBLE_IMAGE

Support two image source inputs

gcFEATURE_BIT_VG_FLEXA

FLEXA interface support

gcFEATURE_BIT_VG_GAMMA

Gamma support

gcFEATURE_BIT_VG_GAUSSIAN_BLUR

Gaussian blur sampling support

gcFEATURE_BIT_VG_GLOBAL_ALPHA

Global alpha support

gcFEATURE_BIT_VG_HW_PREMULTIPLY

HW supports alpha premultiply for image

gcFEATURE_BIT_VG_IM_DEC_INPUT

DEC compressed format input support

gcFEATURE_BIT_VG_IM_FASTCLEAR

Fast Clear support

gcFEATURE_BIT_VG_IM_INDEX_FORMAT

Index format support for image

gcFEATURE_BIT_VG_IM_INPUT

Blit and draw API support

gcFEATURE_BIT_VG_IM_REPEAT_REFLECT

Image repeat reflect mode support

gcFEATURE_BIT_VG_INDEX_ENDIAN

Index format endian support

gcFEATURE_BIT_VG_LINEAR_GRADIENT_EXT

Support for extended linear gradient capabilities

gcFEATURE_BIT_VG_LVGL_SUPPORT

LVGL blend mode support

gcFEATURE_BIT_VG_MASK

Mask support

gcFEATURE_BIT_VG_MIRROR

Mirror support

gcFEATURE_BIT_VG_NEW_BLEND_MODE

New blend mode DARKEN/LIGHTEN support

gcFEATURE_BIT_VG_NEW_IMAGE_INDEX

New CLUT image index support

gcFEATURE_BIT_VG_PARALLEL_PATHS

New parallel path HW support

gcFEATURE_BIT_VG_PE_CLEAR

Pixel engine clear support

gcFEATURE_BIT_VG_PIXEL_MATRIX

Pixel matrix support

gcFEATURE_BIT_VG_QUALITY_8X

8x anti-aliasing path support

gcFEATURE_BIT_VG_RADIAL_GRADIENT

Radial gradient support

gcFEATURE_BIT_VG_RECTANGLE_TILED_OUT

Rectangle tiled output support

gcFEATURE_BIT_VG_RGBA2_FORMAT

RGBA2222 format support

gcFEATURE_BIT_VG_RGBA8_ETC2_EAC

ETC2/EAC compressed image format support

gcFEATURE_BIT_VG_SCISSOR

Scissor support

gcFEATURE_BIT_VG_SRC_PREMULTIPLIED

Source image alpha premultiplied

gcFEATURE_BIT_VG_STENCIL

Stencil image mode support

gcFEATURE_BIT_VG_STRIPE_MODE

Stripe mode support

gcFEATURE_BIT_VG_TESSELLATION_TILED_OUT

Tessellation tiled output support

gcFEATURE_BIT_VG_USE_DST

Read destination pixel support

gcFEATURE_BIT_VG_YUV_INPUT

YUV input format support

gcFEATURE_BIT_VG_YUV_OUTPUT

YUV format output support

gcFEATURE_BIT_VG_YUV_TILED_INPUT

YUV tiled input format support

gcFEATURE_BIT_VG_YUY2_INPUT

YUY2 input format support

Parent topic:Enumerations for product and feature queries

Parent topic:Hardware product and feature information

Structures for product and feature queries

This section describes structures used for product and feature queries.

vg_lite_info_t structure

This structure is used to query VGLite driver information.

Used in function: vg_lite_get_info_t.

vg_lite_info_t member

Type

Description

api_version

vg_lite_uint32_t

VGLite API version

header_version

vg_lite_uint32_t

VGLite header version

release_version

vg_lite_uint32_t

VGLite driver release version

reserved

vg_lite_uint32_t

Reserved for future use

Parent topic:Structures for product and feature queries

Parent topic:Hardware product and feature information

Functions for product and feature queries

This section describes functions used for product and feature queries.

vg_lite_get_product_info

Description:

This function is used to identify the VGLite-compatible product.

Syntax:

uint32_t vg_lite_get_product_info (
       char            *name,
       uint32_t        *chip_id,
       uint32_t        *chip_rev
);

Parameters:

Name

Description

name

A character array to store the name of the chip.

chip_id

Stores an ID number for the chip.

chip_rev

Stores a revision number for the chip.

Parent topic:Functions for product and feature queries

vg_lite_get_info

Description:

This function is used to query the VGLite driver information.

Syntax:

vg_lite_error_t vg_lite_get_info (
    vg_lite_info_t             *info
);

Parameters:

Name

Description

info

Points to the VGLite driver information structure, which includes the API version, header version, and release version

Parent topic:Functions for product and feature queries

vg_lite_get_register

Description:

This function can be used to read a GPU AHB register value given the AHB byte address of a register. Refer to the appropriate Vivante GPU AHB register specification documents for register descriptions. The value range of AHB accessible addresses for VGLite cores is usually 0x0 to 0x1FF and 0xA00 to 0xA7F.

Syntax:

vg_lite_error_t vg_lite_get_register (
       vg_lite_uint32_t      address,
       vg_lite_uint32_t      *result
);

Parameters:

Name

Description

address

Byte Address of the register which value you want.

*result

The registers value.

Parent topic:Functions for product and feature queries

vg_lite_query_feature

Description:

This function is used to query if a specific feature is available.

Syntax:

vg_lite_uint32_t vg_lite_query_feature (
    vg_lite_feature_t          feature
);

Parameters:

Name

Description

feature

Feature to be queried, as detailed in enum vg_lite_feature_t

Returns:

The feature is either not supported (0) or supported (1).

Parent topic:Functions for product and feature queries

vg_lite_get_mem_size

Description:

This function queries whether there is any remaining allocated contiguous video memory. (available from June 2020)

Syntax:

vg_lite_error_t vg_lite_get_mem_size(
    vg_lite_uint32_t            *size
);

Parameters:

Name

Description

size

Pointer to the remaining allocated contiguous video memory.

Returns:

Returns VG_LITE_SUCCESS if the query is successful and memory is available. Returns VG_LITE_NO_CONTEXT if the driver is not initialized or there is no available memory.

Parent topic:Functions for product and feature queries

Parent topic:Hardware product and feature information