ash icon indicating copy to clipboard operation
ash copied to clipboard

Inquiry: OpenHarmony Surface Supports

Open Hanfeng23333 opened this issue 2 months ago • 5 comments

Are there any plans to support OpenHarmony? I'm interested in using Ash for graphics development on OHOS, but it seems official support might not be available yet. Could you share if this is under consideration or if there are known technical hurdles? Any guidance on how to contribute towards this would be appreciated.

As far as I know, Rust has already supported the development on OpenHarmony:

> rustup target list | findstr "ohos"
aarch64-unknown-linux-ohos
armv7-unknown-linux-ohos
x86_64-unknown-linux-ohos

Also, Vulkan has offically supported OpenHarmony. For example, Surface (instance extension). Additionally, raw-window-handle includes the window handle and display handle on OpenHarmony.

In a nutshell, now I have to use the Cpp rather than Rust, but I personally thought Rust is much better than Cpp in many aspects.... :(

Hanfeng23333 avatar Nov 05 '25 08:11 Hanfeng23333

We have an extension wrapper and ash-window support in the pipeline, but the extension was only added in Vulkan 1.4.316 while our generated code is currently """stuck""" at https://github.com/ash-rs/ash/pull/951.

It will come at some point!

MarijnS95 avatar Nov 05 '25 08:11 MarijnS95

@Hanfeng23333 would you be able to test https://github.com/ash-rs/ash/pull/1016? There is no need to fetch the submodule, which currently points to a local patch to fix upstream vk.xml issues.

MarijnS95 avatar Nov 05 '25 10:11 MarijnS95

@MarijnS95 Wow, that's extremely fast. Sure thing, but...I just deleted all my rust crates as I Chose cpp. I'll give it a try, but it may take a long time. Anyway, thank you Ash team very much :D

Hanfeng23333 avatar Nov 05 '25 11:11 Hanfeng23333

@MarijnS95 I'm sorry to bother you, but where did the push_next in InstanceCreateInfo go? My IDE hints this:

Method `push_next` not found in the current scope for type `InstanceCreateInfo`

I'm not sure whether this is correct:

create_info.p_next = &debug_info as *const vk::DebugUtilsMessengerCreateInfoEXT as *const _;

Hanfeng23333 avatar Nov 06 '25 02:11 Hanfeng23333

It's become a method of the TaggedStructure trait. You'll need to import that trait to use it.

Ralith avatar Nov 07 '25 02:11 Ralith