Eng-Tips is the largest engineering community on the Internet

Intelligent Work Forums for Engineering Professionals

  • Congratulations waross on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Macro to make picture capture and setting lighting effects

Status
Not open for further replies.

AlexMorasan

Automotive
Aug 17, 2020
13
0
0
MX
Hello everyone


Recently I made a macro that stores all the viewpoints from the assembly manual we deliver to our main customer. My new objective was to make a macro that was able to also make the screenshot from CATIA window to ensure that all pictures are exactly the same size in every new version of the manual. I have managed to make the capture while also hiding the compass and the tree, however in each capture there is a smsll axys system in the lower right corner. Is there any way to hide also this element ?

graph_bqlwgh.png


Another point that I want to cover is to control de light settings in each picture so that also remains the same. I manage to control the light vector with the LIghtsources object in CATIA. However I am still unable to control the three parameters that affect that light (Ambien, Diffuse and Specular).


ambient_kchrda.png


Does anybody know how I can control this parameters? I found in the object browser that those three parameters can be control with the object / method RenderingLight but I am not quite sure how to use it or declare it.

I tried the following code without success.

Dim RenderingLightObj as RenderingLight
SEt RenderingLightObj = CATIA.ActiveDocument.RenderingLight (I am not sure if this correct)
RenderingLIghtObj.Ambient = .5

I would be very thankfuld for any advice orhint you can give me
thanks if advance for your support.
 
Replies continue below

Recommended for you

Status
Not open for further replies.
Back
Top