Direct3D 12简介
Direct3D 12简介
DirectX 12是Microsoft最新的DirectX API版本。 Direct3D随DirectX 12一起提供,Direct3D 12是DirectX API集合中的图形API(其他API包括DirectSound,DirectInput,DirectDraw等)。
Direct3D 12的性能比Direct3D的任何以前的迭代要好得多。 Direct3D提供了对图形硬件的较低级别控制,从而可以更有效地使用线程。我们能够使用多个线程来填充命令列表。拥有更多控制权的另一方面意味着我们现在要承担更多责任,例如CPU / GPU同步和内存管理。
Direct3D还通过使用预编译的管道状态对象和命令列表(bundles)来最大程度地减少CPU开销。在应用程序的初始化阶段,我们将创建许多管线状态对象,这些对象由着色器(顶点,像素等)和其他管线状态(混合,光栅化器,基本拓扑等)组成。然后,在运行时,驱动程序不必像在Direct3D 11中那样更改管道的状态,就可以创建管道状态。相反,我们提供了一个管道状态对象,当我们调用draw时,它将使用管道,而且我们没有动态创建管道状态的开销。我们还可以在初始化期间创建一组命令,这些命令可以反复使用称为Bundles的命令。
关于Direct3D的另一件很酷的事情是,它的API调用少得多,根据MSDN,它的调用数约为200(而其中大约三分之一完成了所有艰苦的工作)。
我们将在本教程中学习以下内容:
图形管道概述
- The Compute Shader
- Input Assembler (IA) Stage
- Vertex Shader (VS) Stage
- Hull Shader (HS) Stage
- Tessellator (TS) Stage
- Domain Shader (DS) Stage
- Geometry Shader (GS) Stage
- Stream Output (SO) Stage
- Rasterizer Stage (RS)
- Pixel Shader (PS) Stage
- Output Merger (OM) Stage
Direct3D 12工作原理概述
- The Device
- Pipeline State Objects
- Command Lists - Bundles
- Command Queues
- Command Allocators
- Resources
- Descriptors (Resource Views)
- Descriptor Tables
- Descriptor Heaps
- Root Signatures
- Resource Barriers
- Fences and Fence Events
- Overview of Application Flow Control for Direct3D 12
- Multithreading in Direct3D 12
初始化Direct3D 12
- Creating a device
- Creating a command queue
- Creating a swap chain
- Creating a descriptor heap
- Creating a command allocator
- Creating a root signature
- Compiling and Creating shader bytecode
- Creating a pipeline state object
- Creating a command list
- Creating a fence and fence event
参考链接:
- https://docs.microsoft.com/en-us/windows/win32/direct3d12/directx-12-programming-guide
- http://www.d3dcoder.net/
- https://www.braynzarsoft.net/viewtutorial/q16390-04-directx-12-braynzar-soft-tutorials
- https://developer.nvidia.com/dx12-dos-and-donts
- https://www.3dgep.com/learning-directx-12-1/
- https://gpuopen.com/learn/lets-learn-directx12/
- https://alain.xyz/blog/raw-directx12
- https://www.rastertek.com/tutdx12.html
- https://digitalerr0r.net/2015/08/19/quickstart-directx-12-programming/
- https://walbourn.github.io/getting-started-with-direct3d-12/
- https://docs.aws.amazon.com/lumberyard/latest/userguide/graphics-rendering-directx.html
- http://diligentgraphics.com/diligent-engine/samples/
- https://www.programmersought.com/article/2904113865/
- https://www.tutorialspoint.com/directx/directx_first_hlsl.htm
- http://rbwhitaker.wikidot.com/hlsl-tutorials
- https://digitalerr0r.net/2015/08/19/quickstart-directx-12-programming/
- https://www.ronja-tutorials.com/post/002-hlsl/
Direct3D 12简介相关推荐
- Import Changes from Direct3D 11 to Direct3D 12
译者:林公子 出处:木木的二进制人生 转载请注明作者和出处,谢谢! 这是微软公布的Direct3D 12文档的其中一篇,此翻译留作学习记录备忘,水平有限,错漏难免,还望海涵. 原文链接是https:/ ...
- Direct3D 12工作原理概述
Direct3D 12工作原理概述 这只是Direct3d 12的概述.以后的教程将更深入. Pipeline State Objects (PSO)(MSDN Pipeline States) 管道 ...
- Direct3D 12 CreateSwapChain失败
DXGI ERROR: IDXGIFactory::CreateSwapChain: Flip model swapchains (DXGI_SWAP_EFFECT_FLIP_SEQUENTIAL a ...
- Direct3D 12入门教程之 ---- Direct3D 12初始化流程
注:以下内容参考自 书籍:<DirectX 12 3D>游戏开发实战, 微软官方的 DirectX样例程序:DirectX-Graphics-Samples, 参见github链接:htt ...
- Direct3D 12入门教程之 ---- 渲染流水线介绍
本文主要参考 <DirectX 12 3D游戏开发实战>一书, 以及微软官方的Direct3D 12示例:DirectX-Graphics-Samples 渲染流水线:又称渲染管线,指的是 ...
- Direct3D 12 Preview
<span style="font-size:12px;"> 在上半年举办的GDC2014大会上,微软提供了一个DirectX12的Preview,同时通过这个prev ...
- Direct3D 12 尝鲜(五): SDK 更新
(转载请注明出处) 又是一个月, 微软在Build2015中公布了不少关于Win10的新闻, 又在N卡公布的支持DX12显卡中看到了我的垃圾显卡(GT640M LE)居然在支持范围,高高兴兴地直接换物 ...
- Direct3D 12 尝鲜: 基本呈现
(转载请注明出处) 请叫我挖坑狂魔_(:3」∠)_ 微软前几天发布了Win10的开发工具,希望使用的童鞋可以加入windows insider计划 进行下载. 下面是我的环境: Windows 10 ...
- Direct3D 12——混合——混合
混合运算 typedef enum D3D12_BLEND_OP {D3D12_BLEND_OP_ADD = 1, //添加源 1 和源 2.D3D12_BLEND_OP_SUBTRACT = 2,/ ...
最新文章
- es分布式搜索引擎在几十亿数据量级的场景下如何优化查询性能
- ArcGIS Web 应用开发框架(ADF)中的Ajax
- stm32中断优先级快速入门
- Python 实现链表和二叉树
- IDM下载速度慢解决方案全网搜集持续更新
- Spring系列(六):@Conditional注解用法介绍
- 怎么利用计算机计算潮流计算,电力系统潮流计算的目的是什么
- Richard Hamming - You and Your Research
- react-native技术调研:react-native是什么?
- eclipse中如何远程java debug配置
- Go语言核心36讲(Go语言实战与应用十九)--学习笔记
- python源代码被解释器转换后的格式_python源代码被解释器转换后的格式是什么?...
- Linux中更换软件源以及更新软件过程中报错的解决方法
- windows win10调节外接显示器亮度
- 三层交换(VLAN间路由)
- php thinkadmin自定义一个弹出弹窗批量操作功能
- js验证身份证(详细版)
- 安装Ubuntu的时候屏幕太小看不到下一步,点不到继续按钮
- 海淀区第九届单片机竞赛获奖名单_第九届蓝桥杯国赛电子类单片机设计与开发组获奖名单...
- 中国人工智能学会通讯——无智能,不驾驶——面向未来的智能驾驶时代 ( 下 )...