I want to configure and write an EffectMaterialContent, using an effect and parameters that I get from somewhere else.
I thought this would be simple -- just create an EffectMaterialContent, set the Effect to a reference to the effect, and the CompiledEffect to the appropriate compiled effect. Then just call SetTexture() with the textures I need in the effect.
Except SetTexture() is protected, so I have to derive to XEffectMaterialContent to be able to set the value.
Except when I do that, the automatic serialization of EffectMaterialContent breaks.
So how do I use this class properly to write out a compiled effect with parameters, and read back in an Effect instance with the appropriate textures?
Jon Watte, Direct3D MVP
Tweets, occasionallykW X-port 3ds Max .X exporter
kW Animation source code