[GameDev]
Tools Programming
Marco Tarini
This Course
this course
game contents
Intro: Game Tools
game
game engine game
tools
digital artists
game contents
Intro: game contents!
(aka game assets)
3D data
models
textures
materials
shaders
animations
collision objects
etc
audio
music
sound fxs
ambient sounds
voice overs
etc
video
2D art
screen splashes
backgrounds
GUI / HUD elements (e.g. buttons, bars),
[ sprites & tile-sets ? ]
etc
text
dialogues trees
messages
translations
etc
etc:
scripts
stats levels
game contents
Intro: Game Tools
game
game engine game
tools
digital artists
game contents
[MOD]
contents digression:
game [MOD] development
game
game engine (public)
game tools
game fans!
[MOD]
contents
(aka game assets)
3D content
models
textures
materials
shaders
animations
collision objects
etc
audio
music
sound fxs
ambient sounds
voice overs
etc
video
cut-scenes, intros
etc
2D art
screen splashes
backgrounds
GUI / HUD elements (e.g. buttons, bars),
[ sprites & tile-sets ? ]
etc
text
dialogues trees
messages
translations
etc
etc:
scripts,
stats,
levels'
3D Models i.e. tri-meshes with:
per vertex attrib
normals, color, AO,
LODs
“uv-mapping”
keyframes
cyclic animations
face-morphs,
“rigging”
Materials
lighting model stats / flags
textures
RGB maps
normal maps
alpha maps
shaders
vertex, fragments,
Intro:
3D game contents
Animations
vertex animations
skeletal animations
Skeletons
Collision objects
hit-boxes
bounding objects
Particle systems
Environments
skydomes
env. maps
scene props
bounding volumes
Tipi di bounding volumes:
Axis Aligned Bounding Box (A.A.B.B.)
(generic) Bounding Box
Discrete Oriented Polytope (D.O.P.)
Bounding sphere
Bounding ellipsoids (axis aligned or not)
Bounding cylinders
Difetti e pregi
quanto sono onerosi da pre-computare?
quanto sono aderenti ?
sono robusti a rotazioni ?
quanto sono onerose le query (es.: di intersezione)?
Rendering di scene composite
spazio mondo (globale) spazio oggetto ruota 1 spazio oggetto automobile
M a r c o T a r i n i ‧ C o m p u t e r G r a p h i c s ‧ 2 0 1 2 / 1 3 ‧ U n i v e r s i t à d e l l ’ I n s u b r i a
V
M
0M
1M
2M
3M
4M
5M
6posizonamento della automobile
(rispetto al mondo)
posiz. della ruota (rispetto
all’
automobile)
Scene graph
V
M
0M
1M
2M
3M
4M
5M
6posizonamento della automobile
(rispetto al mondo)
posiz. della ruota (rispetto
all’
automobile)
Un robot animato…
M
M
0M
1M
2M
4M
6Robot (bacino) spazio mondo
busto1
gamba Sx
gamba Dx
spalla Dx
spalla Sx
polpaccio Dx busto2
M
3M
7piede Dx
M
8M
5collo
Algoritmo 1
mult_matrix( M );
draw( bacino );
push();
mult_matrix( M0 );
draw( busto1 );
mult_matrix( M1 );
draw( busto2 );
push( );
multMatrix( M3 );
draw( spallaDx );
… /* resto del braccio dx */
pop();
push( );
multMatrix( M3 );
draw( spallaSx );
… /* resto del braccio sx */
pop();
pop();
push();
mult_matrix( M2 );
draw( gambaDx );
… pop();
poses(for a skeleton) poses(for a skeleton)
skins(rigged meshes) skins(rigged meshes) skeletons
skeletons
oggetti
Skel Human
rest pose
(or: bind pose)
pose 0 pose 0 pose 0 pose t20
Skin 1 Skin 2
pose 0 pose 0 pose t18
Skel Horse
animation 1 animation 2
“rigging”
skins(rigged meshes) skins(rigged meshes)
(Linear blend) Skinning:
Skel Human
pose 0 pose 0 pose t20
Skin 1 Skin 2
pose 0 pose 0 pose t18
animation 1 animation 2