Diese Präsentation wurde erfolgreich gemeldet.
Wir verwenden Ihre LinkedIn Profilangaben und Informationen zu Ihren Aktivitäten, um Anzeigen zu personalisieren und Ihnen relevantere Inhalte anzuzeigen. Sie können Ihre Anzeigeneinstellungen jederzeit ändern.
‫روشهای‬‫برنامه‬‫نویسی‬
‫انیمیشن‬
‫برای‬
‫بازی‬‫های‬‫رایانه‬‫ای‬
‫امیرحسین‬‫فصیحی‬
‫فن‬‫افزار‬‫شریف‬
‫تیر‬1391
‫اهداف‬
•‫مروری‬‫بر‬‫روشهای‬‫فنی‬‫پیاده‬‫سازی‬‫انیمیشن‬‫در‬‫بازی‬‫ها‬
•‫روشهای‬‫بهینه‬‫سازی‬
•‫بررسی‬‫روش‬‫های‬‫جدید‬
•‫آش...
‫انواع‬‫روشهای‬‫پیاده‬‫سازی‬‫انیمیشن‬‫در‬‫بازی‬
• Cel Animation
• Billboards with animated textures
• Rigid Hierarchical
•...
Cel Animation
3D Animation
•‫بازی‬Doom
oQuad‫هایی‬‫به‬‫سمت‬‫دوربین‬
oAnimated Texture
3D Animation
Rigid Hierarchical Animation
Per Vertex Animation / Morph Target
Facial Morph Demo Video
Skinned Animation
Skinned Animation
• Software Skinning
• Hardware Skinning (GPU shaders)
Automatic Rigging
http://www.mit.edu/~ibaran/autorig/
‫زمان‬‫در‬‫انیمیشن‬
• Pose Interpolation / Continuous Time
• Time unit (seconds/frames)
• Frame/Sample
ttt = 0.2 ttt = 0.8...
‫قالب‬‫داده‬‫ای‬‫برای‬‫انیمیشن‬
• Joint 1
o Keyframe 1
 Translation
• x, y, z
 Orientation
• x, y, z, w
 Scale
• x, y, ...
‫انیمیشن‬‫به‬‫عنوان‬‫روش‬‫فشرده‬‫سازی‬
‫اطالعات‬‫الزم‬:‫موقعیت‬‫هر‬vertex‫در‬‫هر‬‫لحظه‬‫از‬‫زمان‬.
‫هدف‬:‫ذخیره‬‫کمترین‬‫ا...
Animation Retargeting
• Real-time motion retargetting to highly varied
user created morphologies (Spore)
• http://chrishec...
Havok Animation Retargeting Video
Metachannels
• Events
o Time = 0.5
 footstep left
o Time = 1.5
 footstep right
o ...
• ...
Animation Blending
LERP Blending
• Temporal Interpolation
• Motion Continuity (Cross Fading)
• Directional Locomotion
o Ta...
Blending
• Partial skeleton blending
• Additive blending
o Stance variation
o Locomotion noise
o Aim and look at
o Overloa...
Partial Blending
Uncharted 2
Additive Blending
Blend Trees
Blend Tree
UDK Blend Tree Video
Post Processing
• Procedural Animation
• Inverse Kinematics
• Ragdolls
Ragdolls
Ragdolls in Diablo 3 (box2d.googlecode.com/files/GDC2012_ErinCatto_Ragdolls.pdf)
Leg IK
Animation Pipeline
• Clip decompression and pose extraction
• Pose blending
• Global pose generation
• Post-processing
• R...
‫بهینه‬‫سازی‬‫انیمیشن‬
•‫استفاده‬‫از‬‫حافظه‬‫کمتر‬
•‫استفاده‬‫از‬‫حافظه‬‫بصورت‬cache friendly
‫کمتر‬ ‫حافظه‬ ‫از‬ ‫استفاده‬–‫سازی‬ ‫فشرده‬
• Channel Omission
• Quantization
o Scalar Quantization
(Jonathan Blow: http:...
Curve Based Compression (B-Splines)
30fps -> 90 frames -> 90 * 32bits = 27180 bits
Curve Fitting -> 7 data points -> 7 * 3...
CPU Cache
Bitsquid Engine (Low Level Animation System)
http://bitsquid.blogspot.com/2009/11/bitsquid-low-level-animation-s...
Multithreaded Animation
• Intel Horsepower demo:
http://software.intel.com/en-us/articles/horsepower-source-code-download/
Intel Horsepower Demo
Single Threaded Animation
Intel Horsepower Demo
Multithreaded Animation
Animation Layering
Face Layer - Partial
Hand Layer - Partial
Hair Layer - Partial
Base Layer - Full Body
Run Randomness La...
Physics Based Animation
•‫شبیه‬‫سازی‬‫فیزیکی‬‫برای‬‫مدل‬
•‫استفاده‬‫از‬‫انیمیشن‬‫از‬‫پیش‬‫تعریف‬‫شده‬
•‫ترکیب‬‫شبیه‬‫سازی‬...
Dynamic, data-driven character control with
adjustable balance, Dynamo
http://graphics.cs.williams.edu/papers/DynamoVGS06
Dynamo Video - Adaptation
Dynamo Video - Balance
Dynamo - Boxing
Dynamo - Failure
Dynamic Response for Motion
Capture Animation
http://graphics.cs.ucr.edu/projects/dynResp/mocsim2.html
Dynamic Response
Dynamic Motion Synthesis
• Natural Motion (Endorphin, Euphoria)
http://naturalmotion.com
• Games
o Read Dead Redemption
o ...
Natural Motion - Euphoria
‫پایه‬‫فناوری‬
‫شبکه‬‫عصبی‬‫و‬‫الگوریتم‬‫های‬‫ژنتیکی‬
Dynamic Motion Synthesis – Read Dead
Redemption
Dynamic Motion Synthesis – GTA IV
Dynamic Motion Synthesis – Star Wars, Force
Unleashed
Parametric Motion Graphs
•‫ذخیره‬‫داده‬‫های‬‫حرکتی‬،‫عمدتا‬‫از‬Motion Capture
•‫آنالیز‬‫داده‬‫ها‬‫و‬‫ساخت‬Motion Graph
•‫ا...
Motion Graphs Research
Motion Graphs
http://research.cs.wisc.edu/graphics/Papers/Gleicher/Mocap/mograph.pdf
Parametric Mot...
Parametric Motion Graphs Demo Video
‫انیمیشن‬‫و‬‫هوش‬‫مصنوعی‬
•‫انتخاب‬‫حرکت‬
oMotion Graph
o‫فیزیکی‬
active
passive
•‫هم‬‫راستا‬‫با‬‫تحقیقات‬‫کنترل‬‫و‬‫روب...
Animation-Driven Locomotion
Animation Driven Locomotion for Smoother
Navigation (GDC 2012)
Bobby Anguelov
AI Programmer IO...
‫میان‬‫افزارهای‬‫انیمیشن‬
• Natural Motion, Morpheme
• Autodesk, HumanIK
• RAD Game Tools, Granny
• Havok Animation/Behavi...
Animation Middleware - Alienmotion
• Game Engine Architecture, Jason Gregory
• Bisquid.se
• Game Programming Gems Series
• AI Game Programming Wisdom Series
...
‫سوال؟‬
fassihi@fanafzar.com
@ahfassihi
Nächste SlideShare
Wird geladen in …5
×

4

Teilen

Herunterladen, um offline zu lesen

Animation Programming Techniques

Herunterladen, um offline zu lesen

Presented at IRGF 2012.

Ähnliche Bücher

Kostenlos mit einer 30-tägigen Testversion von Scribd

Alle anzeigen

Ähnliche Hörbücher

Kostenlos mit einer 30-tägigen Testversion von Scribd

Alle anzeigen

Animation Programming Techniques

  1. 1. ‫روشهای‬‫برنامه‬‫نویسی‬ ‫انیمیشن‬ ‫برای‬ ‫بازی‬‫های‬‫رایانه‬‫ای‬ ‫امیرحسین‬‫فصیحی‬ ‫فن‬‫افزار‬‫شریف‬ ‫تیر‬1391
  2. 2. ‫اهداف‬ •‫مروری‬‫بر‬‫روشهای‬‫فنی‬‫پیاده‬‫سازی‬‫انیمیشن‬‫در‬‫بازی‬‫ها‬ •‫روشهای‬‫بهینه‬‫سازی‬ •‫بررسی‬‫روش‬‫های‬‫جدید‬ •‫آشنایی‬‫با‬‫بعضی‬‫حوزه‬‫های‬‫تحقیقاتی‬‫علمی‬ •‫تحلیل‬‫فناوری‬‫های‬‫انیمیشن‬‫در‬‫برخی‬‫از‬‫بازی‬‫های‬‫روز‬ •‫میان‬‫افزارهای‬‫انیمیشن‬
  3. 3. ‫انواع‬‫روشهای‬‫پیاده‬‫سازی‬‫انیمیشن‬‫در‬‫بازی‬ • Cel Animation • Billboards with animated textures • Rigid Hierarchical • Vertex Animation • Skinned Animation
  4. 4. Cel Animation
  5. 5. 3D Animation •‫بازی‬Doom oQuad‫هایی‬‫به‬‫سمت‬‫دوربین‬ oAnimated Texture
  6. 6. 3D Animation Rigid Hierarchical Animation
  7. 7. Per Vertex Animation / Morph Target
  8. 8. Facial Morph Demo Video
  9. 9. Skinned Animation
  10. 10. Skinned Animation • Software Skinning • Hardware Skinning (GPU shaders)
  11. 11. Automatic Rigging http://www.mit.edu/~ibaran/autorig/
  12. 12. ‫زمان‬‫در‬‫انیمیشن‬ • Pose Interpolation / Continuous Time • Time unit (seconds/frames) • Frame/Sample ttt = 0.2 ttt = 0.8 ttt = 1.3 Keyframe 1 Keyframe 2 Keyframe 3
  13. 13. ‫قالب‬‫داده‬‫ای‬‫برای‬‫انیمیشن‬ • Joint 1 o Keyframe 1  Translation • x, y, z  Orientation • x, y, z, w  Scale • x, y, z o Keyframe 2  Translation • ..... o .... • Joint 2 o ....
  14. 14. ‫انیمیشن‬‫به‬‫عنوان‬‫روش‬‫فشرده‬‫سازی‬ ‫اطالعات‬‫الزم‬:‫موقعیت‬‫هر‬vertex‫در‬‫هر‬‫لحظه‬‫از‬‫زمان‬. ‫هدف‬:‫ذخیره‬‫کمترین‬‫اطالعات‬
  15. 15. Animation Retargeting • Real-time motion retargetting to highly varied user created morphologies (Spore) • http://chrishecker.com/Real-time_motion_retargeting_to_highly_varied_user-created_morphologies • Feature points based facial animation retargetting • http://dl.acm.org/citation.cfm?id=1450621
  16. 16. Havok Animation Retargeting Video
  17. 17. Metachannels • Events o Time = 0.5  footstep left o Time = 1.5  footstep right o ... • ...
  18. 18. Animation Blending LERP Blending • Temporal Interpolation • Motion Continuity (Cross Fading) • Directional Locomotion o Targeted Movement o Pivotal Movement • Complex LERP Blend o Generalized one dimensional o Simple Two dimensional o Triangular Two dimensional o Generalized Two dimensional
  19. 19. Blending • Partial skeleton blending • Additive blending o Stance variation o Locomotion noise o Aim and look at o Overloading time axis
  20. 20. Partial Blending Uncharted 2
  21. 21. Additive Blending
  22. 22. Blend Trees
  23. 23. Blend Tree
  24. 24. UDK Blend Tree Video
  25. 25. Post Processing • Procedural Animation • Inverse Kinematics • Ragdolls
  26. 26. Ragdolls Ragdolls in Diablo 3 (box2d.googlecode.com/files/GDC2012_ErinCatto_Ragdolls.pdf)
  27. 27. Leg IK
  28. 28. Animation Pipeline • Clip decompression and pose extraction • Pose blending • Global pose generation • Post-processing • Recalculation of global poses • Matrix palette generation
  29. 29. ‫بهینه‬‫سازی‬‫انیمیشن‬ •‫استفاده‬‫از‬‫حافظه‬‫کمتر‬ •‫استفاده‬‫از‬‫حافظه‬‫بصورت‬cache friendly
  30. 30. ‫کمتر‬ ‫حافظه‬ ‫از‬ ‫استفاده‬–‫سازی‬ ‫فشرده‬ • Channel Omission • Quantization o Scalar Quantization (Jonathan Blow: http://number- none.com/product/Scalar%20Quantization/index.html) • Sample Frequency and Key Omission • Curve Based Compression (B-Splines, Granny) • Selective Loading and Streaming
  31. 31. Curve Based Compression (B-Splines) 30fps -> 90 frames -> 90 * 32bits = 27180 bits Curve Fitting -> 7 data points -> 7 * 32bits = 224 bits t = 3 sec q
  32. 32. CPU Cache Bitsquid Engine (Low Level Animation System) http://bitsquid.blogspot.com/2009/11/bitsquid-low-level-animation-system.html http://bitsquid.blogspot.com/2011/10/low-level-animation-part-2.html
  33. 33. Multithreaded Animation • Intel Horsepower demo: http://software.intel.com/en-us/articles/horsepower-source-code-download/
  34. 34. Intel Horsepower Demo Single Threaded Animation
  35. 35. Intel Horsepower Demo Multithreaded Animation
  36. 36. Animation Layering Face Layer - Partial Hand Layer - Partial Hair Layer - Partial Base Layer - Full Body Run Randomness Layer - Additive Weapon Layer - Partial Breathing Layer - Additive Animation and Player Control in Uncharted 1 & 2, Travis McIntosh, GDC 2010
  37. 37. Physics Based Animation •‫شبیه‬‫سازی‬‫فیزیکی‬‫برای‬‫مدل‬ •‫استفاده‬‫از‬‫انیمیشن‬‫از‬‫پیش‬‫تعریف‬‫شده‬ •‫ترکیب‬‫شبیه‬‫سازی‬‫و‬‫انیمیشن‬ •‫اعمال‬‫انیمیشن‬‫بر‬‫روی‬‫اعضای‬‫فیزیکی‬‫و‬‫سپس‬‫شبیه‬‫س‬‫ازی‬
  38. 38. Dynamic, data-driven character control with adjustable balance, Dynamo http://graphics.cs.williams.edu/papers/DynamoVGS06
  39. 39. Dynamo Video - Adaptation
  40. 40. Dynamo Video - Balance
  41. 41. Dynamo - Boxing
  42. 42. Dynamo - Failure
  43. 43. Dynamic Response for Motion Capture Animation http://graphics.cs.ucr.edu/projects/dynResp/mocsim2.html
  44. 44. Dynamic Response
  45. 45. Dynamic Motion Synthesis • Natural Motion (Endorphin, Euphoria) http://naturalmotion.com • Games o Read Dead Redemption o GTA IV o Star Wars: The Force Unleashed
  46. 46. Natural Motion - Euphoria
  47. 47. ‫پایه‬‫فناوری‬
  48. 48. ‫شبکه‬‫عصبی‬‫و‬‫الگوریتم‬‫های‬‫ژنتیکی‬
  49. 49. Dynamic Motion Synthesis – Read Dead Redemption
  50. 50. Dynamic Motion Synthesis – GTA IV
  51. 51. Dynamic Motion Synthesis – Star Wars, Force Unleashed
  52. 52. Parametric Motion Graphs •‫ذخیره‬‫داده‬‫های‬‫حرکتی‬،‫عمدتا‬‫از‬Motion Capture •‫آنالیز‬‫داده‬‫ها‬‫و‬‫ساخت‬Motion Graph •‫انجام‬‫جستجوی‬real-time‫در‬‫هنگام‬‫اجرای‬‫بازی‬
  53. 53. Motion Graphs Research Motion Graphs http://research.cs.wisc.edu/graphics/Papers/Gleicher/Mocap/mograph.pdf Parametric Motion Graphs http://pages.cs.wisc.edu/~heckr/Papers/PMGFullPaper.pdf
  54. 54. Parametric Motion Graphs Demo Video
  55. 55. ‫انیمیشن‬‫و‬‫هوش‬‫مصنوعی‬ •‫انتخاب‬‫حرکت‬ oMotion Graph o‫فیزیکی‬ active passive •‫هم‬‫راستا‬‫با‬‫تحقیقات‬‫کنترل‬‫و‬‫روباتیک‬
  56. 56. Animation-Driven Locomotion Animation Driven Locomotion for Smoother Navigation (GDC 2012) Bobby Anguelov AI Programmer IO Interactive Gabriel Leblanc AI Programmer, Eidos Shawn Harris Senior Programmer, Big Huge Games
  57. 57. ‫میان‬‫افزارهای‬‫انیمیشن‬ • Natural Motion, Morpheme • Autodesk, HumanIK • RAD Game Tools, Granny • Havok Animation/Behavior • Chemical Games, Alienmotion
  58. 58. Animation Middleware - Alienmotion
  59. 59. • Game Engine Architecture, Jason Gregory • Bisquid.se • Game Programming Gems Series • AI Game Programming Wisdom Series • gamasutra.com ‫سایر‬‫منابع‬
  60. 60. ‫سوال؟‬ fassihi@fanafzar.com @ahfassihi
  • SinaTaromian

    Sep. 18, 2019
  • mojtabashafaie

    May. 9, 2018
  • MiladKeramatloo

    Jan. 23, 2016
  • BehzadBigdeli

    Nov. 14, 2015

Presented at IRGF 2012.

Aufrufe

Aufrufe insgesamt

759

Auf Slideshare

0

Aus Einbettungen

0

Anzahl der Einbettungen

4

Befehle

Downloads

36

Geteilt

0

Kommentare

0

Likes

4

×