Init
This commit is contained in:
@@ -0,0 +1,36 @@
|
||||
---
|
||||
title: DirectX12学习笔记(1)——DirectXMath库
|
||||
date: 2023-03-01 19:39:43
|
||||
excerpt:
|
||||
tags:
|
||||
rating: ⭐
|
||||
---
|
||||
|
||||
DXM库利用**SIMD(单指令多数据)** 可以仅使用一条指令就同时完成多个数据的运算或处理。
|
||||
|
||||
# 向量
|
||||
需要包含头文件
|
||||
```c++
|
||||
#include <DirectXMath.h>
|
||||
#include <DirectXPackedVector.h>
|
||||
```
|
||||
`DirectXPackedVector.h`的代码主要位于`DirectX::PackedVector`中。
|
||||
|
||||
## Type
|
||||
- XMVECTOR
|
||||
- XMFLOAT2
|
||||
- XMFLOAT3
|
||||
- XMFLOAT4
|
||||
|
||||
## Method
|
||||
- XMLoadFloat():XMFLOAT =>XMVECTOR
|
||||
- XMStoreFloat():XMVECTOR => XMFLOAT
|
||||
- XMVectorGet()
|
||||
- XMVectorSet()
|
||||
|
||||
# 矩阵
|
||||
## Type
|
||||
- XMMATRIX:代表一个4x4矩阵
|
||||
|
||||
## Method
|
||||
- XMMAtrixSet
|
Reference in New Issue
Block a user