Home › Forums › Bug Reports and Feature Requests › “Append Scene” has it’s params in opposite order than shown in Dev Guide.
- This topic has 4 replies, 2 voices, and was last updated 4 years, 1 month ago by GLiFTeK.
-
AuthorPosts
-
2020-09-30 at 12:32 am #33587GLiFTeKCustomer
Hi,
k…
this has been driving me nuts for like.. 3 days.
I couldn’t understand why the parameters, callbacks etc included in the “Append Scene” method of the App class weren’t working. I was trying all sorts of things.the dev tools page for it reads as such:
.appendScene (url, loadCb, progressCb, errorCb, loadCameras, loadLights) : nullThen I went to look at the appendScene puzzle’s code it injects into the visual_logic.js file.
which is:
function appendScene(url, sceneName, loadCameras, loadLights, loadCb, progCb)
as opposed to the latter … where the params “loadCb, progCb” are switched with “sceneName, loadCameras”.
juuuuust thought i’d point this out….
WHICH ONE IS “RIGHT” MAAAN?
Visit the GLIFTEK Verge3D Plugins Store!
GLIFTEK.com for Plugin Documentation & LIVE DEMOS!
LIKE The GLIFTEK Facebook Page for updates!
Join the Verge 3D Discord Server!
plz share Discord link & on your signature!2020-09-30 at 6:12 am #33592Yuri KovelenovStaff2020-09-30 at 8:24 pm #33649GLiFTeKCustomerI think the docs are incorrect. We’ll fix this! sorry for the trouble.
Nope, both functions are correct. These are different functions, one of them belongs to App class, while the other is generated by the Puzzles editor.I see, my misunderstanding. so the app one is used as “app.appendScene()” and the puzzles one is used with what namespace? PL.appendScene()?
Visit the GLIFTEK Verge3D Plugins Store!
GLIFTEK.com for Plugin Documentation & LIVE DEMOS!
LIKE The GLIFTEK Facebook Page for updates!
Join the Verge 3D Discord Server!
plz share Discord link & on your signature!2020-10-01 at 9:48 am #33669Yuri KovelenovStaffand the puzzles one is used with what namespace? PL.appendScene()?
this one is a local function in visual_logic.js. I’m afraid it is not callable from outside. But there is no need to, as it is basically a wrapping over app.appendScene(). So I suggest you just use the latter.
2020-10-02 at 12:22 am #33710GLiFTeKCustomerOk,
That’s interesting. There’s always so much to learn.
I’ve been looking into the code behind certain puzzles, specifically the event puzzles, drag, move, animate etc…The quaternion matrix code in those are invaluable. Explains a lot that I’ve been curious and stumped on re the axis conversions needed to make THREE.js examples work in Verge etc.
This is important for me since I’ve been taking the clipping planes stencil code example and having the planes not be translatable (moving on axis) but rotating from the center to reveal the object in a raidial fashion.
The dat.GUI slider values have been performing with a serious gimble-lock “”snapping” where the majority of the rotation process will be very slow in approach to the 0 point, then snap quickly over it, then to slow again, which is not desirable.
Hopefully I can use the drag rotate puzzles’ and/or their code to remedy this.
Visit the GLIFTEK Verge3D Plugins Store!
GLIFTEK.com for Plugin Documentation & LIVE DEMOS!
LIKE The GLIFTEK Facebook Page for updates!
Join the Verge 3D Discord Server!
plz share Discord link & on your signature! -
AuthorPosts
- You must be logged in to reply to this topic.