Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Problems recording GPU on linux #186

@qbojj

Description

@qbojj

I build optick with OPTICK_USE_VULKAN flag but the CMakeLists.txt does not set OPTICK_ENABLE_GPU_VULKAN=1 (only OPTICK_ENABLE_GPU=1).

When the flag is not set CMakeLists sets OPTICK_ENABLE_GPU_VULKAN=0, but not the other way around, and because in optick.config.h OPTICK_ENABLE_GPU_VULKAN is always set to 0 when it is not __WIN32__ and OPTICK_ENABLE_GPU_VULKAN is not defined, so vulkan is never enabled on platforms other than windows.

The quickest fix (I don't know if it fully works, only tested on my machine and configuration) is to add
target_compile_definitions(OptickCore PRIVATE OPTICK_ENABLE_GPU_VULKAN=0) inside if(OPTICK_USE_VULKAN)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions