SlideShare a Scribd company logo
1 of 32
XPEC
Senior software engineer
Ellison Mu
2012.9.20
1
 Game Platforms
 3D EngineArchitecture
 Graphics Pipeline
 Q&A
2
Console
• PS3
• XBOX 360
• Wii
Desktop
• Windows
• Linux
• Mac OSX
Handheld
Device
• NDS, N3DS
• PSP,Vita
• iPhone/iPad
• Android devices
Web
Browser
• IE:ActiveX
• Chrome,
FireFox,
Safori…: NPAPI
3
4
Target platform?
Tools pipeline?
Programming language?
Game design?
Reach or Rich?
5
Decide
model
format
Scene
management
Draw surface
Render
module
Material
system
6
7
 As possible as minimize draw surface
 View frustum culling
8
 As possible as minimize draw surface
 Tree hierarchy
▪ BSP
▪ Quad-Tree
▪ Oct-Tree
▪ KD-Tree
9
10
 As possible as minimize draw surface
 Preprocess visibility determination
11
12
 As possible as minimize draw surface
 Preprocess visibility determination
13
Vertex
buffer
Index
buffer
Material
• Texture
• Render state
• Shader
Execute
draw call
14
 Different platform provides different render
API
 DirectX
 OpenGL
 OpenGL ES
 Customized API
15
Non-platform-dependency codes
Render Layer Game Logic
Scene
Manager
Abstract
layer
Platform
dependency
codes
Software
development
kit
16
17
Vertex
Index
Stream
3D API
Commands
Assembled
Primitives
Pixel
Updates
Pixel
Location
Stream
Programmable
Fragment
Processor
Transformed
Vertices
Programmable
Vertex
Processor
GPU
Front End
Primitive
Assembly
Frame
Buffer
Raster
Operations
Rasterization
and
Interpolation
3D API:
OpenGL or
Direct3D
3D
Application
Or Game
Pre-transformed
Vertices
Pre-transformed
Fragments
Transformed
Fragments
GPU
Command&
DataStream
CPU-GPU Boundary (AGP/PCIe)
Programmable pipeline
18
19
(x, y, z)
(r, g, b,a)
(Nx,Ny,Nz)
(tx, ty,[tz])
(tx, ty)
(tx, ty)
Vertex Image F(x,y) = (r,g,b,a)
Material
properties*
 Without indexing
 With indexing
20
 Vertices mapped from object space to world
space
 M = model transformation (scene)
 V = view transformation (camera)
21
X’
Y’
Z’
W’
X
Y
Z
1M *V *
 Operate on a vertex to transform it into the
viewport space
 The viewport is two-dimensional: however,
vertex z-value is retained for depth testing.
22
 All primitives are now converted to
fragments.
 Data type change !Vertices to fragments
 The rasterizer produces a stream of
fragments.
23
Fragment attributes:
(r,g,b,a)
(x,y,z,w)
(tx,ty), …
24
Color R G B A
Position X Y Z W
Texture
coordinates
X Y [Z] -
Texture
coordinates
X Y [Z] -
…
Interpolated from
vertex information
X Y Z W
Input: Fragment
Attributes
 Color(v) = emissive + ambient + diffuse +
specular
 Each term in the right hand side is a function
of the vertex color, position, normal and
material properties.
25
 Each fragment undergoes a series of tests.
 Scissor
 Alpha
 Stencil
 Depth
26
 Blending: pixels are accumulated into final
framebuffer storage
new-val = pixel-value op old-val
new-val = SrcColor * A + DstColor * B
27
28
Fragment
Processor
Vertex
Processor
GPU
Front End
Primitive
Assembly
Raster
Operations
Rasterization
and
Interpolation
 Lock index buffer, vertex buffer, texture
 Create device, index buffer, vertex buffer,
texture
 Destroy device, index buffer, vertex buffer,
texture
 VaildateDevice
 Present
 Command buffer is full
 Query::GetData
29
 Group similar material
 Avoid redundant state change
 Adv:
 Reduce probability of full command buffer
 Separate transparent / Opaque objects
30
 Static / Dynamic type
 Share buffer is better
 Large buffer is better
31
Thank you for attending
32

More Related Content

What's hot

Gdc 14 bringing unreal engine 4 to open_gl
Gdc 14 bringing unreal engine 4 to open_glGdc 14 bringing unreal engine 4 to open_gl
Gdc 14 bringing unreal engine 4 to open_gl
changehee lee
 

What's hot (19)

Cocos2d game programming 2
Cocos2d game programming 2Cocos2d game programming 2
Cocos2d game programming 2
 
A Certain Slant of Light - Past, Present and Future Challenges of Global Illu...
A Certain Slant of Light - Past, Present and Future Challenges of Global Illu...A Certain Slant of Light - Past, Present and Future Challenges of Global Illu...
A Certain Slant of Light - Past, Present and Future Challenges of Global Illu...
 
Gdc 14 bringing unreal engine 4 to open_gl
Gdc 14 bringing unreal engine 4 to open_glGdc 14 bringing unreal engine 4 to open_gl
Gdc 14 bringing unreal engine 4 to open_gl
 
CEDEC 2018 - Towards Effortless Photorealism Through Real-Time Raytracing
CEDEC 2018 - Towards Effortless Photorealism Through Real-Time RaytracingCEDEC 2018 - Towards Effortless Photorealism Through Real-Time Raytracing
CEDEC 2018 - Towards Effortless Photorealism Through Real-Time Raytracing
 
Future Directions for Compute-for-Graphics
Future Directions for Compute-for-GraphicsFuture Directions for Compute-for-Graphics
Future Directions for Compute-for-Graphics
 
AAA game in XNA ? Miner wars 2081
AAA game in XNA ? Miner wars 2081AAA game in XNA ? Miner wars 2081
AAA game in XNA ? Miner wars 2081
 
3D Game development using Blender and Java
3D Game development using Blender and Java3D Game development using Blender and Java
3D Game development using Blender and Java
 
Decima Engine: Visibility in Horizon Zero Dawn
Decima Engine: Visibility in Horizon Zero DawnDecima Engine: Visibility in Horizon Zero Dawn
Decima Engine: Visibility in Horizon Zero Dawn
 
game development
game  developmentgame  development
game development
 
Optimizing Unity games for mobile devices
Optimizing Unity games for mobile devicesOptimizing Unity games for mobile devices
Optimizing Unity games for mobile devices
 
【Unite 2017 Tokyo】インスタンシングを用いた美麗なグラフィックの実現方法
【Unite 2017 Tokyo】インスタンシングを用いた美麗なグラフィックの実現方法【Unite 2017 Tokyo】インスタンシングを用いた美麗なグラフィックの実現方法
【Unite 2017 Tokyo】インスタンシングを用いた美麗なグラフィックの実現方法
 
Authoring of procedural rocks in The Blacksmith realtime short
Authoring of procedural rocks in The Blacksmith realtime shortAuthoring of procedural rocks in The Blacksmith realtime short
Authoring of procedural rocks in The Blacksmith realtime short
 
【Unite 2017 Tokyo】Anima2Dについて語るで!2Dアニメーションの未来
【Unite 2017 Tokyo】Anima2Dについて語るで!2Dアニメーションの未来【Unite 2017 Tokyo】Anima2Dについて語るで!2Dアニメーションの未来
【Unite 2017 Tokyo】Anima2Dについて語るで!2Dアニメーションの未来
 
2 Dimensions Of Awesome: Advanced ActionScript For Platform Games by Iain Lobb
2 Dimensions Of Awesome: Advanced ActionScript For Platform Games by Iain Lobb2 Dimensions Of Awesome: Advanced ActionScript For Platform Games by Iain Lobb
2 Dimensions Of Awesome: Advanced ActionScript For Platform Games by Iain Lobb
 
Umbra Ignite 2015: Jérémy Virga – Dishonored 2 rendering engine architecture ...
Umbra Ignite 2015: Jérémy Virga – Dishonored 2 rendering engine architecture ...Umbra Ignite 2015: Jérémy Virga – Dishonored 2 rendering engine architecture ...
Umbra Ignite 2015: Jérémy Virga – Dishonored 2 rendering engine architecture ...
 
Umbra Ignite 2015: Graham Wihlidal – Adapting a technology stream to ever-evo...
Umbra Ignite 2015: Graham Wihlidal – Adapting a technology stream to ever-evo...Umbra Ignite 2015: Graham Wihlidal – Adapting a technology stream to ever-evo...
Umbra Ignite 2015: Graham Wihlidal – Adapting a technology stream to ever-evo...
 
Fast rendering with starling
Fast rendering with starlingFast rendering with starling
Fast rendering with starling
 
【Unite 2017 Tokyo】Unityを使ったNintendo Switch™ローンチタイトル制作~スーパーボンバーマンRの事例~
【Unite 2017 Tokyo】Unityを使ったNintendo Switch™ローンチタイトル制作~スーパーボンバーマンRの事例~【Unite 2017 Tokyo】Unityを使ったNintendo Switch™ローンチタイトル制作~スーパーボンバーマンRの事例~
【Unite 2017 Tokyo】Unityを使ったNintendo Switch™ローンチタイトル制作~スーパーボンバーマンRの事例~
 
Developing a Multiplayer RTS with the Unreal Engine 3
Developing a Multiplayer RTS with the Unreal Engine 3Developing a Multiplayer RTS with the Unreal Engine 3
Developing a Multiplayer RTS with the Unreal Engine 3
 

Viewers also liked (10)

Noveno
NovenoNoveno
Noveno
 
How to make a title screen
How to make a title screenHow to make a title screen
How to make a title screen
 
Horario reuniones de área
Horario reuniones de áreaHorario reuniones de área
Horario reuniones de área
 
Once
OnceOnce
Once
 
Tavin.CV
Tavin.CVTavin.CV
Tavin.CV
 
Comisión Nacional de los Derechos Humanos
Comisión Nacional de los Derechos HumanosComisión Nacional de los Derechos Humanos
Comisión Nacional de los Derechos Humanos
 
Harness The Power Of Auto Cad Map And Esri
Harness The Power Of Auto Cad Map And EsriHarness The Power Of Auto Cad Map And Esri
Harness The Power Of Auto Cad Map And Esri
 
Bus de la calidad
Bus de la calidadBus de la calidad
Bus de la calidad
 
Comunicado no 01 de 2017
Comunicado no 01 de 2017Comunicado no 01 de 2017
Comunicado no 01 de 2017
 
Pierre BOUVAIS-CVdetailled
Pierre BOUVAIS-CVdetailledPierre BOUVAIS-CVdetailled
Pierre BOUVAIS-CVdetailled
 

Similar to Introduce to 3d rendering engine

Minko stage3d workshop_20130525
Minko stage3d workshop_20130525Minko stage3d workshop_20130525
Minko stage3d workshop_20130525
Minko3D
 
thu-blake-gdc-2014-final
thu-blake-gdc-2014-finalthu-blake-gdc-2014-final
thu-blake-gdc-2014-final
Robert Taylor
 
Frostbite Rendering Architecture and Real-time Procedural Shading & Texturing...
Frostbite Rendering Architecture and Real-time Procedural Shading & Texturing...Frostbite Rendering Architecture and Real-time Procedural Shading & Texturing...
Frostbite Rendering Architecture and Real-time Procedural Shading & Texturing...
Johan Andersson
 

Similar to Introduce to 3d rendering engine (20)

Minko stage3d workshop_20130525
Minko stage3d workshop_20130525Minko stage3d workshop_20130525
Minko stage3d workshop_20130525
 
Programmable Piplelines
Programmable PiplelinesProgrammable Piplelines
Programmable Piplelines
 
Cg Chap 02
Cg Chap 02Cg Chap 02
Cg Chap 02
 
XNAPresentation
XNAPresentationXNAPresentation
XNAPresentation
 
Pixel-Lab / Games:EDU / Michel Kripalani / Games Industry Overview and Trends
Pixel-Lab / Games:EDU / Michel Kripalani / Games Industry Overview and TrendsPixel-Lab / Games:EDU / Michel Kripalani / Games Industry Overview and Trends
Pixel-Lab / Games:EDU / Michel Kripalani / Games Industry Overview and Trends
 
A Scalable Real-Time Many-Shadowed-Light Rendering System
A Scalable Real-Time Many-Shadowed-Light Rendering SystemA Scalable Real-Time Many-Shadowed-Light Rendering System
A Scalable Real-Time Many-Shadowed-Light Rendering System
 
thu-blake-gdc-2014-final
thu-blake-gdc-2014-finalthu-blake-gdc-2014-final
thu-blake-gdc-2014-final
 
The next generation of GPU APIs for Game Engines
The next generation of GPU APIs for Game EnginesThe next generation of GPU APIs for Game Engines
The next generation of GPU APIs for Game Engines
 
Frostbite Rendering Architecture and Real-time Procedural Shading & Texturing...
Frostbite Rendering Architecture and Real-time Procedural Shading & Texturing...Frostbite Rendering Architecture and Real-time Procedural Shading & Texturing...
Frostbite Rendering Architecture and Real-time Procedural Shading & Texturing...
 
4K Checkerboard in Battlefield 1 and Mass Effect Andromeda
4K Checkerboard in Battlefield 1 and Mass Effect Andromeda4K Checkerboard in Battlefield 1 and Mass Effect Andromeda
4K Checkerboard in Battlefield 1 and Mass Effect Andromeda
 
Beginning direct3d gameprogramming01_thehistoryofdirect3dgraphics_20160407_ji...
Beginning direct3d gameprogramming01_thehistoryofdirect3dgraphics_20160407_ji...Beginning direct3d gameprogramming01_thehistoryofdirect3dgraphics_20160407_ji...
Beginning direct3d gameprogramming01_thehistoryofdirect3dgraphics_20160407_ji...
 
Abc of DirectX
Abc of DirectXAbc of DirectX
Abc of DirectX
 
XNA Intro Workshop
XNA Intro WorkshopXNA Intro Workshop
XNA Intro Workshop
 
02 direct3 d_pipeline
02 direct3 d_pipeline02 direct3 d_pipeline
02 direct3 d_pipeline
 
WT-4065, Superconductor: GPU Web Programming for Big Data Visualization, by ...
WT-4065, Superconductor: GPU Web Programming for Big Data Visualization, by  ...WT-4065, Superconductor: GPU Web Programming for Big Data Visualization, by  ...
WT-4065, Superconductor: GPU Web Programming for Big Data Visualization, by ...
 
Don't Call It a Comeback: Attribute Grammars for Big Data Visualization
Don't Call It a Comeback: Attribute Grammars for Big Data VisualizationDon't Call It a Comeback: Attribute Grammars for Big Data Visualization
Don't Call It a Comeback: Attribute Grammars for Big Data Visualization
 
NvFX GTC 2013
NvFX GTC 2013NvFX GTC 2013
NvFX GTC 2013
 
Using The New Flash Stage3D Web Technology To Build Your Own Next 3D Browser ...
Using The New Flash Stage3D Web Technology To Build Your Own Next 3D Browser ...Using The New Flash Stage3D Web Technology To Build Your Own Next 3D Browser ...
Using The New Flash Stage3D Web Technology To Build Your Own Next 3D Browser ...
 
Next generation graphics programming on xbox 360
Next generation graphics programming on xbox 360Next generation graphics programming on xbox 360
Next generation graphics programming on xbox 360
 
Computer Graphics Part1
Computer Graphics Part1Computer Graphics Part1
Computer Graphics Part1
 

More from Daosheng Mu (7)

Webrender 1.0
Webrender 1.0Webrender 1.0
Webrender 1.0
 
Maze VR
Maze VRMaze VR
Maze VR
 
A frame beginner lesson
A frame beginner lessonA frame beginner lesson
A frame beginner lesson
 
Introduction to A-Frame
Introduction to A-FrameIntroduction to A-Frame
Introduction to A-Frame
 
Introduction to WebGL and WebVR
Introduction to WebGL and WebVRIntroduction to WebGL and WebVR
Introduction to WebGL and WebVR
 
Direct3D to WPF
Direct3D to WPFDirect3D to WPF
Direct3D to WPF
 
Order independent transparency
Order independent transparencyOrder independent transparency
Order independent transparency
 

Recently uploaded

Recently uploaded (20)

Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
 
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
 
Automating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps ScriptAutomating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps Script
 
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
 
Slack Application Development 101 Slides
Slack Application Development 101 SlidesSlack Application Development 101 Slides
Slack Application Development 101 Slides
 
What Are The Drone Anti-jamming Systems Technology?
What Are The Drone Anti-jamming Systems Technology?What Are The Drone Anti-jamming Systems Technology?
What Are The Drone Anti-jamming Systems Technology?
 
The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024
 
Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt Robison
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)
 
The Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxThe Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptx
 
How to convert PDF to text with Nanonets
How to convert PDF to text with NanonetsHow to convert PDF to text with Nanonets
How to convert PDF to text with Nanonets
 
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day Presentation
 
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organization
 
08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men
 
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfThe Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
 
Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024
 
2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...
 
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
 

Introduce to 3d rendering engine