Normal maps:
come si ottengono (2/4)
Photometric Stereo
(una forma di
“inverse lighting”)
da: N immagini (N>=4) reali Stesso punto di vista
Illuminazione diversa
(possibilmente, controllata e nota)
a Normal Map in spazio vista!
convertire in spazio oggetto, o TBN
Normal maps
come si ottengono (3/4)
Normal-Painting sul modello
(e.g. con Z-brush, Sculptris Alpha…) simile a pittura delle diffuse maps
ma painting di dettagli geometrici simile a scuplting
ma il sistema scrive direttamente normali, non geometria
Normal maps
come si ottengono (4/4)
Detail recovery
“detail texture” synthesis baking delle tessiture
da:
1) mesh Hi-Res
2) mesh Low-res + UV mapping (senza ripetizioni) a:
Normal map per 2
(che mimica il dettaglio presente in 1)
Detail texture synthesis (aka detail preservation)
Idea:
input:
a low res mesh A, with (injective) UV-map a hi-res mesh B
with per vertex attributes output:
a texture for A
capturing the vertex attributes in B normals? a normal map is produced
(in object space, convert to TBN if necessary) base color? a diffuse maps is produced
baked (global lighting)? a light-map is produced fully automatic!
es: A ottenuto da B tramite
semplificazione automatica
Modelling + Texturing:
Pipeline production example
Concept drawings
2D artists
Low-poly model A
3D modeller, low poly editing tools
(Injective) UV-mapping of A
UV-mapper, or automatic tool, to build UV-map for A
Subdivision, digital sculpting of Hi-Res model B
3D modeller, digital sculpting
Painting over B
per vertex painting
Detail Recovery:
Automatic construction of Textures for A with attributes from B:
Normals from B, (normal map) Colors from B (diffuse map) Baked lighting from B (light-map)
M a r c o T a r i n i ‧ [ G A M E - D E V ] ‧ V e r o n a ‧ 2 0 1 3
hi-res mesh
low res mesh
semplificazione automatica
still low-res, but textured!
rendering
TESSITURA fatta apposta (es. BumpMap
normali o RGB map x colori) detail
recover
M a r c o T a r i n i ‧ [ G A M E - D E V ] ‧ V e r o n a ‧ 2 0 1 3
simplificato
2K triangles
originale
500K triangles
semplificato ma con tessitura
2K triangles
Detail Recovery: how to
Hi-res model Low-res
model
Texture map
u v
find a suitable spot
Some attribute
e.g.: color, precomputed shading, normal...
Code & Store find a suitable spot
Esempio
Esempio
esempi da cg-talks – CG society
sempi da cg-talks–CG society
esempi da cg-talks–CG society
Cutout textures
texels = alpha (lvl trasparenza)
Alpha map
RGB map
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 1 / 1 2 ‧ U n i v e r s i t à d e l l ’ I n s u b r i a
Cutout textures
texels = alpha (lvl trasparenza)
es: drappi, barba...
by Micheal Filipowski 2004
tessitura
Cutout textures
texels = alpha (lvl trasparenza)
es: alberi, foliage
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 1 / 1 2 ‧ U n i v e r s i t à d e l l ’ I n s u b r i a
Texture mapping e Alpha Test
Es: pelo, pellicce
tessitura (ripetuta)
“Procedural Textures”
Idea: textures come funzioni di (u,v)
E.g.: color texture per bandiera del giappone:
u
v 1.0 0.5
0.3 0.5 1.0
=
else if v
f u
) 1 , 1 , 1 (
) 0 , 0 , 1
( 2
2
3 . 5 0
. 0
5 . 0
<
−
v u
“Procedural Textures”
Funzione da (u,v) a valori texel
Da computare dinamicamente, durante il rendering (per frammento)
invece di accedere ad array 2D di texel
Vantaggi:
costo in RAM: quasi azzerato resolution independent
ALU, invece di accessi in (texture) RAM:
meno caro, quasi sempre!
Usate per immagini semplici
Funz. implementata nel fragment shader
Solid Textures
Solid Textures
Tessituravolumetrica voxelizzata: array 3D di texels 1 texel == 1 voxel
E.g. ogni voxel un colore RGB solid RGB textures
Come tutte le tessiture:
In video RAM
Accesso veloce durante rendering
filtering (tri-lineare) in accesso, MIP mapping …
Modellano colore sul volume
superficie + interno utile, per es, per fratture
Nota: nessun bisogno di UV-mapping!
tessitura indicizzata con geometria mesh (riscalata)
Problema: spazio ram
Cubico con risoluzione
Soluz: tessiture 3D procedurali?
Solid Textures Procedurali
Gyross - progetto di Paolo P. Slepoi