Forum Replies Created
-
AuthorPosts
-
David DuperronCustomer
Ok, so there is no way I can achieve the same behavior as in Blender in V3D/Three using this kind of constraint (because inside Blender this issue does not occur!)?
I’ve got similar results when trying to use a mix of “set object direction” puzzle, and “limit rotation” constraint puzzles.David DuperronCustomerHo All!
I finally took the time to pack a small demo app that reproduces the issue with the Track To constraint.
You can play the App here:
Track To Issue
You need to raise the lower arm to the maximum (using the blue controllers), and then manipulate the second arm, you will see the issue near the top position and near the lower one: the pistons “flip” around their contrained axis, trying to maintain the Z-axis up I guess…
and the source blend file is attached to this post.
I can’t figure out why this constraint does not work once exported!
Any help would be greatly appreciated!
CheersDavid
David DuperronCustomerAlso check if your are moving in LOCAL or GLOBAL coordinates (by default the puzzle moves the object in local coordinates (or parent coordinates if your parented the moving object to another). If you want to move in global coordinates you need to tick the “world” option of the puzzles.
This, together with what @xeon describes above, is the key to getting what you expect when trying to move your objects with Verge3D.
Hope it will help!Cheers
David
David DuperronCustomerHi Xeon!
Very interesting feedback, thanks! It basically decribes what I was expecting… I think the “tab” approach, based on a common GLTF asset is probably the best solution so far.
I will definitely have to get prepared and think in depth about all the aspects you mention when it will come to that point.
Also curious to have any other feedback!
CheersDavid
David DuperronCustomerThere is still an issue when hovering a cube while orbiting the camera with this solution that causes a crash.
- This reply was modified 3 months, 1 week ago by David Duperron.
Attachments:
You must be logged in to view attached files.David DuperronCustomerHi!
As it is, you only evaluate your normal once when you “enter” one of your cubes, meaning that if you go from one face to another, WITHOUT exiting your cube (i.e. without triggering the “out” slot) your selected face will not change.
You have to put something in place to “constantly” evaluate your hovered face while hovering your cube, and update the position of your “selectedFace” object accordingly, and stop it as soon as you are not hovering your objects anymore…David DuperronCustomerHi Felix!
I guess you could use the “setup preloader” in the init tab of the puzzles, and its “on finish” slot to change the visibility of your elements (buttons) either based on their IDs if they have some or their class name.
Do you have a screenshot of your puzzles in the init tab?
CheersDavid
David DuperronCustomerHi!
You can give an id to the created annotation, so you then just need to create an event listener for a click on this element using the “on event click for elem id” HTML puzzle, that change the display property of your div from “none” to “block”.David DuperronCustomerHi Kdv, thanks for the advice.
In fact I spent some more time yesyterday on this, and finally discovered that this had to do with a material assignment in earlier steps of my scene loading (steps where I imported some objects and assigning them an already existing material – and these objetcs were importing and displayed correctly!).
However as soon as I invoked the append scene puzzle after that, the imports failed… I had to rework the material assignment part, and make sure the objects had some properties defined with the following script (like the computeTangents(), or a correct UVMap name):var mat = v3d.SceneUtils.getMaterialByName(appInstance, "NI_paint_vertex_color"); var object = PzLib.getObjectByName(addedPennantName); object.geometry.attributes.uv.name="UVMap"; object.castShadow = false; object.receiveShadow = false; object.geometry.computeTangents(); object.material = mat;
David DuperronCustomerHi @david-yanez!
It seems that I have a very similar issue today after updating to 4.7.1 version. I’m getting axactly the same error messagen and my imports fail.
Did you manage to find a solution to the above problem??2024-08-07 at 1:26 pm in reply to: Cannot read properties of undefined (reading ‘morphAttributes’) – after update to 4.7.1 #76457David DuperronCustomerAs soon as the
appendScene()
function is called after initial loading, this behaviour appears.
I use the appendScene() puzzle several times during the initial loading and it works correctly, no error message, and the objects are correctly imported.
But if I try to import objects later, it fails with this message…
Did anything change with this append scene puzzle?? Anyone has any clue??
Please Help!!David DuperronCustomerTo say it quick: it’s better to re-export everything (all gltf files) after the update, as I also realized that there was another issue with objects “morphattributes” that were not properly read on old gltf files. This is solved by re-exporting the gltf with the latest version.
EDIT: no it’s not solved… still have the morphattribute not defined issue… :(
- This reply was modified 3 months, 1 week ago by David Duperron.
David DuperronCustomerThanks! I think I got it.
I had some gltf imports in my main scene, and these gltf were not updated, which caused the errors.
This material issue is solved now!David DuperronCustomeryou just need to change 5 to some other value.
How can I add these generated submeshes to the objects
coding
I created a procedure to extract the names (not 3D objects!) of submeshes and add them to the list of measurable objects, and now everything is as expected!
Thanks for the help!
David DuperronCustomerOk Got it thanks!
Also it gave me the opportunity to tune your puzzle block to add a scale option fore these ends. Everything works fine now! -
AuthorPosts