arcore-android-sdk icon indicating copy to clipboard operation
arcore-android-sdk copied to clipboard

Feature Request: Support for Vulkan (VK_KHR_external_memory)

Open DerRM opened this issue 7 years ago • 19 comments

Are there any plans to support VK_KHR_external_memory or something similar with ArSession_setCameraTextureName? It would be great to use Vulkan as a render backend but as far as I understood you only can either use GLES or Vulkan for the same surface you render to.

DerRM avatar Mar 23 '18 13:03 DerRM

While VK_KHR_external_memory solves half the problem, at the moment Android has no equivalent to SurfaceTexture that works with Vulkan.

inio avatar Mar 23 '18 15:03 inio

Are there any plans for supporting a Vulkan enabled SurfaceTexture in a future Android release?

DerRM avatar Mar 24 '18 08:03 DerRM

I'm not on the AR team, but can answer the question. Internally, SurfaceTexture is a mutable texture: the same texture ID is used in multiple calls to glEGLImageTargetTexture2DOES to point the texture at different native buffers (gralloc buffers). Mutable textures do not exist in Vulkan and therefore it's not possible to add Vulkan support to SurfaceTexture. The Vulkan-compatible equivalent of SurfaceTexture is AImageReader, but using it with camera frames requires Vulkan 1.1 and the extension VK_ANDROID_external_memory_android_hardware_buffer, which is not supported by any GPU drivers yet.

tweenk avatar Mar 28 '18 21:03 tweenk

@tweenk Thanks for the info!

inio avatar Mar 28 '18 21:03 inio

I want to use ARCore with Vulkan, too. Any updates?

kidapu avatar Sep 04 '20 08:09 kidapu

Any updates on this?

laim2003 avatar Nov 24 '20 12:11 laim2003

No updates on this so far, sorry.

devbridie avatar Nov 24 '20 14:11 devbridie

Can't believe this is still an issue! I need Vulcan with Unity AR foundation for performance reasons! I hope Google supports Vulcan soon!

uprealdigital avatar Feb 19 '21 21:02 uprealdigital

Same situation here, any news?

blasco avatar Oct 18 '21 06:10 blasco

2 years have passed, just a little update to say why it's still not supported would be nice :)

ROBYER1 avatar Mar 28 '22 08:03 ROBYER1

Is this ever going to happen? I'm finding this to be very limiting. It has been 4 years.

sam1am avatar Apr 02 '22 21:04 sam1am

Still waiting for vulkan. It is now one of the standard render APIs, it is the default in Unity now (where a lot of AR apps/games are made) and it hinders some features in Unity (such as VFX graph)

smitdylan2001 avatar Apr 20 '22 20:04 smitdylan2001

Same here! We need Vulkan support!

rtrn1337 avatar Aug 30 '22 14:08 rtrn1337

We also need Vulkan support! Particle System instead of VFX graph is NOT a high end solution in Unity!

nara6500 avatar Aug 31 '22 12:08 nara6500

It would be great if ArCore could have Vulkan support. Please consider adding it.

speedym avatar Sep 27 '22 14:09 speedym

Any way to share the texture now?

axilesoft avatar Nov 05 '22 15:11 axilesoft

Let me be the first voice calling for this in 2023. Happy New Year 🎊

olokobayusuf avatar Jan 07 '23 22:01 olokobayusuf

Is there any update on that ?

The comment from @tweenk in 2018, referred to Vulkan 1.1 requirement is now fully addressed in 2023, as there is 77% of Android devices now supporting this version: https://developer.android.com/about/dashboards

The fact that all Unity apps using ARCore/ARFoundation have been limited for so many years on using an API which is getting old, not improved anymore is concerning, and really limit what can be done in term of quality/delivery on the app side.

ptc-rgrasset avatar Apr 14 '23 09:04 ptc-rgrasset

Glad to see that finally added in 1.37 !

ptc-rgrasset avatar May 11 '23 08:05 ptc-rgrasset