[Full Release] EditableMesh Batching APIs & Parallel Queries

I need to find the right place to post this in more detail but I’m throwing it here incase it’s relevant or if there’s some neat info that gets shared :smiley:

Below is a microprofile showing a client process in which a delayed thread on heartbeat is invoking a yielding author job i.e writing batches of info into an editablemesh → createdatamodelasync when the batch is ready (AsyncTask).

Being able to batch these calls will be great because cutting down on that serial editablemesh authoring phase on a client esp one with perf limitations can let us do some nifty stuff, in this case its the client lazily writing its own baked copy of the visuals of a player avatar in our game (better perf via updateBones, compressed buffer + client gen=lower bandwidth), batching speedups a shown in the graphs = way less frame time on the client authoring = much better which is exciting.

I wanted to mention/ask about this call i have hovered in the image, it has a strange title but it’s CreateMeshPartAsync. unlike CreateDataModelContentAsync which works in an async task, calling CreateMeshPartAsync == 20ms lockup on the main thread, regardless of the size of what you put in and there’s no way to get it off the serial thread.

Unsure if this is a bug or intentional (feels possibly like its not intentional given Async in the method name), but if this method is able to move to being truly async i.e not block the main thread, it + batching apis + datamodelcontent become much more desirable to use on the client, since until then you have to trade off the bandwidth reduction&budgeting wins against this hangup you cause by trying to create the meshpart.

Will also mention in this case we’re going for skinned meshes intended purely for visuals, so we basically just want something to render and we don’t mind if it’s slow since it’s not intended to be on-demand.

I can’t find much information about this method or why it holds up the main thread, so would love any insight i.e not sure if its a bug report thing because it says async but runs very-not-async, or is it a feature request i.e it needs to be serial but an async-friendly one for certain cases could exist?

1 Like

Hi, thanks for the report. I have done some investigation of latency around converting EditableMesh into a MeshPart backed by DataModelContent, but I didn’t see the same kind of blocking the main thread as you’re showing.

Would you be able to send a repro file? I can DM you, or you can file a separate report if that’s more convenient for you.

1 Like

Yeah, shoot me a DM and i can send everything we have!

1 Like

can we get a new function that can blur EditableImages? Bluring is already performance heavy as is and having to do it manually pixel by pixel on the cpu is extremely slow

Could we get an expected date of release by now?

The tech seems to be working well in studio beta for intensive workloads.

The sooner the better honestly :folded_hands:

2 Likes

It works amazingly please, we really need this released for our custom voxel engine sandbox! <3

2 Likes

We’re excited to announce that the EditableMesh batching APIs are now available in published experiences. Thank you to everyone for your testing and feedback!

Please continue providing bug reports, feedback and sharing what you have made in this dev forum post.

14 Likes

Why doesn’t my child have access to this API. He passed all the checks required by Roblox. Parental controls are enabled on his account, and I, as his parent, have also passed all the checks. However, there is no access either from under his account or from the group. Yes, he is not 13, but as a parent I have confirmed my responsibility. It doesn’t make any sense.

Thank you so much! This helped my Roblox game so much performance wise!

1 Like

Oh my god this is so huge! Thank you!

Without it my voxel game is getting avg like 40 fps, i will share the improvement once we benchmark

1 Like

Was waiting for this to drop, I made some nice stylized and performant water for my games!

8 Likes

Wow - that is amazing - well done !!
I was thinking a few days ago - when this will be possible.
Well.. it is already. Thanks for sharing.

Care to share a little - “How to” hints ?

Hey L3, I’m experiencing a similar issue with ~21ms lockup when using CreateMeshPartAsync (that’s mostly idle waiting, not work) that also blocks to main thread. Like in Pava’s experience, it doesn’t seem to depend on the complexity of the mesh being generated. Wondering if you were able to reproduce this/if any progress has been made. Someone made a bug report already (that I replied to), so I don’t want to clog up bug reports, but if you DM me I can send you a repro + more info about the issue. I’d DM you, but I don’t see the option to do so

I have been looking into the bug report, which was very helpful. It always saves a ton of time to have a reliable repro. I believe I have a fix, will respond to that bug report thread when the flag has been enabled.

Also, no worries about clogging up the bug reports - if it’s the same issue, it’s very helpful to have further discussion about it in the same thread, from the same dev and other devs. Especially with complicated bugs, other reports and details are always appreciated. And, that way everyone who was running into it can easily get notified about it when a likely fix is in.

2 Likes