Q3D V-2.4 [3D Physics + Skeletal Animation UPDATE]

Post your completed addons to share with the community

Post » Mon Apr 10, 2017 1:49 pm

QuaziGNRLnose wrote:@tunepunk

Nice!

3D is pretty taxing for mobile, but the best way to get increased performance is to avoid bone based animations and use morph targets (these run almost entirely in shaders so they can be quite fast), and to cap the resolution to something lower than the native screen resolution (in Q3D Master) since mobile GPUs lack the performance to keep up.


For anyone who is interested, here is a modified version of the morph animation test. I got rid of the 5 point lights, and turned shadows off for the directional light.

https://dl.dropboxusercontent.com/u/55106174/morphanimationtest/index.html

Here is the .capx for the test:

https://dl.dropboxusercontent.com/u/55106174/morphanimationtest.capx

You can tap the text to get rid of models one at a time until the framerate becomes acceptable on your device. On a 2-year-old iPhone 6, I can have 25 animated models onscreen at 60 fps. On a Nexus 5, I can run about 4 animated models at an acceptable framerate.
Last edited by cjbruce on Mon Apr 10, 2017 4:19 pm, edited 1 time in total.
www.simbucket.com - HTML5 Science Simulations / https://www.airconsole.com/#!play=com.n ... obotrumble - Robot Rumble on AirConsole
B
52
S
17
G
26
Posts: 436
Reputation: 18,092

Post » Mon Apr 10, 2017 2:22 pm

@cjbruce I used morph animations instead directly, I havn't tried bone animations yet.

To convert bone animations to morph anim, i think best way is to bake the animations. It's an option in the exporter. (But I think you can bake it in Maya as well). but I haven't played around with this. I didn't do much preparation at all in Maya, just checked the export options. Then check the json file so everything looks okay. You don't need a lot of keyframes, since animations are interpolated in Q3D. I'm just using 6 frame walking animation for example.
Follow my progress on Twitter
or in this thread Archer Devlog
B
42
S
18
G
19
Posts: 1,060
Reputation: 14,054

Post » Thu Apr 13, 2017 3:55 pm

@QuaziGNRLnose Is it possible to load a three.js file containing multiple objects? And can you assign textures to each individual one? I was thinking of using https://threejs.org/editor/ to create the levels, and then just import the levels directly to Q3D. Only dynamic objects i would place in C2.
Follow my progress on Twitter
or in this thread Archer Devlog
B
42
S
18
G
19
Posts: 1,060
Reputation: 14,054

Post » Sun Apr 16, 2017 11:33 am

@QuaziGNRLnose

I've been using Q3D without problems for about 6 months now, but this morning when I exported a project, it wouldn't run. Preview works just fine.

Here is the error:

Image

Here is the c2runtime.js:

Image

I am using OIMO physics, and this is a new project.

Any ideas?
www.simbucket.com - HTML5 Science Simulations / https://www.airconsole.com/#!play=com.n ... obotrumble - Robot Rumble on AirConsole
B
52
S
17
G
26
Posts: 436
Reputation: 18,092

Post » Sun Apr 16, 2017 8:59 pm

cjbruce wrote:@QuaziGNRLnose

I've been using Q3D without problems for about 6 months now, but this morning when I exported a project, it wouldn't run. Preview works just fine.

Here is the error:

Image

Here is the c2runtime.js:

Image

I am using OIMO physics, and this is a new project.

Any ideas?


Fixed!

I had accidentally used a version of index.html that didn't include Oimo.js.

Everything is working fine now.
www.simbucket.com - HTML5 Science Simulations / https://www.airconsole.com/#!play=com.n ... obotrumble - Robot Rumble on AirConsole
B
52
S
17
G
26
Posts: 436
Reputation: 18,092

Post » Fri Apr 28, 2017 1:00 pm

how can i use the qfx shader, i imported my 3d object but i would like to use any kind of shader?
from www.shadertoy.com

it is possible?
B
41
S
16
G
7
Posts: 1,750
Reputation: 9,963

Post » Mon May 01, 2017 4:54 am

@imothep85

No, it's not at all that simple. Qfx shaders aren't a complete feature, and shadertoy doesn't use some kind of standard format anyway.
B
79
S
13
G
8
Posts: 1,977
Reputation: 9,947

Post » Mon May 01, 2017 4:37 pm

@QuaziGNRLnose

Is there anything weird about the raytrace plugin? I have added it to a game layout, then created a new layout as a starting layout. I can loop over all objects when I load the game layout, but when I load the "start" layout first, then go to the game layout, the raytrace object exists in the debugger, but I can't loop through any objects with it.

Any suggestions?
www.simbucket.com - HTML5 Science Simulations / https://www.airconsole.com/#!play=com.n ... obotrumble - Robot Rumble on AirConsole
B
52
S
17
G
26
Posts: 436
Reputation: 18,092

Post » Tue May 02, 2017 3:43 am

@cjbruce

I'm not sure what you mean, its unclear. Even if it's in the debugger it might not exist in the same scene, but there are too many factors for me to understand whats going wrong. Send me a Capx that demonstrates the problem.
B
79
S
13
G
8
Posts: 1,977
Reputation: 9,947

Post » Tue May 02, 2017 10:19 am

QuaziGNRLnose wrote:@cjbruce

I'm not sure what you mean, its unclear. Even if it's in the debugger it might not exist in the same scene, but there are too many factors for me to understand whats going wrong. Send me a Capx that demonstrates the problem.


The bug went like this:

I had two raytracers. One raytracer looked down to see the floor normal. The other raytracer was used for a laser weapon. When I loaded directly to my in-game screen, both raytracers worked. When I loaded from the start screen, then used the "go to layout" to go to the game layout, neither raytracer would raytrace. They both existed with UIDs in the inspector, but they simply would not work.

It looks like the bugs might have been related to one of two things:

1. I was using two different raytracer objects.
2. I had marked the raytracer objects as global.

In the process of troubleshooting, I set both object's "global" property to "no". Then I added one of the raytracers to a container with a 3D game model. Finally, I refactored the event sheet so that all raytracing was done by just one of the raytracers, and deleted the unused raytracer.

After all of this, the problem of raytracers not raytracing when a new layout was loaded went away.
www.simbucket.com - HTML5 Science Simulations / https://www.airconsole.com/#!play=com.n ... obotrumble - Robot Rumble on AirConsole
B
52
S
17
G
26
Posts: 436
Reputation: 18,092

PreviousNext

Return to Completed Addons

Who is online

Users browsing this forum: wertt22 and 2 guests