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

Post your completed addons to share with the community

Post » Sat Feb 14, 2015 6:31 am

In addition to the performance suggestions from @QuaziGNRLnose in the above posts, here is the summary of performance optimization findings with whatever limited features (and with my limited knowledge of the plugin) I have used so far...These could be helpful to optimize the performance for someone trying build such apps, especially for mobile.
-----
- A balancing act : If I create and destroy too many models upfront, then the FPS dips to pretty low rates. Rather, I saw optimized performance, understandably, when I create/destroy a group of them at different times OR you could even consider dynamic loading if the .js model files are very small.
- Optimization when using morph animations: The morph animations seems to account for major percentage of "kb" in the .js files. So if I try to consolidate many morph animations of the same model with different animation names into a single .js file, then the size of the .js file becomes too large when loading for the first time to cause a enough pause/dip in FPS. Rather a dynamic loading of each small file seemed better from user experience perspective.
- Beware of Transparent objects : Making a model transparent ( with draw sides of front and back) makes the model appear patchy...probably a threejs limitation but definitely brings the user experience down when this feature is used. I also noticed that having the transparency on, made the performance little bit lower, for valid rendering reasons, ofcourse! With such limitation, the user experience is still a compromise if you want to show transparent objects.
- Lights on mobile? : With addition of even a single light, the performance on iPad2 ( I haven't tested on other mobile platforms) is pretty low. So need to get rid of all lights if you plan to launch it on iPad2 ( and probably true for many mobile platforms as well!).
- .js model file size: if the .js file to be loaded is very big ( lets say more than 2Mb or so), then there is quite a good chance that the model will not load on iPad2. So try to have smaller .js model files. Not sure if .obj files are smaller in size and load faster than .js files? If some experts could comment, please welcome.
----
Not sure if its related to performance but I observed that the navigation seemed slightly jittery in iPad in-app browser ( when launched as an app) compared to running the same app on the iPad safari browser when in online preview mode. Again, could be a limitation from Apple to support such stuff...
For game development / IT services contact - [email protected]

List of published iOS apps -
https://itunes.apple.com/us/artist/ravi ... d693234511
B
84
S
20
G
3
Posts: 337
Reputation: 7,368

Post » Sat Feb 14, 2015 8:38 am

ex32 wrote:I see many people are using this plugin without problem. How about mobile performance with lights? anyone tested it?


Performance on mobile varies widely between device types / OS / hardware

The WebGL standard is support better by some (google / android) than others (apple / IOS). My current stance is to optimize the plugin for current average desktop hardware. Phones will get there when they get there, but I can't do much to make it more performant that wouldn't mean severe limitations. When Q3D was in V1.0 most (probably all) phones couldn't run/render 3D WebGL with much success, and now I've gotten 60 fps on a nexus 5. I'd say mobiles are catching up, but first and foremost Q3D and really WebGL itself are optimized for desktop web applications right now. Test the mobile demo on the first page for an example on your phone browser. It has 6 lights i believe. I'm working to make it a fast game engine for the web, but WebGL's still pretty cutting edge so the mobile environment/devs aren't as fast on the uptake of the technology as desktop browsers have been. I'd say anything you make with it will eventually (in the not so distant future) be running just as well on mobiles.
B
79
S
13
G
8
Posts: 1,977
Reputation: 9,947

Post » Sat Feb 14, 2015 8:45 am

@kmsravindra

Thanks for being so helpful with your testing on iPad, I'm doing my best to ensure Q3D performs as well as it can. somethings you listed like the transparency are simply shortcomings of forward renderers that i can't avoid without a heavy performance tradeoff, and other things like morph animation size are just a drawback of the technique. When skeletal animation is available you should be able to improve loading/filesize issues (morph animations love to chew memory when not used for procedural morphing stuff) at the cost of some performance (skeletal animations are more cpu-intensive, since they require extra transformation matrices). That's quite an old iPad you're testing on, so it's understandable to me now why there have been these issues, as i stated my nexus 5 can run many lights simultaneously in the browser no less! i think this stuff varies widely among platforms.
B
79
S
13
G
8
Posts: 1,977
Reputation: 9,947

Post » Sat Feb 14, 2015 9:22 am

Thanks! With this said, I am really enjoying developing with Q3Dplugin so far and I plan on building some interesting stuff in the near future...Cutting edge technologies always have few trade-off's and I tend to look at the brighter side of the things :)
For game development / IT services contact - [email protected]

List of published iOS apps -
https://itunes.apple.com/us/artist/ravi ... d693234511
B
84
S
20
G
3
Posts: 337
Reputation: 7,368

Post » Sat Feb 14, 2015 4:50 pm

lost my q3d plugin pass ... is there a way to find out what was it? since on website i dont see a password recovery ... :-s
B
78
S
23
G
69
Posts: 1,353
Reputation: 44,025

Post » Sun Feb 15, 2015 7:45 am

gamecorpstudio wrote:lost my q3d plugin pass ... is there a way to find out what was it? since on website i dont see a password recovery ... :-s


email davioware(at)davioware.com with your contact info / name / any useful identification so we can check the database/email history for your purchase and resend it.
B
79
S
13
G
8
Posts: 1,977
Reputation: 9,947

Post » Mon Feb 16, 2015 9:07 am

Hi @QuaziGNRLnose,

I am trying to build something like as in here - http://threejs.org/examples/webgl_inter ... inter.html

I understood that I have to use the Q3Draycaster for this and tried working my way with the plugin. I have looked at the example of Raycaster and viewports.capx in this regard.

However, I am stuck with some basic questions like -
1. how do I pickup the cube and limit the cube movement in 3d axis while moving it only the grid.
2. how to move it step by step on the grid in x or y directions (exactly into the square positions) along the grid
3. Should I make the grid a Q3DModel object having one single object OR multiple square Q3DModel objects connected together?
4. How can I place the cube only on top ( if there is a cube already at the bottom) etc., To do this, would I need to use collision testing feature as well?
5. I think I can pick up the cube using the 2 conditions - Q3DViewport projection point in frame to mouse co-ordinates and Q3Dviewport --> Project,pick 1st, then I see I can pick-up the cube? Then should I use Q3Draycaster to move the cube along the raycaster? If so, how can I move along the raycaster? (Also, I assume I have to position the Q3Draycaster to cameraposition.xw, cameraposition.yw, cameraPosition.zw and direct it at the highlighted cube model?)

Do you see this as relatively easy one to build OR slightly complex? Any quick helpful pointers on how to achieve this functionality would be really helpful.
Last edited by kmsravindra on Mon Feb 16, 2015 10:21 am, edited 2 times in total.
For game development / IT services contact - [email protected]

List of published iOS apps -
https://itunes.apple.com/us/artist/ravi ... d693234511
B
84
S
20
G
3
Posts: 337
Reputation: 7,368

Post » Mon Feb 16, 2015 9:18 am

Awesome plugin! Do anyone know if this works with the Wii U? I'm guessing probably not due to WebGL rendering, but I may be wrong?
B
3
Posts: 1
Reputation: 177

Post » Mon Feb 16, 2015 7:11 pm

Its possible with q3d, but the math/linear algebra involved (unrelated to q3d) is a bit complex if youve never done it. Q3d viewport casts rays too, just based on x / y coordinates, the intersection gives you info about the point of intersection in X,Y,Z , normal of intersections, etc. through the expressions (they have useful descriptions).

You'd make the grid one big Q3D Model, and test for intersections with it. then you'd take the intersection point and do something like x= round(.x/cellsizex)*cellsizex to get it aligned to the grid. Just check out the source for the page to get an idea of how they did it! obviously it'll be simpler with Q3D since it has lots of functions and objects to do it, but not vastly different.
B
79
S
13
G
8
Posts: 1,977
Reputation: 9,947

Post » Mon Feb 16, 2015 7:26 pm

Naeza wrote:Awesome plugin! Do anyone know if this works with the Wii U? I'm guessing probably not due to WebGL rendering, but I may be wrong?


I'm pretty sure it wont work because it's WebGL. I haven't gotten anything to run in my WiiU browser at least.
B
79
S
13
G
8
Posts: 1,977
Reputation: 9,947

PreviousNext

Return to Completed Addons

Who is online

Users browsing this forum: No registered users and 0 guests