Does emscripten support externref reference types for holding opaque handles to JS objects in C++? If not, any idea when?
--
You received this message because you are subscribed to the Google Groups "emscripten-discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email to emscripten-disc...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/emscripten-discuss/7f6178fa-bd05-4f65-aa7c-9e5a405bf851n%40googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/emscripten-discuss/68c9b121-f12f-44fa-a91c-2a8b73d2f456n%40googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/emscripten-discuss/57b1491a-7025-4967-a66e-ebcbf10f5e2bn%40googlegroups.com.
Do we have anyway to write hand-written assembly code along with emscripten? And is it possible to return that externref from wasm code into emscripten world?
To view this discussion on the web visit https://groups.google.com/d/msgid/emscripten-discuss/ed80516b-e1ac-4ba1-a535-acd1f632a2f5n%40googlegroups.com.
Thank you very much. Are there any public discussion or roadmap to add EM_ASM_REF into emscripten?
To view this discussion on the web visit https://groups.google.com/d/msgid/emscripten-discuss/e4853c85-e981-4fa4-a6d8-f64a7ad5c048n%40googlegroups.com.
I am actually using emscripten from unity and I mainly use C# code from unity side. But there are tons of 3rd party library and SDK that written with assumption that we will only use JavaScript. It then need us to construct javascript object in javascript and pass javascript object reference all over the places. For example, the google's firebase SDK that we need to construct it special object type to work with its complex servicesIt then become very frustrating to wrap everything in an API with mergeInto library that kept growing for everythings related to js objectWith just the ability to pass externref into C# as IntPtr or int64 and so C# can pass it to another js API after it was done everything in C# is just what we really need, everything would come together as a flow of reference. The chain of bottleneck is that unity rely on emscripten to fully support externref first then it could start support it in some future. So the sluggish are stacking up
To view this discussion on the web visit https://groups.google.com/d/msgid/emscripten-discuss/1018024e-ab04-46c1-bb22-f73183601976n%40googlegroups.com.
I don't actually know which things unity would use to hold the value of externref, just guessing it would be IntPtr. But by anything it require that emscripten can officially define externref first anyway
To view this discussion on the web visit https://groups.google.com/d/msgid/emscripten-discuss/8cb8c47e-fc87-4429-8dcd-1057c6f090f6n%40googlegroups.com.
I am not sure how limited it is but there are many situation that we just need a value to pass object from one function to another immediately in the same flowBy the way, which the handle would be returned as EM_ASM_INT or EM_ASM_PTR ?
To view this discussion on the web visit https://groups.google.com/d/msgid/emscripten-discuss/82954f49-c753-4c67-8de7-e5524f1e7f0en%40googlegroups.com.