/*************************************************************************** * Copyright (c) 2024 Microsoft Corporation * * This program and the accompanying materials are made available under the * terms of the MIT License which is available at * https://opensource.org/licenses/MIT. * * SPDX-License-Identifier: MIT **************************************************************************/ /**************************************************************************/ /**************************************************************************/ /** */ /** GUIX Component */ /** */ /** Binres Loader Management (Binres Loader) */ /** */ /**************************************************************************/ #define GX_SOURCE_CODE /* Include necessary system files. */ #include "gx_api.h" #include "gx_binres_loader.h" #include "gx_system.h" /**************************************************************************/ /* */ /* FUNCTION RELEASE */ /* */ /* _gxe_binres_font_load PORTABLE C */ /* 6.3.0 */ /* AUTHOR */ /* */ /* Ting Zhu, Microsoft Corporation */ /* */ /* DESCRIPTION */ /* */ /* This function checks for errors in binres font load function. */ /* */ /* INPUT */ /* */ /* root_address Pointer to the binary data */ /* memory */ /* font_index Resource index of the font */ /* to be loaded */ /* buffer Pointer to the buffer to */ /* store the loaded font */ /* buffer_size Size of the buffer. It will */ /* be overwritten with the */ /* required buffer size if the */ /* input buffer size is */ /* insufficient */ /* */ /* OUTPUT */ /* */ /* status Completion status */ /* */ /* CALLS */ /* */ /* _gx_binres_font_load The actual binres font load */ /* function */ /* */ /* CALLED BY */ /* */ /* Application Code */ /* */ /* RELEASE HISTORY */ /* */ /* DATE NAME DESCRIPTION */ /* */ /* 10-31-2023 Ting Zhu Initial Version 6.3.0 */ /* */ /**************************************************************************/ UINT _gxe_binres_font_load(GX_UBYTE *root_address, UINT font_index, GX_UBYTE *buffer, ULONG *buffer_size) { if (root_address == GX_NULL || buffer == GX_NULL || buffer_size == GX_NULL) { return GX_PTR_ERROR; } return _gx_binres_font_load(root_address, font_index, buffer, buffer_size); }