Last active
December 7, 2018 02:38
-
-
Save baobao/579848e2ab50a2aae3e9e01e81080c55 to your computer and use it in GitHub Desktop.
SlimDX 回転行列を生成してそれをシェーダに渡す部分コード
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// 回転行列生成 | |
var axis = new Vector3(0.5f, 0, 1f); | |
var rotateMatrix = Matrix.RotationAxis(axis, radian); | |
// 回転行列をシェーダに渡す | |
var matrix = effect.GetVariableByName("RotateMatrix"); | |
matrix.AsMatrix().SetMatrix(rotateMatrix); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment