Changing material preview scene
-
THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED
On 30/09/2007 at 11:46, xxxxxxxx wrote:
User Information:
Cinema 4D Version: 10.1
Platform:
Language(s) : C++ ;---------
Can anyone help me out with how to change a basic material to a different built-in preview scene?
TIA
- Rick -
THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED
On 01/10/2007 at 03:56, xxxxxxxx wrote:
I think one of the shader examples in the SDK uses a custom preview scene, that might help you get started.
regards
/Filip -
THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED
On 02/10/2007 at 03:59, xxxxxxxx wrote:
This is how you change the preview to one of the build-in scenes for a standard Cinema4D material.
> _
> GeData d;
> if(mymat->GetParameter(DescLevel(MATERIAL_PREVIEW),d,0))
> {
> MaterialPreviewData *mpd = (MaterialPreviewData* )d.GetCustomDataType(CUSTOMDATATYPE_MATPREVIEW);
> if(mpd)
> {
> mpd->SetPreviewType(MatPreviewTorus);
> mymat->SetParameter(DescLevel(MATERIAL_PREVIEW),d,0);
> }
> }
> _You find the other definitions for the preview type in the docu under MatPreviewType.
cheers,
Matthias -
THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED
On 05/10/2007 at 16:10, xxxxxxxx wrote:
thanks Matthias - that's exactly what I needed