Skip to content

CF_AppOptionFlagBits

Category: app
GitHub: cute_app.h


Various options to control how the application starts up, such as fullscreen, or selecting a graphics backend.

Values

Enum Description
APP_OPTIONS_NO_GFX_BIT Does not initialize any graphics backend at all (for servers or headless mode).
APP_OPTIONS_FULLSCREEN_BIT Starts the application in borderless full-screen mode.
APP_OPTIONS_RESIZABLE_BIT Allows the window to be resized.
APP_OPTIONS_HIDDEN_BIT Starts the application with the window hidden.
APP_OPTIONS_WINDOW_POS_CENTERED_BIT Starts the application with the window centered on the screen. Does not affect any later adjustments to window size/position.
APP_OPTIONS_FILE_SYSTEM_DONT_DEFAULT_MOUNT_BIT Disables automatically mounting the folder the executable runs from to "/". See cf_fs_mount for more details.
APP_OPTIONS_NO_AUDIO_BIT Starts the application with no audio.
APP_OPTIONS_GFX_D3D11_BIT Starts the application with a D3D11 backend.
APP_OPTIONS_GFX_D3D12_BIT Starts the application with a D3D12 backend.
APP_OPTIONS_GFX_METAL_BIT Starts the application with a Metal backend.
APP_OPTIONS_GFX_VULKAN_BIT Starts the application with a Vulkan backend.
APP_OPTIONS_GFX_DEBUG_BIT Starts the application with a debug mode graphics context.

Code Example

Creating a basic window and immediately destroying it.

#include <cute.h>
using namespace cute;

int main(int argc, const char argv)
{
    app_make("Fancy Window Title", 0, 0, 0, 640, 480, CF_APP_OPTIONS_WINDOW_POS_CENTERED_BIT, argv[0]);
    app_destroy();
    return 0;
}

Remarks

The app_options parameter of cf_make_app is a bitmask flag. Simply take the APP_OPTIONS_ flags listed above and OR them together.

cf_destroy_app
cf_make_app