MackeyK24

[SOLVED] - Scene Level Metadata

Recommended Posts

This request is more for the BabylonJS maintainers like David.

I talked you guys into letting me add node.metadata which is WORKING GREAT... SO GREAT that i really need (and hope you can see the same value as well) of having

the same serializable metadata at the scene level. So i am asking SOMEONE to please:

 @serialize()
 public metadata:any = null;

to babylon.scene.ts so it can be used exactly like node.metedata.

Right now if i want to store SCENE level metadata i gotta put a DUMMY mesh (or node) into the scene and search the all the scene.meshes to find some node.metadata that has been aliased to be used as scene level data. That kinda sucks (Note: I DONT MEAN BABYLONJS sucks in any way... remember... I luv you guys and the very concept of babylonjs :) ). Just not a clean way to store and retrieve any scene level metadata.

Adding scene.metadata would give that same 'automatic de-serialization' of the built in babylon parsing framework. We will end up with a real javascript object scene.metadata JUST LIKE node.metadata

Please REALLY think about it... I would luv to clean up some of my BabylonJS loader code and having to look thru the scene nodes to grab a dummy node with my scene level metadata, really bugs my OCD

Thanks again for even thinking about it :)

 

Share this post


Link to post
Share on other sites

bumpity bump bump.  :)  As best I can tell (not very)... this is quite an acceptable (and good) idea.

Ever do github Pull Requests, Mackey?  Fork the BJS source repository... to your personal repository, edit the .ts file, and submit a pull request.  BJS big dogs will look it over, and determine if it is wise.  Then they will commit/merge it, and it will be active after the next build.

You can do a forum search and docs search for "contributing"... should find more info.  Sorry for the slow replies.  Hopefully, core coders will comment, soon... and they are more intelligent and informed... than I.  Thanks for the contribution/suggestion.  I like it... and I like your great attitude, too.

Share this post


Link to post
Share on other sites

I didn't see any other @serializable properties on the scene like the node... Didn't know if the scene runs thru the same de-serialization process as the node. SO i hoping someone with a little bit more knowledge on how the scene deserializes to help me out a bit :)

 

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...

  • Recently Browsing   0 members

    No registered users viewing this page.