Gamestudio Links
Zorro Links
Newest Posts
Data from CSV not parsed correctly
by EternallyCurious. 04/18/24 10:45
StartWeek not working as it should
by Zheka. 04/18/24 10:11
folder management functions
by VoroneTZ. 04/17/24 06:52
lookback setting performance issue
by 7th_zorro. 04/16/24 03:08
zorro 64bit command line support
by 7th_zorro. 04/15/24 09:36
Zorro FIX plugin - Experimental
by flink. 04/14/24 07:48
Zorro FIX plugin - Experimental
by flink. 04/14/24 07:46
AUM Magazine
Latest Screens
The Bible Game
A psychological thriller game
SHADOW (2014)
DEAD TASTE
Who's Online Now
1 registered members (AndrewAMD), 552 guests, and 1 spider.
Key: Admin, Global Mod, Mod
Newest Members
EternallyCurious, 11honza11, ccorrea, sakolin, rajesh7827
19046 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
Multithreaded / GPU based vertex animation? #326377
05/31/10 18:54
05/31/10 18:54
Joined: Jul 2001
Posts: 6,904
H
HeelX Offline OP
Senior Expert
HeelX  Offline OP
Senior Expert
H

Joined: Jul 2001
Posts: 6,904
A8 will have a very nice feature that is a good selling point: GPU-based bone animation.

In the manual, you still propose to use vertex animation when a lot of actors are moving (like crowds, armies, etc.). Is this proposal still valid if you use GPU-bones animation VS. CPU-based vertex animation?

Other than that: (and here comes my proposal) --- are you considering GPU-based vertex animation in the future?

OR: Are you calculating the vertex positions in a multithreaded fashion? If you do not plan to add GPU-based vertex animation and do not multithread the calculations - is there are way to replace your calculations by my own so that I can set up my own animation format for models and calculate it on the CPU by myself by using multithreading under C++? Would you be so kind and give an example for this, then?

This is especially useful if you are doing procedural animations, so if you want to extent the engine into that direction... then... just my two cents :-)

This is an important topic for me,
so, thanks in advance,
-Christian

Last edited by HeelX; 05/31/10 18:56.
Re: Multithreaded / GPU based vertex animation? [Re: HeelX] #326426
06/01/10 00:59
06/01/10 00:59
Joined: Aug 2001
Posts: 2,320
Alberta, Canada
William Offline
Expert
William  Offline
Expert

Joined: Aug 2001
Posts: 2,320
Alberta, Canada
It would be nice if vertex animation is sped up. As I use it a fair bit.


Check out Silas. www.kartsilas.com

Hear my band Finding Fire - www.myspace.com/findingfire

Daily dev updates - http://kartsilas.blogspot.com/
Re: Multithreaded / GPU based vertex animation? [Re: William] #326441
06/01/10 07:28
06/01/10 07:28
Joined: Jul 2000
Posts: 27,978
Frankfurt
jcl Offline

Chief Engineer
jcl  Offline

Chief Engineer

Joined: Jul 2000
Posts: 27,978
Frankfurt
In the last time, people seem only to want features that were already implemented more or less long ago. Seems I can go on vacation... laugh

http://manual.3dgamestudio.net/beta.htm

GPU based animation is only supported in A8 however. It needs the A8 vertex format, which is different to A7.

Re: Multithreaded / GPU based vertex animation? [Re: jcl] #326444
06/01/10 08:00
06/01/10 08:00
Joined: Jul 2001
Posts: 6,904
H
HeelX Offline OP
Senior Expert
HeelX  Offline OP
Senior Expert
H

Joined: Jul 2001
Posts: 6,904
JCL, either I speak in the last time in ambiguous words - and if so, I promise I improve on that - or you don't read carefully. Or both. Who knows.

Nevertheless. In the beta page you are explicitely talking about bones animation. I (or respectively, we) talk about vertex animation. That is for instance, if you load a model in MED with bones animations and click on Edit\Convert to points animation.

So, again my question in a easy to understand order of causal relations:

1.) Situation 1: You provide in A8 a shader which allows GPU accelerated bones animations
2.) Request: We would like to have in A8 a shader that does vertex animations on the GPU rather on the CPU
3.) Reason 1: it is rather time consuming on models with lots of vertices to calculate animations on the CPU if not multithreaded.
4.) Conclusion 1: If your CPU-animation code is not multithreaded (is it?), a parallel GPU would be way more faster, especially on models with lots of vertices
5.) Situation 2: if you don't want to do this, I ask for a way to calculate vertex animations by our own without using ent_setvertex because (citing the manual) "Modifying a mesh of a certain entity [with ent_setvertex] affects all entities that use the same mesh" and using ent_clone is kinda wrong because you have then for each individual entity a cloned mesh...
6.) Request 2: If Situation 2 becomes true, could you provide an example how to do that with DirectX functions without cloning the mesh or can you provide a way to do this (or similar)?

I hope this is clearer to you know. If I am mistaken and confused big time, show me.

Thanks.

Last edited by HeelX; 06/01/10 08:10.
Re: Multithreaded / GPU based vertex animation? [Re: HeelX] #326445
06/01/10 08:12
06/01/10 08:12
Joined: Jul 2000
Posts: 27,978
Frankfurt
jcl Offline

Chief Engineer
jcl  Offline

Chief Engineer

Joined: Jul 2000
Posts: 27,978
Frankfurt
Ah, I see. I must learn to read more than the first sentence of a post. GPU accelerated vertex animation is also theoretically possible. But it does only offer a relatively small speed advantage, and this only in special cases. So, we will probably not provide such a shader, unless some good reason comes up.

Re: Multithreaded / GPU based vertex animation? [Re: jcl] #326447
06/01/10 08:15
06/01/10 08:15
Joined: Jul 2001
Posts: 6,904
H
HeelX Offline OP
Senior Expert
HeelX  Offline OP
Senior Expert
H

Joined: Jul 2001
Posts: 6,904
Okay.. what is this special case you were mentioning?

Re: Multithreaded / GPU based vertex animation? [Re: HeelX] #326448
06/01/10 08:18
06/01/10 08:18
Joined: Jul 2000
Posts: 27,978
Frankfurt
jcl Offline

Chief Engineer
jcl  Offline

Chief Engineer

Joined: Jul 2000
Posts: 27,978
Frankfurt
The special case is when you have many vertex animated models of the same type on the screen, which have a huge number of polygons but only few animation cycles (maybe 5 or 6). In that case the GPU could gain some speed by interpolating the animation with a shader.

Re: Multithreaded / GPU based vertex animation? [Re: jcl] #326453
06/01/10 09:00
06/01/10 09:00
Joined: Jul 2001
Posts: 6,904
H
HeelX Offline OP
Senior Expert
HeelX  Offline OP
Senior Expert
H

Joined: Jul 2001
Posts: 6,904
This is my case, I will have lots of entities on screen, ~1000 vertices each, vertex animated, 4-6 frames per animation, only ~4 models, but many of each type (ranges from 1 to 100 each). My hopes are that model instancing and GPU powered animation will reduce the workload for it (in the future)... so, is it a big deal to do it when you have finished some of the more important stuff?

Last edited by HeelX; 06/01/10 09:01.
Re: Multithreaded / GPU based vertex animation? [Re: HeelX] #326457
06/01/10 09:14
06/01/10 09:14
Joined: Jul 2000
Posts: 27,978
Frankfurt
jcl Offline

Chief Engineer
jcl  Offline

Chief Engineer

Joined: Jul 2000
Posts: 27,978
Frankfurt
Yes, this is possible. When A8 is released, you could send me such a scene and I'll check how I can improve it with GPU vertex animation.

However you must be aware that for GPU based vertex animation to make any sense, we must allocate as many model meshes as there are frames. So we need 5 meshes for a model with 5 frames, which of course consumes 5 times the memory. I'd say this is tolerable for 5 frames, but not if the model has 30 or 50 frames. You'll then use up all your memory for one single model.

When speed is important, better use GPU based bones animation.

Re: Multithreaded / GPU based vertex animation? [Re: jcl] #326482
06/01/10 11:47
06/01/10 11:47
Joined: Jul 2001
Posts: 6,904
H
HeelX Offline OP
Senior Expert
HeelX  Offline OP
Senior Expert
H

Joined: Jul 2001
Posts: 6,904
Ah, I thought that you mean ~5 frames per animation sequence. In that case I think that the costs are way too high for such a (maybe small) improvement.

Anyways, I will then provide you a scene.

Thanks for your explanations!
-Christian


Moderated by  aztec, Spirit 

Gamestudio download | chip programmers | Zorro platform | shop | Data Protection Policy

oP group Germany GmbH | Birkenstr. 25-27 | 63549 Ronneburg / Germany | info (at) opgroup.de

Powered by UBB.threads™ PHP Forum Software 7.7.1