Page 1 of 3

Character System Demo (feat. Miku Hatsune) MKII

Posted: Mon Oct 18, 2010 11:56 pm
by fmx
Image

MKII, updated: 07 Nov 2010
not the best screenshot in the world I'll admit :oops:


Download ZIP, 5.41MB, Windows only:
http://www.box.net/shared/dc2a0tyr7y
http://www.mediafire.com/?teyt45ovtfbwgv4

This is a small tech-demo of the new Character System I am developing for an upcoming commercial game.

The updated version has some new features and is more complete as a demo and should work on most graphics cards

New Features:
  • Depth of Field post-processing effect
    Glow post-processing effect
    Multi threading
    Variance Shadow Maps
    Lots of tweaks
Demo Features:
  • New joint-skin animation framework (quaternion based)
    Realtime jiggle physics on hair and clothing
    Matrix palette GPU skinning
    Full Bone control (IK ready)
    Generic shadow mapping
    Post processing framework
    Uses Cg shaders (via Nadro's irrCg wrapper)
    Works correctly on both DX9 and GL drivers
Not to mention other features of my engine (custom menus, full iPhone/iPad support, file encryption, irrklang audio, etc).

I wrote my own physics and collision routines so it isn't perfect.
I plan to upgrade to PhysX or Bullet in the future though.

This Miku model was created by Kio for the Blender community, and I borrowed it for this tech demo.
All credit goes to him/her.

I re-rigged and animated it quickly, mind the shoddy work on the skin weighing.
Only three animations were needed: stand idle, walk and run.
All the other motion (her head, ponytails and tie) are derived dynamically.

On a technical note, this Miku model is fairly heavy and not ideal for realtime games:
  • 14K triangles
    22 texture maps
    57 bones
Irrlicht just cannot cope with such models as it stands, which is why I had to reinvent the wheel to get more mileage.


Give her a spin (literally) and post here to share the framerates you get.
Oh and it would also be useful to know about crashes, glitches and other anomalies

Cheers :D


Hatsune Miku is copyright Crypton Media, this demo is for non-profit purposes only.

Posted: Tue Oct 19, 2010 12:27 am
by Adler1337
On highest settings I stay at 133 fps. This is definitely one of the coolest things I've seen around here in a while. Are you planning on releasing the character system?

Posted: Tue Oct 19, 2010 1:16 am
by ArakisTheKitsune
Highest settings 110 fps at GeForce 7600gs Athlon 64 3000+ Windows XP SP3 32 bit
but only works in DirectX9 for me, in OpenGL it crashes instantly no mater what settings I use.

Looks nice, keep up good work.

EDIT: It also crashes in DirectX9 when I set Shadowmap depth 16 bit float

Posted: Tue Oct 19, 2010 3:35 am
by BlindSide
Lookin' goooood 8)

Posted: Tue Oct 19, 2010 7:07 am
by pera
her hair waves really nice, natural.
i got 95fps on integrated graphics IntelCore2Duo @ 2.93GHz + 3.3GB RAM
no post processing, 1024x768, DirectX, 32bp, shadowmap size 1024, depth 16bit.

her tie breaks unnaturally, but i suppose postprocessing fixes that.

is that rinnegan on your avatar?

Posted: Tue Oct 19, 2010 10:39 am
by Mel
I got around 130 fps too with the nice stuff disabled, 90 fps with the Shadow Mapping, and around 35 with physics, pretty slow, but my system is fairly slow too.

Try putting 2 characters like that simultaneously, and see how thing go :)

Posted: Tue Oct 19, 2010 11:04 am
by Bate
That looks amazing!

Runs fine on my ATI Radeon 4850, I get ~130FPS with everything cranked up.

On default settings:
OpenGL : 280FPS
D3D9 : 200FPS

...which is kinda weird.

Posted: Tue Oct 19, 2010 12:09 pm
by Virion
Nice. I got 205 - 210 fps (opengl) and 170 - 175 (directx) on my nvidia gefore 8800gt. i like the head that keep looking at the camera. :D

Posted: Tue Oct 19, 2010 1:19 pm
by Tihtinen
I tried it and got everything from 200 to 700 fps depending on the settings. I have Intel Q6600 + Nvidia GeForce gtx460. For some reason the demo worked generally better on OpenGL than D3D9.

Posted: Tue Oct 19, 2010 2:45 pm
by fmx
Thanks for the feedback! :D
200FPS seems to be a good average, I get similar results to Virion on my development system too.

No idea why GL generally performs better than DX9, it might have something to do with the texture format settings for the RTTs.
I noticed that enabling post processing gives much better results with DX though

ArakisTheKitsune wrote: It also crashes in DirectX9 when I set Shadowmap depth 16 bit float
So it works correctly with 32bit float shadowmap?
Or do you have to disable shadowmapping completely?

Adler1337 wrote:Are you planning on releasing the character system?
Short answer: No
Long answer: Probably :wink:

The character system is still in its infancy and it will evolve alongside the game we plan to use it for.
As Mel just suggested, one character is fine and dandy but two or more may prove to be a recipe for disaster... :roll:

I will share the code when I feel it is superior enough to warrant replacing the current system.
Not anytime soon however.

We still have to consider flexible vertex formats and the direction the irrlicht devs want to go in the future

Posted: Tue Oct 19, 2010 4:26 pm
by puh
Good job!
Also have crash when using OpenGL (all default settings, NVIDIA GeForce 8600GT), but if i switch off shadowmap - runs fine (in OpenGL, in DirectX all is ok)

One note - try to set rendering mode to double-sided, at least for her sleeves

Posted: Tue Oct 19, 2010 7:03 pm
by Virion
I noticed that enabling post processing gives much better results with DX though
I did turn on the post processing during the test and OpenGL ran faster

Posted: Tue Oct 19, 2010 9:57 pm
by shadowslair
Both tests made without rotating the camera or turning on help. All options w/o postrprocessing are on. PC is Win XP cpu 1.14 ram 512 Radeon 9550
Settings: Dx9, 1024x768 screen, 32bp, windowed, shadowmap on 1024, 32 depth, postprocessing is off.
FPS: solid 50
Same settings with OGL: FPS are 56, which is strange for this card (never get higher framerate with GL).

As for the system:
- Using cloth-like physics for such huge (they are as big as herself) ponnytails can be very distracting for the player, plus they are a precognition for some buggy behaviour, at least with the current physics/collision system. As a whole the idea is good, but needs some more work. The tie is behaving very bad all the time.

- IMO It`s a good practice to do your tests with a model with polycount near your polylimit for your actual character plus just a bit more (say about 10%) just in case. Using probably 3x higher model can be used for some "special" kind of test - say what is the performance with many hair particles, more tris for the skinning etc.

- If I was you and I decide to release something for iPhone platform, I`d definitely reject the hair physics for sure. You can animate her hair to see how it will behave (do some tests). Will be much better in 95% of the cases. For some shorter hair the physics may work probably better, then it will not be that spottable, hence again it still does not worth the calculations. Talking about the iPhone device. For the pc it`s ok if it was bit more stable.

- She looks like she`s too lazy to look at the target point properly. In fact, it looks like the look-at controller is not working very good due to gimbal lock. At least not very reallistic.

Um, that`s all I think. Small demo, small feedback. :wink:

Posted: Tue Oct 19, 2010 11:46 pm
by Mel
Then again, what is a program that can only show a single skinned mesh? A skinned character system should be flexible for any amount. :)

I saw a demo in which the program put in as much animated -skinned- meshes it could, and when the program's fps lowered under 30, it stopped.

Keep it up!

Posted: Wed Oct 20, 2010 7:07 pm
by stefbuet
Really nice.
I have 220FPS OpenGL 1280x1024 everything to its maximum
geforce 260GTX.
However physics is very instable. Did you use any kind of instable method like euler integration?