Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove macros Vulkan shader definitions #3203

Open
louwers opened this issue Feb 8, 2025 · 0 comments · May be fixed by #3210
Open

Remove macros Vulkan shader definitions #3203

louwers opened this issue Feb 8, 2025 · 0 comments · May be fixed by #3210
Assignees
Labels
build Related to build, configuration or CI/CD Vulkan

Comments

@louwers
Copy link
Collaborator

louwers commented Feb 8, 2025

I am getting compile errors related to the shaders in include/mbgl/shaders/vulkan

  /home/bart/maplibre-native/include/mbgl/shaders/vulkan/background.hpp:10:5: error: unterminated raw string
     10 |     R"(
        |     ^
  /home/bart/maplibre-native/include/mbgl/shaders/vulkan/background.hpp:15:2: warning: missing terminating " character
     15 | )"
        |  ^
  /home/bart/maplibre-native/include/mbgl/shaders/vulkan/background.hpp:15:2: error: missing terminating " character
  /home/bart/maplibre-native/include/mbgl/shaders/vulkan/background.hpp:10:5: error: stray 'R' in program
     10 |     R"(
        |     ^~~
  /home/bart/maplibre-native/include/mbgl/shaders/vulkan/background.hpp:10:5: note: in definition of macro 'BACKGROUND_SHADER_COMMON'
     10 |     R"(
        |     ^~~
  /home/bart/maplibre-native/include/mbgl/shaders/vulkan/background.hpp:10:5: error: stray 'R' in program
     10 |     R"(
        |     ^~~
  /home/bart/maplibre-native/include/mbgl/shaders/vulkan/background.hpp:10:5: note: in definition of macro 'BACKGROUND_SHADER_COMMON'
     10 |     R"(
        |     ^~~
  /home/bart/maplibre-native/include/mbgl/shaders/vulkan/background.hpp:10:5: error: stray 'R' in program
     10 |     R"(
        |     ^~~
  /home/bart/maplibre-native/include/mbgl/shaders/vulkan/background.hpp:10:5: note: in definition of macro 'BACKGROUND_SHADER_COMMON'
     10 |     R"(
        |     ^~~
  /home/bart/maplibre-native/include/mbgl/shaders/vulkan/background.hpp:10:5: error: stray 'R' in program
     10 |     R"(
        |     ^~~
  /home/bart/maplibre-native/include/mbgl/shaders/vulkan/background.hpp:10:5: note: in definition of macro 'BACKGROUND_SHADER_COMMON'
     10 |     R"(
        |     ^~~
  /home/bart/maplibre-native/include/mbgl/shaders/vulkan/background.hpp:15:1: error: expected unqualified-id before ')' token
     15 | )"

We should refactor this code so that we do not have to use #define.

@louwers louwers added build Related to build, configuration or CI/CD Vulkan labels Feb 8, 2025
@adrian-cojocaru adrian-cojocaru linked a pull request Feb 12, 2025 that will close this issue
@adrian-cojocaru adrian-cojocaru self-assigned this Feb 12, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
build Related to build, configuration or CI/CD Vulkan
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants