PDA

View Full Version : fileProperties and Loading Render Presets.


Kramsurfer
01-05-2010, 06:53 PM
I've been having an issue with fileProperties disappearing when I load render presets in Max 2009 x64. The entire #custom field gets erased. I've removed every callback and custom script we have and am at my wits end.

If anyone has a relatively clean max 2009 x64 install, could you please execute the following snippit?


renderPresets.saveall 0 "D:\\temp\\SaveTemp.rps"
fileProperties.addProperty #custom "TestString" "I disappear!"
fileProperties.findProperty #custom "TestString"
renderPresets.loadall 0 "D:\\temp\\SaveTemp.rps"
fileProperties.findProperty #custom "TestString"


My install of Max 9 x32 and x64 return the proper results:

true
OK
1
true
1

The last "1" indicating that the custom fileProperties was found.
My install of Max 2009 x64 returns

true
OK
1
true
0


Thanks in advance;

MarcoBrunetta
01-05-2010, 07:00 PM
true
OK
1
false
1

On Max 2009 x64 & Vista.... I guess it's just you.

Kramsurfer
01-05-2010, 07:04 PM
You didn't get a valid load of the render preset... Please try a valid filepath on the preset save and load...

Hence the false before the 1

Thanks

MarcoBrunetta
01-05-2010, 07:37 PM
true
OK
1
true
0

>.<
o

must....get...sleep....

Kramsurfer
01-05-2010, 08:24 PM
Anyone else able to confirm this bug? Perhaps try it in 2010?

Thanks

denisT
01-05-2010, 08:40 PM
Anyone else able to confirm this bug? Perhaps try it in 2010?

Thanks

i confirm this nasty BUG - the loading of render preset file clears #custom file properties
(max 2010 x32 and x64)

ps. it deletes both #summary and #custom properties.

PiXeL_MoNKeY
01-05-2010, 09:16 PM
render presets have created various bugs with other features of Max in the past, I would stay away from it if you could.

-Eric

Kramsurfer
01-06-2010, 12:09 AM
Amazing... Guess no one's really using these data fields... I was just storing a few filepaths to related info in there... it was an easy way to do it..

I've now created a CA on the rootNode of the scene... Nice part is I can make a UI for these vars being saved with the file.. :-)

Thanks everyone!

denisT
01-06-2010, 01:10 AM
Amazing... Guess no one's really using these data fields... I was just storing a few filepaths to related info in there... it was an easy way to do it..

I've now created a CA on the rootNode of the scene... Nice part is I can make a UI for these vars being saved with the file.. :-)

Thanks everyone!

because you are storing paths (strings) you can use appData (set and get data for rootnode). It's safer then create CA. There are some situations when max crashes trying to open xref-scenes with rootnode's CA

Kramsurfer
01-06-2010, 05:18 AM
Code change again..

Thanks for the heads up on that one... I'm sure that was a F*$K to figure out when you hit it!

Appdata on the rootNode.. I like that even better!

Bobo
01-06-2010, 01:22 PM
Amazing... Guess no one's really using these data fields... I was just storing a few filepaths to related info in there... it was an easy way to do it..

I've now created a CA on the rootNode of the scene... Nice part is I can make a UI for these vars being saved with the file.. :-)

Thanks everyone!

Render Presets are a limited form of MAX files that contain only the renderer-related chunks. When you load a render preset, you are kind of Merging two MAX files. Can you check whether a Merge operation also clears the fileproperties? If it does, then it might be a know issue. If it does not, I would call it a bug and report it. (Bugs don't fix themselves, especially if nobody knows about them).

And yes, I never use those fields. They are part of a more general Microsoft file specification (together with the scene's thumbnail and some other fields in the header of the Max file) and are not as "native" as the rest of the data stored.

denisT
01-06-2010, 03:39 PM
Render Presets are a limited form of MAX files that contain only the renderer-related chunks. When you load a render preset, you are kind of Merging two MAX files. Can you check whether a Merge operation also clears the fileproperties? If it does, then it might be a know issue. If it does not, I would call it a bug and report it. (Bugs don't fix themselves, especially if nobody knows about them).



i double-checked merge, xref scene, and xref object (which is kinda merging too) functions, and not any of those deletes file's properties. I use file's #custom properties a lot, but i've never used it in combination with loading render presets. So only "presets loading" clears file's properties for me.

chib
03-11-2010, 01:07 PM
damn! I just fell in that problem too...
appData are not as convenient as fileProperties :( such a shame it can only contains strings... and a shame too you have to give them an ID instead of a real name!
And a shame that there is no UI to manage them (or at least to see them)...
I think it's too many constraints for me, I'm gonna have to think of another workaround...
Paul.

CGTalk Moderation
03-11-2010, 01:07 PM
This thread has been automatically closed as it remained inactive for 12 months. If you wish to continue the discussion, please create a new thread in the appropriate forum.