THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED
On 23/11/2008 at 22:44, xxxxxxxx wrote:
Cinema 4D Version: 10
Platform: Windows ;
Language(s) : C++ ;
How do I find out about the field-of-view of the current scene camera from within the InitRender function of a material shader?
Thanks for the support.
On 24/11/2008 at 01:04, xxxxxxxx wrote:
Get the camera through the render basedraw.
> \> irs->doc->GetRenderBasedraw() \>
\> irs->doc->GetRenderBasedraw() \>
On 24/11/2008 at 14:26, xxxxxxxx wrote:
GetRenderBasedraw returns me a pointer to BaseDraw class.
I guess with that I can get the scene camera by
However this returns me a BaseObject, and not a CameraObject, which I would need to use the functions GetAperture and GetFocus.
Maybe you could tell me, where my misunderstanding is.
On 25/11/2008 at 05:42, xxxxxxxx wrote:
Or is there a direct way from BaseDraw to get the field-of-view of the current scene camera.
On 25/11/2008 at 06:33, xxxxxxxx wrote:
Just cast the BaseObject to a CameraObject or access the container of the BaseObject with the according IDs (e.g CAMERAOBJECT_FOV).