CGTalk > Software > Maxon Cinema 4D
Login register
Thread Closed share thread « Previous Thread | Next Thread »  
 
Thread Tools Search this Thread Display Modes
Old 06-24-2013, 07:30 PM   #1
anna1
Expert
 
anna1's Avatar
portfolio
Anna Huber
3D Artist
Germany
 
Join Date: Jul 2011
Posts: 303
Access to the graphic preferences

Hi everyone,

I am trying to get access to the parameters in the graphic preferences window (hope this is the right word in English) via python. So I looked up the code in the phyton SKD, but I am not completely understanding it. I am still at the beginning with python.

So let's say I want to get access to the opacity and change the value. I thought that I have to use this command

Vorne[c4d.BASEDRAW_DATA_TINTBORDER_OPACITY]

Now the thing is, that Vorne, which is my front perspective is not working. I am getting an error line, saying NameError: global name "Vorne" is not defined. So it makes sense to me, that I have to define it first, that Vorne is my front perspective, but how to do it. I don't find the command for the front perspective in the SKD. So is it even possible or do I have to do the whole thing with COFFEE?

Would be great to get some help and thank you very much

Anna
 
Old 06-24-2013, 09:16 PM   #2
NiklasR
Expert
 
NiklasR's Avatar
portfolio
Niklas Rosenstein
Germany
 
Join Date: Jan 2011
Posts: 436
Hi Anna!

A viewport window is represented by a BaseDraw instance. You can get a BaseDraw by index
from a document via doc.GetBaseDraw(index). The number of available BaseDraw's can be
retrieved via doc.GetBaseDrawCount(). Iterate over all available BaseDraw's and search for
the one with the front perspective.

Best,
-Niklas
__________________
Cinema 4D Plugin Developer
niklasrosenstein.com/ | Freebies | Plugins
 
Old 06-25-2013, 07:39 AM   #3
anna1
Expert
 
anna1's Avatar
portfolio
Anna Huber
3D Artist
Germany
 
Join Date: Jul 2011
Posts: 303
Thanks a lot Niklas, it is working

Anna
 
Old 06-25-2013, 07:39 AM   #4
CGTalk Moderation
Lord of the posts
CGTalk Forum Leader
 
Join Date: Sep 2003
Posts: 1,066,481
Thread automatically closed

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.
__________________
CGTalk Policy/Legalities
Note that as CGTalk Members, you agree to the terms and conditions of using this website.
 
Thread Closed share thread


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
CGSociety
Society of Digital Artists
www.cgsociety.org

Powered by vBulletin
Copyright 2000 - 2006,
Jelsoft Enterprises Ltd.
Minimize Ads
Forum Jump
Miscellaneous

All times are GMT. The time now is 07:52 PM.


Powered by vBulletin
Copyright ©2000 - 2016, Jelsoft Enterprises Ltd.