Giter VIP home page Giter VIP logo

Comments (8)

sohailshafii avatar sohailshafii commented on May 25, 2024

I assume that vkGetInstanceProcAddr needs to be called for vkCreateDebugReportCallbackEXT. The code in the example provided in android-test does not do that (unless that example was updated recently). I know how to use vkGetInstanceProcAddr in C++ so I'm wondering how I would do the same in Java.

from android-test.

Spasi avatar Spasi commented on May 25, 2024

Are you running HelloVulkan without any modifications? The VALIDATE flag at line 53 must be set to true in order to enable validation (enumerates the validation layers, enables the EXT_debug_report extension and calls vkCreateDebugReportCallbackEXT).

I assume that vkGetInstanceProcAddr needs to be called for vkCreateDebugReportCallbackEXT

No, the vkCreateDebugReportCallbackEXT function pointer is stored in the VkInstance passed as the first parameter.

from android-test.

sohailshafii avatar sohailshafii commented on May 25, 2024

The only changes I made to that Java file are that VALIDATE flag as you mentioned (it is true) and a log statement right before the call for vkCreateDebugReportCallbackEXT (for debugging purposes). I just ran it again and it's that line that causes the crash. The S7 I am running the program on has Android 7.0 on it and I don't know that would relate to this at all (i.e. maybe an older version of Android would have problems with this but I really doubt that).

The rest of the project is unchanged with the exception of:
-the armv7 jnilibs in main/jniLibs/armeabi-v7a (libVkLayer_core_validation.so, *_image.so, *_object_tracker.so, *_parameter_validation.so, *_swapchain.so, *_threading.so and *_unique_objects.so)
-the armv7 lwjgl aar file.
-Android studio forced me to update the gradle version in build.gradle to 2.3.1 (from 2.3.0-beta3)

from android-test.

Spasi avatar Spasi commented on May 25, 2024

I think the problem is related to dyncall, which is used to implement callbacks in LWJGL. The armeabi-v7a artifacts for dyncall where available on our S3 build bucket, but I noticed that there was no CI setup for that architecture. I can't remember when/how those binaries were build.

The CI and a fresh build is up now, please rebuild lwjgl3 for armeabi-v7a and try again. The build script should download new .a files under libs/android/armeabi-v7a, please verify that they're dated 5/5.

from android-test.

sohailshafii avatar sohailshafii commented on May 25, 2024

I've verified that the .a files are dated 5/5 after the recompilation. Unfortunately, the problem still persists.

from android-test.

Spasi avatar Spasi commented on May 25, 2024

Hey @sohailshafii,

The bug was indeed in LWJGL's callback implementation. It has been fixed with LWJGL/lwjgl3@26459f7 and the android branch has been updated to include the fix.

Please note that the validation layer binaries in the NDK are not up-to-date and have issues. In my tests, they reported errors that shouldn't happen and VK_LAYER_LUNARG_core_validation crashed after a while. It might be a good idea to build them from source.

Thanks for reporting this issue!

from android-test.

Spasi avatar Spasi commented on May 25, 2024

To clarify: the aarch64 validation layers worked fine, it was the armeabi-v7a binaries that were problematic for me (tested on Nvidia Shield and Nexus 6P), after fixing the callback bugs.

from android-test.

sohailshafii avatar sohailshafii commented on May 25, 2024

Thank you for your assistance and attention on this matter. I've verified that the debug callback now works in android-test and in my own program. When I get a chance I will recompile the validation layer binaries in the NDK.

from android-test.

Related Issues (9)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.