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

Post your completed addons to share with the community

Post » Sun May 10, 2015 4:41 pm

@QuaziGNRLnose

But on local wi-fi preview this problem was also.
B
29
S
8
G
2
Posts: 193
Reputation: 3,179

Post » Sun May 10, 2015 10:03 pm

@norman74
I tested on a MotoX 2013 (Kitkat), a MotoG 2014 (Lollipop) and a Galaxy S4 (Lollipop) and all worked really well on Chrome when exported for web (with minify script off). I use the MotoX for preview over wifi and never had a problem. I haven't tested exporting with Crosswalk yet, but I'm planning to do soon.

@QuaziGNRLnose
I don't know if you have considered, but I have a suggestion to merge similar actions to make the plugins simpler. For example, there's three different "Set Position" actions, one for each coordinate space with the exact same parameters. They could all be merged into one that have a dropdown parameter to select the transform space. The same could be done for "Look At" and "Rotate Around" actions. The "Translate" action could also benefit from a dropdown to select different transform spaces.

*It seems a bit inconsistent that in Q3DModels and secondary plugins it's called "Translate (local space)" and in the Q3DMaster it's called "Move along local vector". They do essentially the same thing and could have the same name for consistency.
Scirra Employee
B
148
S
53
G
17
Posts: 711
Reputation: 17,700

Post » Mon May 11, 2015 12:18 am

@animaniac

The switch statement for the dropdown would make the set position action very slightly slower per call, but the fact set position is so common made me do it that way, because it becomes a waste if you start having thousands of set positions per frame (which is pretty expected in larger projects). Either option had it's caveats but i figured multiple actions was better than a drop down.

that Q3D Master action is just accidentally named different (it's been there a lot longer than the other plugs), thanks for the heads up :)

@norman74

I'm not really sure what you mean. you can't run things "locally" in a browser on a desktop because of browser settings unrelated to Q3D: https://github.com/mrdoob/three.js/wiki ... gs-locally

The cordova/crosswalk issue is similar, but i don't know the settings to change because I haven't used XDK very much. I'm going to investigate when I've got more time. I'm not very familiar with a lot of wrappers so it's difficult for me to find whats going wrong. Right now my hypothesis is that Q3D is not using the right URL for loading files and i'll need to investigate more to verify.
B
75
S
13
G
8
Posts: 1,973
Reputation: 9,841

Post » Mon May 11, 2015 1:18 am

Does Q3D support object animations without skin weighting and bones, only using objects hierarchy ?
Image
B
10
S
1
Posts: 35
Reputation: 935

Post » Mon May 11, 2015 4:34 am

@gorgonzola

You can build/set up object hierarchies in Q3D and animate the transforms with actions. There is no supported boneless file format that can do that though, (although you can convert it to one with bones for Q3D if you can track down importer/exporters). If you really want this type of effect (for something like a robot / car whatever which doesn't have skin weighting), you can use bones to handle the objects/animations (making each "objects" vertices on a single mesh controlled/weighted to only a single bone in the hierarcy will do what you want). This technique can also be mixed with skinning to for example animate a sword being swung by someone. You can also at run-time add objects to the hierarchy of a bone, to put a different gun model in someones hand, a helmet on their head, etc. Alternatively you can assemble/animate entirely with actions if your work needs to be proceduraly animated. If you need fast performance you can even do some things entirely with morph targets when performance needs to be really good (for example in an rts, were having lots of units is more important than super high quality animation, you can make morph targets for a tank+turret as a single model and run/mix 4 multiple targets at any one time entirely on the gpu). Theres a multitude of options depending on your use case.

I'm not really sure if im being clear about the "bones for discrete objects" so what I meant for example:

make a model of a car with wheels.

Make a "bone" at the desired local origin of each wheel, and make these children of a bone for the body. make the wheel vertices linked only to their bone, the body's vertices linked only to its bone , animate the bones then export. The bones will be the "object" in the hierarchy. Bones don't really limit you to organic forms, they're just a way of recognizing the animation information for scale/translation/rotation in the hierarchy.

The other way is to use seperate Q3DModels like you would sprites, and do everything from within construct (this is how the tank in the Tiny Tank demo is animated).

What workflow are you thinking of that necessitates this?
B
75
S
13
G
8
Posts: 1,973
Reputation: 9,841

Post » Mon May 11, 2015 1:55 pm

http://learningthreejs.com/blog/2011/10 ... -geometry/

does this above works same if we add object as child ? will this save some performance if it is positioned as child "for example "3d healthbar" instead of using using set positions every tick ?
B
14
S
2
Posts: 82
Reputation: 1,059

Post » Mon May 11, 2015 2:41 pm

I've got some problems when installing..

This shows up when trying to run any of the examples in C2

http://i.imgur.com/y0Rb33Q.png

But I've put all the plugins in the right folder

http://i.imgur.com/v80vXW5.png

http://i.imgur.com/W8SuSJ7.png

edit: forgot to mention that I just bought it and the version is 2.4

edit 2: oh wow, nevermind, I was putting it in the wrong folder.
B
122
S
42
G
40
Posts: 846
Reputation: 27,994

Post » Mon May 11, 2015 4:21 pm

Ralph wrote:http://learningthreejs.com/blog/2011/10/05/performance-merging-geometry/

does this above works same if we add object as child ? will this save some performance if it is positioned as child "for example "3d healthbar" instead of using using set positions every tick ?


No its not the same, children actually have worse performance than seperate objects in some cases. That article is referring to the practice of lets say making blades of grass all part of the same model instead of seperate objects to make the cpu do less work in calculating only a single transform vs 1000s. This is good practice to delegate work to the gpu.
B
75
S
13
G
8
Posts: 1,973
Reputation: 9,841

Post » Mon May 11, 2015 7:14 pm

QuaziGNRLnose wrote:The switch statement for the dropdown would make the set position action very slightly slower per call, but the fact set position is so common made me do it that way, because it becomes a waste if you start having thousands of set positions per frame (which is pretty expected in larger projects).

I'm not much into C2 plugin development, but can't you avoid the switch by calling different functions and get less overhead?

Like:
Code: Select all
On setPosition action
-callFunction( "setPosition" & dropdownIndex )

On Function "setPosition0"
-do transform in world space...

On Function "setPosition1"
-do transform in local space...

On Function "setPosition2"
-do transform in parent space...
Scirra Employee
B
148
S
53
G
17
Posts: 711
Reputation: 17,700

Post » Mon May 11, 2015 8:19 pm

QuaziGNRLnose wrote:
Ralph wrote:http://learningthreejs.com/blog/2011/10/05/performance-merging-geometry/

does this above works same if we add object as child ? will this save some performance if it is positioned as child "for example "3d healthbar" instead of using using set positions every tick ?


No its not the same, children actually have worse performance than seperate objects in some cases. That article is referring to the practice of lets say making blades of grass all part of the same model instead of seperate objects to make the cpu do less work in calculating only a single transform vs 1000s. This is good practice to delegate work to the gpu.


thx,,,, for your answer,,
what should i do if I would like to have for example 300-500 trees ,50 rocks, plants...etc..
is there any trick to avoid performance kill ? If I create simple 1000 cubes on map "simple geometry" it will increase cpu /drawcalls usage by 35 percent. I have quadcore i7 with 12gb ram , gtx570 .. "lights,, shadows disabled,,, basic shader used."
thats why i am asking if there is possible to do something like that ----> http://learningthreejs.com/blog/2011/10 ... -geometry/ ,, ,, i dont need to move or interact with theese objects.........just save performance................. or three.js is limmited to count of objects . or... maybe i am doing something wrong,,,, or maybe debugger is showing wrong
:roll:

also ,, I would need some .qfx example to get into it.
B
14
S
2
Posts: 82
Reputation: 1,059

PreviousNext

Return to Completed Addons

Who is online

Users browsing this forum: No registered users and 2 guests