Forum

Activate new scene

29 July 2017 03:01
I am trying to activate a new scene with set_active() but the view is not updating. This scene has its own camera.

Do I need to copy and append the default camera into this scene?
31 October 2017 20:56
Hi AshyBlend, did you manage to activate a new scene? I do not either.
19 December 2017 11:44
same for me, have you found a right way ?
19 December 2017 22:19
I'm sorry I have not gotten it to work and nobody says anything. I do not know if it will be done with several canvases, if I get something I will comment on it here.
21 December 2017 10:55
Hello!
Currently set_active() method just selects the scene which then is used for some manipulations in internals. But unfortunately non-main scenes you can use only for rendering into a texture. Work on the API and Internals refactor is a large task for february and further releases. Scenes' API is the first here.
Alexander (Blend4Web Team)
twitter
21 December 2017 19:43
Thank you very much Alexander, we clarify the doubt.
26 December 2017 12:02
Hello, I managed to change the scene but I do not know if it is the most appropriate method.
1. Each scene is a .blend file exported to .json
2. To load the second scene I make a function
3. The function deletes the scenes loaded with the unload () method and loads the new
4. I call the function with the JSCallback node, (this is a personal preference to save me code), when I click on the scenario through a Select node.

If you see it well I can do a small tutorial.
I attach the project.
I would appreciate any help to improve this.
 
Please register or log in to leave a reply.