Can't Use Scenes in Material Preview [SOLVED]
On 15/12/2014 at 15:48, xxxxxxxx wrote:
Cinema 4D Version: 13
Platform: Windows ;
Language(s) : C++ ;
If we store .c4d scenes in this folder it lets us choose them in our material preview:
*C:\Program Files\MAXON\Your Version\library\materialpreview*
But I can't save a new scene from R13 and use it as a material object option anymore.
The last time I did this was way back somewhere around R9.
I can remove the read-only option from the scenes already in there. Modify them. And then save them with a different name. And it will work.
But...If I try to write a brand new file. And save it in that folder. It will not load into the material.
The material preview locks up and has some sort of melt down.
I've looked at all of the settings in those files and I can't find what it is that's causing the crash.
Since I can copy, edit, and re-save a current existing scene in that folder as a new one, and it works. I'm thinking that there's got to be a setting that needs to be changed when making one from scratch. But I can't find it.
On 15/12/2014 at 22:03, xxxxxxxx wrote:
I couldn't vouch for R13, but in R14, R15, and R16 it seems to work fine.
- Opened a file from Material Preview folder
- Selected all items in the Object Manager (ctrl+a) and copied (ctrl+c)
- Opened new scene (ctrl+n)
- Pasted objects into new scene (ctrl+v)
- saved file into Material Preview folder
I'd imagine it's possibly a stray scenehook or a plugin that's in your fresh scene that's causing the issue.
Did you try doing it with no plugins loaded?
I also forgot to ask if the object/tag names in your new scene are also consistent with the default preview files...
On 16/12/2014 at 07:48, xxxxxxxx wrote:
I can use the existing files as a base too.
What doesn't work for me is when I make a brand new .c4d file like normal. Then save it into the materialpreview folder. And then try to use it as a material preview object.
There seems to be something special about the files in that materialpreview folder that a brand new file from c4d doesn't have.
The "Stairs.c4d" file in the sdk also has the same problem.
I can open it and edit it. But... if I replace it with a brand new file from R13. It no longer loads into the material preview.
These are very old files. R8 I think.
Is it possible that when re-saving an R8 file in newer versions. C4D does not overwrite certain information in the file?
This is the only reason I can think of why a brand new file won't work. But an old R8 file that's edited and re-saved from latter versions will still work.
On 17/12/2014 at 06:46, xxxxxxxx wrote:
we discussed this in the SDK Support Team and none of us knows, if this is a bug or not.
I'm moving this thread to General Discussion, as this is in no way related to the SDK.
I suggest to ask MAXON support or file a bug report there.
On 17/12/2014 at 07:01, xxxxxxxx wrote:
I'm confused about your reply Andreas?
Can you create a brand new .c4d file and use it in your material preset menu as an object option?
If it does work for you then at least I'll know that the problem I'm having is something local to my computer. And it's not an SDK problem.
If it doesn't work. Then it's definitely a bug and an SDK problem.
Since AddUserPreviewScene(); is part of the SDK.
I'm mostly wondering if it's just me that is having this problem?
On 17/12/2014 at 07:23, xxxxxxxx wrote:
Ok, first I tried opening and saving the staris.c4d from the SimpleMaterial example. This worked fine for me.
Then I created a completely new scene, which has to meet one condition. It has to contain an object named "Object" (this may also be a Null grouping several objects). This worked for me as well.
So as far as I can see AddUserPreviewScene() works just like demonstrated in SimpleMaterial example.
Edit: Moved topic back to SDK Help
Edit2: Added a note to the SDK docs explaining this.
On 17/12/2014 at 08:02, xxxxxxxx wrote:
There has to be at least one object named "Object" in the scene for it to work.
On 17/12/2014 at 08:05, xxxxxxxx wrote:
Had to rename the topic slightly to fit the [SOLVED] tag