Yingcai Xiao Surface and Volume Representation and Procedural Animation Yingcai Xiao

  • View
    212

  • Download
    0

Embed Size (px)

Text of Yingcai Xiao Surface and Volume Representation and Procedural Animation Yingcai Xiao

  • Slide 1
  • Yingcai Xiao Surface and Volume Representation and Procedural Animation Yingcai Xiao
  • Slide 2
  • Outline Why? Surface Representation Volume Representation Procedural Animation Application in Unity3D
  • Slide 3
  • Yingcai Xiao Why? Waves of tsunami Splashes of diving Drilling into the ground Moving inside an object (fluids)
  • Slide 4
  • Yingcai Xiao Surface Representations
  • Slide 5
  • . Analytical Planes: ax + by + cz + d=0 e.g. y = 0;
  • Slide 6
  • . Analytical Curved Surfaces : ax 2 + by 2 + cz 2 + dxy + eyz + fzx + gx + hy + iz + j = 0 a-j are constants. x 2 + y 2 + z 2 = 64;
  • Slide 7
  • . Analytical Parametrical Surfaces : x = x (s,t); y = y (s,t); B-Splines
  • Slide 8
  • Parametric Form of a line: x(t) = x 0 + t * (x 1 x 0 ) y(t) = y 0 + t * (y 1 y 0 ) 0
  • Converting non-indexed to an indexed structure. Elevation grid => Triangular strips Uniform grid => Hexahedral mesh Uniform grid => Tetrahedral mesh
  • Slide 50
  • Morphing and Procedural Animation
  • Slide 51
  • Morphing Special effect hat changes (morphs) one image or geometry into another. http://en.wikipedia.org/wiki/Morphing
  • Slide 52
  • Morphing Geometric morphing: modify the xyz values in the point list in a coordinated way. http://www.makehuman.org, open source for creating animation characters. http://www.makehuman.org http://www.makehuman.org/doc/node/what_is_a_target_the_ makehuman_morphing_process.html
  • Slide 53
  • Procedural Morphing Use scripts to change the geometry of game objects at run-time. A demo in Unity3D to change the geometry of a plane to a wave form.
  • Slide 54
  • Demo in Unity3D To change the geometry of a plane to a wave form. Create a new project with Character Controller package. Add a plane (GameObject->CreateOhters->Plane) Scale it in the Inspector to 10X10 (in x and z). Uncheck the Mesh Collider (in the Inspector) Add a light (GameObject->CreateOhters->DirectionalLight) Add a FPC (Project->Assets->StandardAssets- >CharacterControllers->FirstPersonController, drag-and- drop it to Hierarchy.) Move it up. (Change its y position in the Inspector to 11). Add script to morph the plane (Plane->Inspector- >AddComponent->NewScript->JavaScript) name it Wave. Add the code on the next page to the Wave.js in Mono. Build->Build All in Mono to make sure there is no compilation errors.
  • Slide 55
  • Demo in Unity3D (Wave) #pragma strict function Start () { var mesh: Mesh = this.GetComponent(MeshFilter).mesh; var verts: Vector3[] = mesh.vertices; for (var v = 0; v < verts.Length; v++) { verts[v].y = Random.Range(0,10); } mesh.vertices = verts; mesh.RecalculateBounds(); mesh.RecalculateNormals(); this.gameObject.AddComponent(MeshCollider); } function Update () { }
  • Slide 56
  • Time-dependent Carpet Plots y(r,t) = A e -r-at cos(2 (r-Vt) / ); r = sqrt ((x-x 0 )*(x-x 0 )+ (z-z 0 )*(z-z 0 )) P 0 (x 0, y 0, z 0 ) : center of the wave A: amplitude of the wave V: velocity of the wave : wave length of the wave a: speed of decaying t = current time time of impact (t 0 )
  • Slide 57
  • Advanced Morphing Tools
  • Slide 58
  • - Major Issues Mesh generation Mesh modification Mesh node identification Grid based: x(i), y(j), z(k) Indexed: node => x, y, x X, y, z => node (graphical)
  • Slide 59
  • - Free software for students from AutoDesk http://www.autodesk.com/education/free-software/all http://area.autodesk.com/students Popular 3ds Max: 3D modeling, animation, rendering, and compositing software for games, film, and video content. AutoCAD (Computer Aided Design) CAD design, drafting, modeling, drawing, and engineering software. Inventor Professional 3D CAD software 3D mechanical CAD, visualization, and documentation software. Revit Building Information Modeling (BIM) tools for architectural design, MEP, and structural engineering.
  • Slide 60
  • - Maya: free for students from AutoDesk 3D animation, modeling, simulation, rendering, and compositing software Can be used to generate morphing. -Use Maya to create a 3D object. -Duplicate it and modify the duplicate to the needed shape. -Use Blend Shape Deformer of Maya to recognize all of the shapes. -Import the shapes into Unity3D. -Write C# or JavaScript to control the morphing animation.
  • Slide 61
  • MegaFiersMegaFiers plugin for Unity3D -Mesh deformation, animation and Morphing system. -Over 50 modifiers such as Bend, Twist, FFD, Displace. -Wave in a pond at1:24 in the first video. MegaFlowMegaFlow plugin for Unity3D Fluid flow simulation. CFD: Computational Fluid Dynamics using PDEs (partial deferential equations.) Volumetric rendering is challenging.
  • Slide 62
  • MegaFiersMegaFiers / MegaFlow plugin for Unity3DMegaFlow Mesh deformation example: Bending. Morphing example: Lysosomes.
  • Slide 63
  • Surface Morphing: -Mesh deformation via changing vertex values (geometry and attributes) of the surface mesh. -The surface mesh could represent the enclosure of a solid object. Volumetric Morphing / Deformation: Deformation based on changing the representation of a volume. Voxel (Volume Element) based processing algorithms. Voxel What could be changed: geometry, attributes, and topology (e.g. iso-surface generation).