Startup scripts
-
THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED
On 22/08/2007 at 19:37, xxxxxxxx wrote:
User Information:
Cinema 4D Version: 10.11
Platform: Windows ;
Language(s) : C.O.F.F.E.E ;---------
Hello there.
Im evaluating C4D for production use and I need to know if there is a way to do certain things i have grown accostumed on ohter 3d packages.
Is there a way to define a coffee script to be loaded at startup to configure the settings of C4D?
Is there a way to have such coffee script in another directory besides the installation default directory.
Is there an environment variable that allows me to define seach paths for scripts?
Do I still need a different ID just for this initialization scripts?
Your help would be greatly appreciated
Cheers!
Rudy -
THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED
On 22/08/2007 at 20:50, xxxxxxxx wrote:
Is there a way to define a coffee script to be loaded at startup to configure the settings of C4D?
Plugins in the plugins folder are always registered at startup, COFFEE or C++. Plugins can be run at 'startup' but not sure if COFFEE will do this or not. C++ can definitely do this depending upon the plugin type.
Is there a way to have such coffee script in another directory besides the installation default directory.
No. If it is running as a plugin, it MUST be in the plugins folder of the installation (period).
Is there an environment variable that allows me to define seach paths for scripts?
Nope.
Do I still need a different ID just for this initialization scripts?
Yes. The plugin ID must be a unique one obtained from here if it is to be used outside of your own use. There is a range of plugin values set aside that can be used in-house otherwise.
-
THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED
On 23/08/2007 at 09:26, xxxxxxxx wrote:
Ok. So is there a way to read (and write) environment variables from the shell where C4D was run?
Basically im trying to design a pipeline where C4D could be used for different shows at the time and based on the predefined environment variables, the "default settings" of C4D are tweaked to adhere to the show standards. This is extremely important to us.
How do people with professional production houses handle show settings? Any comments are appreciated
Cheers
Rudy -
THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED
On 29/08/2007 at 14:13, xxxxxxxx wrote:
No answer? So I guess its not possible then. Thats too bad. Back to my other app then
thanks guys/gals
cheers!
-
THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED
On 29/08/2007 at 16:34, xxxxxxxx wrote:
Which settings? Your question is vague and seems to think that there there is a 'shell' (?). C4D is an application that runs in a windowed environment (Windows, MacOS 9, MacOS X). What exactly are you seeking - and haven't you looked at the sdk examples and docs and searched here?
There is access to the entire Preferences through the C++ SDK. COFFEE isn't quite as expansive in its support. It is a basic scripting language - not the plugin language (which is...C++).
Hard to answer when you don't specify exactly what you need to accomplish.
-
THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED
On 29/08/2007 at 17:22, xxxxxxxx wrote:
Thanks for your quick response Robert. Here is what im trying to do.
Im used to using Houdini, which always inherits the system environment variables from the shell/terminal/command prompt that it was launched from. This is important to me as it is a very powerful way to control and release a lot of default values for a show in production.
Im also used to the way things are loaded in Houdini, where there is a default search path for plugins and config files, but through environment variables someone can append directories to those paths to override certain things such as the default startup scene, plugins that should be loaded, etc.
For example, imagine working on two shows. Show A uses different world units, render settings, LUT's, etc. It is great to be able to execute a simple batch script that sets the system environment variables then launch your app and not having to worry about being using the right configuration for your scene.
Im sure there is a way to do this with C++, but im interested to see if COFFEE can handle this. Other packages like MAX and Maya allow you to read system environment variables. If C++ is the only way to get this in C4D then I can start looking at other packages since C4D scripting doesn't really provide a big advantage.
Cheers
Rudy
-
THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED
On 29/08/2007 at 18:38, xxxxxxxx wrote:
Ah. Unlike Max and Maya, Cinema 4D started on the AmigaOS. So one must suppose that the legacy of using environment variables for pre-configuration was not there like in DOS and Windows (the AmigaOS did have such variables, but in a different paradigm). That and batch files, CLI, and such weren't big there either - you could go to ARexx back then if there was an interface (this is sort of like AppleScript, I assume).
All that I know is that most of this information is stored in the Prefs folder in various files (such as Cinema 4D.prf which probably contains the general Preferences settings). This is a proprietary binary file so not recommended to parse it directly.
Depending on how much you wanted to changed, much can be done in C++ but not certain about COFFEE. If it is possible in COFFEE, it will probably be an arduous effort. It definitely needs an overhaul if it is to reach the level of MEL.
Sorry that I can't be of much more help.
-
THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED
On 29/08/2007 at 20:05, xxxxxxxx wrote:
You have been a lot of help robert. This is an area where I have run into problems with most midlevel applications (by mid level I dont mean that they are not capable of producing outstanding work, but they are not used as much in professional film environments:) ) the lack of support for configuration. If those binary .prf where ascii and if those prefs where loaded through search path in a cascading style, then that would improve the whole configuration environment for C4D.
Thanks a lot everyone.
Cheers