12.2 Space Deformation Hao Li http://cs621.hao-li.com 1 Hoooray! - - PowerPoint PPT Presentation

12 2 space deformation
SMART_READER_LITE
LIVE PREVIEW

12.2 Space Deformation Hao Li http://cs621.hao-li.com 1 Hoooray! - - PowerPoint PPT Presentation

Spring 2019 CSCI 621: Digital Geometry Processing 12.2 Space Deformation Hao Li http://cs621.hao-li.com 1 Hoooray! 2 Last Time Surface Deformations 3 Space Deformation Displacement function defined on the ambient space d : R 3 R 3


slide-1
SLIDE 1

CSCI 621: Digital Geometry Processing

Hao Li

http://cs621.hao-li.com

1

Spring 2019

12.2 Space Deformation

slide-2
SLIDE 2

Hoooray!

2

slide-3
SLIDE 3

Last Time

3

Surface Deformations

slide-4
SLIDE 4

Space Deformation

4

  • Displacement function defined on the ambient

space

  • Evaluate the function on the points of the

shape embedded in the space

Twist warp Global and local deformation of solids [A. Barr, SIGGRAPH 84]

d : R3 → R3 x0 = x + d(x)

slide-5
SLIDE 5

Freeform Deformation

5

  • Control object
  • User defines displacements di for each element
  • f the control object
  • Displacements are interpolated to the entire

space using basis functions

  • Basis functions should be

smooth for aesthetic results

Bi(x) : R3 → R

d(x) =

k

X

i=1

di Bi(x)

slide-6
SLIDE 6

Freeform Deformation

6

  • Control object = lattice
  • Basis functions Bi (x) are

trivariate tensor-product splines:

d(x, y, z) =

l

X

i=0 m

X

j=0 n

X

k=0

dijk Ni(x)Nj(y)Nk(z)

[Sederberg & Parry 86]

slide-7
SLIDE 7

Freeform Deformation

7

  • Aliasing artifacts
  • Interpolate deformation constraints?

! Only in least squares sense

[Sederberg & Parry 86]

slide-8
SLIDE 8

Limitations of Lattices as Control Objects

8

  • Difficult to manipulate
  • The control object is not

related to the shape of the edited object

  • Parts of the shape in

close Euclidean distance always deform similarly, even if geodesically far

slide-9
SLIDE 9

9

  • Control objects are arbitrary space curves
  • Can place curves along meaningful features of

the edited object

  • Smooth deformations around the curve with

decreasing influence

Wires

[Singh & Fiume 98]

slide-10
SLIDE 10

10

Handle Metaphor

  • Wish list for the displacement function d(x) :

! Interpolate prescribed constraints ! Smooth, intuitive deformation

d : R3 → R3

x → x + d(x) d(xi) = di

[RBF, Botsch & Kobbelt 05]

slide-11
SLIDE 11

11

Volumetric Energy Minimization

  • Minimize similar energies to surface case
  • But displacements function lives in 3D...

! Need a volumetric space tessellation? ! No, same functionality provided by RBFs!

Z

R3 kdxxk2 + kdxyk2 + . . . + kdzzk2 dx dy dz ! min

[RBF, Botsch & Kobbelt 05]

slide-12
SLIDE 12

12

Radial Basis Functions

  • Represent deformation by RBFs
  • Triharmonic basis function ϕ (r) = r 3

! C2 boundary constraints ! Highly smooth / fair interpolation

d(x) = X

j

wj ϕ(kcj xk) + p(x)

Z

R3 kdxxxk2 + kdxyyk2 + . . . + kdzzzk2 dx dy dz ! min

[RBF, Botsch & Kobbelt 05]

slide-13
SLIDE 13

13

Radial Basis Functions

  • Represent deformation by RBFs
  • RBF fitting

! Interpolate displacement constraints ! Solve linear system for wj and p!

d(x) = X

j

wj ϕ(kcj xk) + p(x)

[RBF, Botsch & Kobbelt 05]

slide-14
SLIDE 14

14

Radial Basis Functions

  • Represent deformation by RBFs
  • RBF evaluation

! Function d transforms points ! Jacobian ∇d transforms normals ! Precompute basis functions! ! Evaluate on the GPU!

d(x) = X

j

wj ϕ(kcj xk) + p(x)

[RBF, Botsch & Kobbelt 05]

slide-15
SLIDE 15

15

Local & Global Deformations

[RBF, Botsch & Kobbelt 05]

slide-16
SLIDE 16

16

Local & Global Deformations

1M vertices movie

[RBF, Botsch & Kobbelt 05]

slide-17
SLIDE 17

17

Space Deformation

  • Handle arbitrary input

! Meshes (also non-manifold) ! Point sets ! Polygonal soups ! …

  • Complexity mainly depends
  • n the control object, not

the surface

! 3M triangles ! 10k components ! Not oriented ! Not manifold

slide-18
SLIDE 18

18

Space Deformation

  • Handle arbitrary input

! Meshes (also non-manifold) ! Point sets ! Polygonal soups ! …

  • Easier to analyze:

functions on Euclidean domain

! Volume preservation: |Jacobian| = 1

slide-19
SLIDE 19

19

Space Deformation

  • The deformation is only loosely aware of the

shape that is being edited

  • Small Euclidean distance → similar deformation
  • Local surface detail may be distorted
slide-20
SLIDE 20

20

Cage-Based Deformation

  • Cage = crude version of the input shape
  • Polytope (not a lattice)

[Ju et al. 05]

slide-21
SLIDE 21

21

Cage-Based Deformation

  • Each point x in space is represented w.r.t.

to the cage elements using coordinate functions

v x

pi

x =

k

X

i=1

wi(x) pi

[Ju et al. 05]

slide-22
SLIDE 22

22

Cage-Based Deformation

  • Each point x in space is represented w.r.t.

to the cage elements using coordinate functions x pi

x =

k

X

i=1

wi(x) pi

[Ju et al. 05]

slide-23
SLIDE 23

23

Cage-Based Deformation

x pi p!i x!

x0 =

k

X

i=1

wi(x) p0

i

[Ju et al. 05]

slide-24
SLIDE 24

24

Generalized Barycentric Coordinates

  • Lagrange property:
  • Reproduction:
  • Partition of unity:

wi(pj) = δij ∀x,

k

X

i=1

wi(x) pi = x ∀x,

k

X

i=1

wi(x) = 1

slide-25
SLIDE 25

25

Coordinate Functions

  • Mean-value coordinates

[Floater 2003, Ju et al. 2005] ! Generalization of barycentric coordinates ! Closed-form solution for wi (x)

slide-26
SLIDE 26

26

Coordinate Functions

  • Mean-value coordinates

[Floater, Ju et al. 2005] ! Not necessarily positive on non-convex domains

slide-27
SLIDE 27

27

Coordinate Functions

  • Harmonic coordinates (Joshi et al. 2007)

! Harmonic functions hi(x) for each cage vertex pi ! Solve subject to: hi linear on the boundary s.t. hi (pj) = δij

Δ h = 0

MVC HC

slide-28
SLIDE 28

28

Coordinate Functions

  • Harmonic coordinates (Joshi et al. 2007)

! Harmonic functions hi(x) for each cage vertex pi ! Solve subject to: hi linear on the boundary s.t. hi (pj) = δij

  • Volumetric Laplace equation
  • Discretization, no closed-form

Δ h = 0

slide-29
SLIDE 29

29

Coordinate Functions

  • Harmonic coordinates (Joshi et al. 2007)

MVC HC

slide-30
SLIDE 30

30

Coordinate Functions

x0 =

k

X

i=1

wi(x) p0

i + m

X

j=1

ψj(x) n0

j

  • Green coordinates (Lipman et al. 2008)
  • Observation: previous vertex-based basis

functions always lead to affine- invariance!

slide-31
SLIDE 31

31

Coordinate Functions

  • Green coordinates (Lipman et al. 2008)
  • Correction: Make the coordinates depend
  • n the cage faces as well

x0 =

k

X

i=1

wi(x) p0

i + m

X

j=1

ψj(x) n0

j

slide-32
SLIDE 32

32

Coordinate Functions

  • Green coordinates (Lipman et al. 2008)
  • Closed-form solution
  • Conformal in 2D, quasi-conformal in 3D

MVC GC GC

slide-33
SLIDE 33

33

Coordinate Functions

  • Green coordinates (Lipman et al. 2008)
  • Closed-form solution
  • Conformal in 2D, quasi-conformal in 3D

Alternative interpretation in 2D via holomorphic functions and extension to point handles : Weber et al. Eurographics 2009

slide-34
SLIDE 34

34

Cage-Based Methods: Summary

Pros:

  • Nice control over volume

! Squish/stretch

Cons:

  • Hard to control details of embedded

surface

slide-35
SLIDE 35

35

Non-Linear Space Deformation

! Involve'nonlinear'op,miza,on' ! Enjoy'the'advantages'of'space'warps'' ! Addi,onally,'have'shape<preserving' proper,es'

slide-36
SLIDE 36

36

As-Rigid-As-Possible Deformation

! Points'or'segments'as'control'objects' ! First'developed'in'2D'and'later'extended'to'3D' by'Zhu'and'Gortler'(2007)'

Moving-Least-Squares (MLS) approach [Schaefer et al. 2006]

slide-37
SLIDE 37

37

As-Rigid-As-Possible Deformation

! A"ach&an&affine& transforma0on&to&each&point&x& ∈&R3:& &Ax(p) = Mxp + tx ! The&space&warp:& x → Ax(x) & &

Moving-Least-Squares (MLS) approach [Schaefer et al. 2006]

slide-38
SLIDE 38

38

As-Rigid-As-Possible Deformation

! Handles(pi(are(displaced(to(qi( ! The(local(transforma3on(at(x:( (Ax(p) = Mxp + tx s.t.( ( ! The(weights(depend(on(x:( wi (x) = ||pi – x||–2α( (

min ) ( A ) (

1 2

→ −

= k i i i i

w q p x

x

Moving-Least-Squares (MLS) approach [Schaefer et al. 2006]

slide-39
SLIDE 39

39

As-Rigid-As-Possible Deformation

! No#addi'onal#restric'on#on#Ax(⋅)#–#affine# local#transforma'ons#

Moving-Least-Squares (MLS) approach [Schaefer et al. 2006]

slide-40
SLIDE 40

40

As-Rigid-As-Possible Deformation

! Restrict(Ax(⋅)(to(similarity(

Moving-Least-Squares (MLS) approach [Schaefer et al. 2006]

slide-41
SLIDE 41

41

As-Rigid-As-Possible Deformation

! Restrict(Ax(⋅)(to(similarity(

! ! " # $ $ % & − = a b b a

x

M

Moving-Least-Squares (MLS) approach [Schaefer et al. 2006]

slide-42
SLIDE 42

42

As-Rigid-As-Possible Deformation

! Restrict(Ax(⋅)(to(rigid(

Moving-Least-Squares (MLS) approach [Schaefer et al. 2006]

slide-43
SLIDE 43

43

As-Rigid-As-Possible Deformation

! Restrict(Ax(⋅)(to(rigid(

( ( (

( Solve(for(Mx(like( similarity(and(then( normalize(

! ! " # $ $ % & − = a b b a

x

M

Moving-Least-Squares (MLS) approach [Schaefer et al. 2006]

slide-44
SLIDE 44

44

As-Rigid-As-Possible Deformation

! Examples)

Moving-Least-Squares (MLS) approach [Schaefer et al. 2006]

slide-45
SLIDE 45

45

As-Rigid-As-Possible Deformation

! No#linear#expression#for#similarity#in#3D# ! Instead,#can#solve#for#the#minimizing#rota;on# # #

#

#by#polar#decomposi;on#of#the#3×3#covariance# matrix##

= ∈

k i i i i

w

1 2 ) 3 ( SO R

R ) ( min arg q p x

Moving-Least-Squares (MLS) extension to 3D [Zhu & Gortler 07]

slide-46
SLIDE 46

46

As-Rigid-As-Possible Deformation

! Zhu$and$Gortler$also$replace$the$Euclidean$ distance$in$the$weights$by$“distance$within$ the$shape”$ $ $ $ $

$

$$ wi (x) = d(pi , x)–2α $

Moving-Least-Squares (MLS) extension to 3D [Zhu & Gortler 07]

slide-47
SLIDE 47

47

As-Rigid-As-Possible Deformation

! More%results% % % % %

%

%%

Moving-Least-Squares (MLS) extension to 3D [Zhu & Gortler 07]

slide-48
SLIDE 48

48

As-Rigid-As-Possible Deformation

! Surface(handles(as(interface( ! Underlying(graph(to(represent(the( deforma6on;(nodes(store(rigid(transforma6ons( ! Decoupling(of(handles(from(def.( representa6on(

Deforma6on(Graph( Op6miza6on(Procedure(

Embedded Deformation [Sumner et al. 07]

slide-49
SLIDE 49

49

Deformation Graph

Embedded Deformation [Sumner et al. 07]

slide-50
SLIDE 50

50

Deformation Graph

Begin&with&an&embedded&object.& Embedded Deformation [Sumner et al. 07]

slide-51
SLIDE 51

51

Deformation Graph

One$rigid$transforma/on$for$each$node: Rj , tj Each$node$deforms$nearby$space.$ Edges$connect$nodes$of$overlapping$ influence.$ Begin$with$an$embedded$object.$ Nodes$selected$via$uniform$sampling;$located$at$$$gj Embedded Deformation [Sumner et al. 07]

slide-52
SLIDE 52

52

Deformation Graph

One$rigid$transforma/on$for$each$node: Rj , tj Each$node$deforms$nearby$space.$ Edges$connect$nodes$of$overlapping$ influence.$ Begin$with$an$embedded$object.$ Nodes$selected$via$uniform$sampling;$located$at$$$gj Embedded Deformation [Sumner et al. 07]

slide-53
SLIDE 53

53

Deformation Graph

Influence'of'nearby'transforma1ons'is'blended.'

[ ]

2 max 1

) 1 ( ) ( ) ( R ) ( d / w w

j j m j j j j j j

g x x t g g x x x − − = + + − = " ∑

=

point'x'transformed'by'node'j Embedded Deformation [Sumner et al. 07]

slide-54
SLIDE 54

54

Optimization

Select&&&drag&ver-ces&of&embedded&

  • bject.&

Embedded Deformation [Sumner et al. 07]

slide-55
SLIDE 55

55

Optimization

Select&&&drag&ver-ces&of&embedded&

  • bject.&

Op-miza-on&finds& deforma-on&parameters&&Rj , tj.&

Embedded Deformation [Sumner et al. 07]

slide-56
SLIDE 56

56

Optimization

Graph& parameters& Rota-on& term& Regulariza-on& term& Constraint& term& Select&&&drag&ver-ces&of&embedded&

  • bject.&

Op-miza-on&finds& deforma-on&parameters&&Rj , tj.&

con con reg reg rot rot , , , ,

E E E min

1 1

w w w

m m

+ +

t R t R …

Embedded Deformation [Sumner et al. 07]

slide-57
SLIDE 57

57

Optimization

For$detail$preserva.on,$ features$should$rotate$and$ not$scale$or$skew.$

con con reg reg rot rot , , , ,

E E E min

1 1

w w w

m m

+ +

t R t R …

2 3 3 2 2 2 2 1 1 2 3 2 2 3 1 2 2 1

) 1 ( ) 1 ( ) 1 ( ) ( ) ( ) ( ) ( Rot − ⋅ + − ⋅ + − ⋅ + ⋅ + ⋅ + ⋅ = c c c c c c c c c c c c R ) ( Rot E

1 rot j m j

R

=

=

Embedded Deformation [Sumner et al. 07]

slide-58
SLIDE 58

58

Optimization

where%node%j%thinks% node%k%should%go% where%node%k actually%goes% Neighboring%nodes%should% agree%on%where%they%transform% each%other.%

con con reg reg rot rot , , , ,

E E E min

1 1

w w w

m m

+ +

t R t R …

∑ ∑

= ∈

+ − + + − =

m j j k k k j j j k j jk

α

1 ) ( N 2 2 reg

) ( ) ( E t g t g g g R

Embedded Deformation [Sumner et al. 07]

slide-59
SLIDE 59

59

Optimization

Handle'ver*ces'should'go' where'the'user'puts'them.'

con con reg reg rot rot , , , ,

E E E min

1 1

w w w

m m

+ +

t R t R …

=

− =

p l l l 1 2 2 ) ( index con

~ E q v

Embedded Deformation [Sumner et al. 07]

slide-60
SLIDE 60

60

Optimization

con con reg reg rot rot , , , ,

E E E min

1 1

w w w

m m

+ +

t R t R …

Embedded Deformation [Sumner et al. 07]

slide-61
SLIDE 61

61

Results on Polygon Soups

Embedded Deformation [Sumner et al. 07]

slide-62
SLIDE 62

62

Results on Giant Mesh

Embedded Deformation [Sumner et al. 07]

slide-63
SLIDE 63

63

Detail Preservation

Embedded Deformation [Sumner et al. 07]

slide-64
SLIDE 64

64

Discussion

! Decoupling+of+deforma1on+complexity+and+ model+complexity+ ! Nonlinear+energy+op1miza1on+–+results+ comparable+to+surface:based+approaches+

Embedded Deformation [Sumner et al. 07]

slide-65
SLIDE 65

Projects

65

slide-66
SLIDE 66

Geometry Processing Project

66

Goal

  • Small research project
  • 1 week for project proposal, deadline April 2
  • choose between 3 options: A,B, or C
  • >1 month for project, deadline May 07
  • group, size up to 2
  • contributes 30% to the final grade.
  • send to zenghuan@usc.edu
slide-67
SLIDE 67

Scope

67

A) For the disciplined

  • Deformation Project, we will provide a framework
  • You will implement a surface-based linear deformation

algorithm (bending minimizing deformation).

B) For the creative [+10 points]

  • Imagine an interesting topic around geometry processing
  • r related to your PhD research or something you always

wanted to do, and write a proposal.

  • If it gets approved, you are good to go.

C) For the bad ass [+10 points]

  • Implement a Siggraph, SGP, SCA, or Eurographics Paper.
  • Geometry processing related of course ;-)
slide-68
SLIDE 68

Project Submission

Deliverables for A)

  • Source Code, Binary, Data
  • Text files describing the project, how to run it.

Deliverables for B) and C)

  • Short Presentation will be held May 7th (length TBD)
  • Video / Figures
  • Documentation (pdf, doc, txt file): 2 or more pages, short

paper style, be rigorous and organized, must include at least abstract, methodology, and results.

slide-69
SLIDE 69

Project Proposal

69

Structure

  • Title
  • Motivation
  • Goal
  • Proposed Method
  • References

Format

  • authors’ names/student IDs
  • 1-2 pages
  • .doc, .pdf, .txt
  • figures
slide-70
SLIDE 70

Deformation Framework for A)

70

  • Inherit from MeshViewer with user interface:
  • ‘p’: pick a handle
  • ‘d’: drag a handle (last one with starting code)
  • ‘m’: move the mesh
slide-71
SLIDE 71

Deformation Framework for A)

71

  • add handle picking code to

DeformationViewer::mouse()

  • add deformation codes to

DeformationViewer::deform_mesh()

  • add extra classes and files if needed
  • gmm is provided to solve linear systems
slide-72
SLIDE 72

Some ideas for B) or C)

  • registration: articulated / deformable motions…
  • shape matching: RANSAC, spin images, spherical

harmonics…

  • Smoothing: implicit surface fairing…
  • parameterization: harmonic/conformal mapping…
  • remeshing: anisotropic, quad mesh…
  • deformation: As-rigid-as-possible, gradient-based…
slide-73
SLIDE 73

http://cs621.hao-li.com

Thanks!

73