ShaderEffect.PixelShaderConstantCallback(Int32) 方法
定義
重要
部分資訊涉及發行前產品,在發行之前可能會有大幅修改。 Microsoft 對此處提供的資訊,不做任何明確或隱含的瑕疵擔保。
將相依屬性值與像素著色器的浮點數常數暫存器關聯起來。
protected:
static System::Windows::PropertyChangedCallback ^ PixelShaderConstantCallback(int floatRegisterIndex);
protected static System.Windows.PropertyChangedCallback PixelShaderConstantCallback(int floatRegisterIndex);
static member PixelShaderConstantCallback : int -> System.Windows.PropertyChangedCallback
Protected Shared Function PixelShaderConstantCallback (floatRegisterIndex As Integer) As PropertyChangedCallback
參數
- floatRegisterIndex
- Int32
與相依屬性相關的著色器暫存器的索引。
傳回
一個 PropertyChangedCallback 代理,將依賴屬性與由 floatRegisterIndex指定的著色器常數暫存器關聯起來。
例外狀況
依賴性質是一種未知類型。
floatRegisterIndex 大於或等於32,或 floatRegisterIndex 小於0。
備註
在註冊著色器常數的相依屬性時,使用這個 PixelShaderConstantCallback 方法。 該 PixelShaderConstantCallback 方法構建一個 PropertyChangedCallback 代理,當被呼叫時,會在依賴性質與由 floatRegisterIndex所指定的著色器常數暫存器之間建立關聯。