依名稱取得著色器反映變數。
語法
ID3D11ShaderReflectionVariable * GetVariableByName(
[in] LPCSTR Name
);
參數
[in] Name
類型: LPCSTR
變數名稱。
傳回值
類型: ID3D11ShaderReflectionVariable*
傳回清單標記) 結尾 (sentinel 物件。 若要判斷 GetVariableByName 是否成功完成,請呼叫 ID3D11ShaderReflectionVariable::GetDesc 並檢查傳回的 HRESULT;成功以外的任何傳回值表示 GetVariableByName 失敗。
備註
這個方法的介面裝載於現用 DLL D3DCompiler_xx.dll。
規格需求
| 需求 | 值 |
|---|---|
| 目標平台 | Windows |
| 標頭 | d3d11shader.h |
| 程式庫 | D3DCompiler.lib |
| Dll | D3DCompiler_47.dll |