<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Get Camera FOV from a Rendering addin in Archicad C++ API</title>
    <link>https://community.graphisoft.com/t5/Archicad-C-API/Get-Camera-FOV-from-a-Rendering-addin/m-p/255917#M5507</link>
    <description>Any feedback from GS on this? It seems the rendering and general lib can't be compiled into the same plugin as they have DLL basic export functions (load etc) built in, so there's a name clash. Fetching info such as camera FOV and reading library item data can't be done via the rendering API, so there's a need to call the general API via the ACAP_STAT library. But it won't compile with the rendering libs.&lt;BR /&gt;
&lt;BR /&gt;
UPDATE: need to do it the other way around. Build standard API then link with GSModelerImp.lib.</description>
    <pubDate>Mon, 04 May 2015 07:14:19 GMT</pubDate>
    <dc:creator>Anonymous</dc:creator>
    <dc:date>2015-05-04T07:14:19Z</dc:date>
    <item>
      <title>Get Camera FOV from a Rendering addin</title>
      <link>https://community.graphisoft.com/t5/Archicad-C-API/Get-Camera-FOV-from-a-Rendering-addin/m-p/255910#M5500</link>
      <description>&lt;DIV class="actalk-migrated-content"&gt;Hi &lt;BR /&gt;&lt;BR /&gt;How can I get the camera Field Of View from a rendering addin pls? I use the following code to get the camera position and target - but cannot find a way to get the FOV.&lt;BR /&gt;
&lt;PRE&gt;	GSModeler::Vertex targetPoint = camera-&amp;gt;GetTargetPoint ();
	GSModeler::Vertex viewPoint = camera-&amp;gt;GetViewPoint ();
&lt;/PRE&gt;
Thanks&lt;BR /&gt;&lt;BR /&gt;Paul&lt;/DIV&gt;</description>
      <pubDate>Tue, 01 Aug 2023 11:29:32 GMT</pubDate>
      <guid>https://community.graphisoft.com/t5/Archicad-C-API/Get-Camera-FOV-from-a-Rendering-addin/m-p/255910#M5500</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2023-08-01T11:29:32Z</dc:date>
    </item>
    <item>
      <title>Re: Get Camera FOV from a Rendering addin</title>
      <link>https://community.graphisoft.com/t5/Archicad-C-API/Get-Camera-FOV-from-a-Rendering-addin/m-p/255911#M5501</link>
      <description>Does anyone have a solution for this pls?&lt;BR /&gt;
&lt;BR /&gt;
Thanks&lt;BR /&gt;
&lt;BR /&gt;
Paul</description>
      <pubDate>Thu, 26 Mar 2015 23:05:04 GMT</pubDate>
      <guid>https://community.graphisoft.com/t5/Archicad-C-API/Get-Camera-FOV-from-a-Rendering-addin/m-p/255911#M5501</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2015-03-26T23:05:04Z</dc:date>
    </item>
    <item>
      <title>Re: Get Camera FOV from a Rendering addin</title>
      <link>https://community.graphisoft.com/t5/Archicad-C-API/Get-Camera-FOV-from-a-Rendering-addin/m-p/255912#M5502</link>
      <description>Bumping to hopefully get a reply pls.&lt;BR /&gt;
&lt;BR /&gt;
Thanks&lt;BR /&gt;
&lt;BR /&gt;
Paul</description>
      <pubDate>Tue, 07 Apr 2015 00:36:24 GMT</pubDate>
      <guid>https://community.graphisoft.com/t5/Archicad-C-API/Get-Camera-FOV-from-a-Rendering-addin/m-p/255912#M5502</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2015-04-07T00:36:24Z</dc:date>
    </item>
    <item>
      <title>Re: Get Camera FOV from a Rendering addin</title>
      <link>https://community.graphisoft.com/t5/Archicad-C-API/Get-Camera-FOV-from-a-Rendering-addin/m-p/255913#M5503</link>
      <description>Hi Paul, &lt;BR /&gt;
 &lt;BR /&gt;
from Rendering API you won't be able to get the FOV value. &lt;BR /&gt;
But using AC API it's possible: 
&lt;PRE&gt;API_3DProjectionInfo	p; 
err = ACAPI_Environment (APIEnv_Get3DProjectionSetsID, &amp;amp;p, NULL); 
if (err == NoError &amp;amp;&amp;amp; p.isPersp) { 
	fov = p.u.persp.viewCone; 
}&lt;/PRE&gt; &lt;BR /&gt;
 &lt;BR /&gt;
Or if you have the GUID of the camera, you can get the camera element with ACAPI_Element_Get using the GUID and element.camera.perspCam.persp.viewCone will contain the value. &lt;BR /&gt;
 &lt;BR /&gt;
I hope this is useful for you. &lt;BR /&gt;
 &lt;BR /&gt;
Regards, &lt;BR /&gt;
Tibor</description>
      <pubDate>Tue, 07 Apr 2015 12:42:19 GMT</pubDate>
      <guid>https://community.graphisoft.com/t5/Archicad-C-API/Get-Camera-FOV-from-a-Rendering-addin/m-p/255913#M5503</guid>
      <dc:creator>Tibor Lorantfy</dc:creator>
      <dc:date>2015-04-07T12:42:19Z</dc:date>
    </item>
    <item>
      <title>Re: Get Camera FOV from a Rendering addin</title>
      <link>https://community.graphisoft.com/t5/Archicad-C-API/Get-Camera-FOV-from-a-Rendering-addin/m-p/255914#M5504</link>
      <description>Thanks Tibor&lt;BR /&gt;
&lt;BR /&gt;
How do I access the AC API from a rendering API pls?  I cannot get ACAPI_Environment() to compile without error, even when I include ACAPinc.h.&lt;BR /&gt;
&lt;BR /&gt;
Thanks&lt;BR /&gt;
&lt;BR /&gt;
Paul</description>
      <pubDate>Wed, 08 Apr 2015 00:22:24 GMT</pubDate>
      <guid>https://community.graphisoft.com/t5/Archicad-C-API/Get-Camera-FOV-from-a-Rendering-addin/m-p/255914#M5504</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2015-04-08T00:22:24Z</dc:date>
    </item>
    <item>
      <title>Re: Get Camera FOV from a Rendering addin</title>
      <link>https://community.graphisoft.com/t5/Archicad-C-API/Get-Camera-FOV-from-a-Rendering-addin/m-p/255915#M5505</link>
      <description>&lt;BLOCKQUOTE&gt;paulk wrote:&lt;BR /&gt;How do I access the AC API from a rendering API pls?  I cannot get ACAPI_Environment() to compile without error, even when I include ACAPinc.h.&lt;/BLOCKQUOTE&gt; &lt;BR /&gt;
 &lt;BR /&gt;
Please use API DevKit and don't forget to link with ACAP_STAT library. &lt;BR /&gt;
Could you tell me please what kind of errors did you get during the compiling or linking?</description>
      <pubDate>Wed, 22 Apr 2015 08:10:29 GMT</pubDate>
      <guid>https://community.graphisoft.com/t5/Archicad-C-API/Get-Camera-FOV-from-a-Rendering-addin/m-p/255915#M5505</guid>
      <dc:creator>Tibor Lorantfy</dc:creator>
      <dc:date>2015-04-22T08:10:29Z</dc:date>
    </item>
    <item>
      <title>Re: Get Camera FOV from a Rendering addin</title>
      <link>https://community.graphisoft.com/t5/Archicad-C-API/Get-Camera-FOV-from-a-Rendering-addin/m-p/255916#M5506</link>
      <description>Thanks Tibor&lt;BR /&gt;
&lt;BR /&gt;
If I try to link my rendering API plugin with ACAP_STAT.lib, I get the following link errors.&lt;BR /&gt;

&lt;PRE&gt;ACAP_STAT.lib(ACAPlib.obj) : error LNK2038: mismatch detected for '_ITERATOR_DEBUG_LEVEL': value '0' doesn't match value '2' in ConfigurationDlg.obj
ACAP_STAT.lib(ACAPlib.obj) : error LNK2005: "int (__cdecl* _pRawDllMain)(void *,unsigned long,void *)" (?_pRawDllMain@@3P6AHPEAXK0@ZEA) already defined in OctaneRenderForArchiCAD_Renderer.obj
ACAP_STAT.lib(ACAPlib.obj) : error LNK2005: "struct HINSTANCE__ * __cdecl DllMainImp_GetWindowsHInstance(struct DllMainImp_InitContext const *)" (?DllMainImp_GetWindowsHInstance@@YAPEAUHINSTANCE__@@PEBUDllMainImp_InitContext@@@Z) already defined in OctaneRenderForArchiCAD_Renderer.obj
ACAP_STAT.lib(ACAPlib.obj) : error LNK2005: "struct DllMainImp_ResModuleSpec __cdecl DllMainImp_GetResModuleSpec(struct DllMainImp_InitContext const *)" (?DllMainImp_GetResModuleSpec@@YA?AUDllMainImp_ResModuleSpec@@PEBUDllMainImp_InitContext@@@Z) already defined in OctaneRenderForArchiCAD_Renderer.obj
ACAP_STAT.lib(ACAPlib.obj) : error LNK2005: "__int64 __cdecl DllMainImp_OpenResModule(struct DllMainImp_InitContext const *)" (?DllMainImp_OpenResModule@@YA_JPEBUDllMainImp_InitContext@@@Z) already defined in OctaneRenderForArchiCAD_Renderer.obj
ACAP_STAT.lib(ACAPlib.obj) : error LNK2005: "__int64 __cdecl DllMainImp_OpenResModuleFromSpec(struct DllMainImp_ResModuleSpec const *)" (?DllMainImp_OpenResModuleFromSpec@@YA_JPEBUDllMainImp_ResModuleSpec@@@Z) already defined in OctaneRenderForArchiCAD_Renderer.obj
ACAP_STAT.lib(ACAPlib.obj) : error LNK2005: "void __cdecl DllMainImp_CloseResModule(__int64)" (?DllMainImp_CloseResModule@@YAX_J@Z) already defined in OctaneRenderForArchiCAD_Renderer.obj
ACAP_STAT.lib(ACAPlib.obj) : error LNK2005: "struct DllMainImp_LocationSpec __cdecl DllMainImp_GetLocation(struct DllMainImp_InitContext const *)" (?DllMainImp_GetLocation@@YA?AUDllMainImp_LocationSpec@@PEBUDllMainImp_InitContext@@@Z) already defined in OctaneRenderForArchiCAD_Renderer.obj
ACAP_STAT.lib(ACAPlib.obj) : error LNK2005: "int __cdecl _CRT_INIT_MY(void *,unsigned long,void *)" (?_CRT_INIT_MY@@YAHPEAXK0@Z) already defined in OctaneRenderForArchiCAD_Renderer.obj
ACAP_STAT.lib(ACAPlib.obj) : error LNK2005: DllMain already defined in OctaneRenderForArchiCAD_Renderer.obj
ACAP_STAT.lib(ACAPlib.obj) : error LNK2005: DllMainEntry already defined in OctaneRenderForArchiCAD_Renderer.obj
LINK : fatal error LNK1104: cannot open file 'stlport_vc7.lib'
&lt;/PRE&gt;

Paul</description>
      <pubDate>Thu, 23 Apr 2015 12:41:01 GMT</pubDate>
      <guid>https://community.graphisoft.com/t5/Archicad-C-API/Get-Camera-FOV-from-a-Rendering-addin/m-p/255916#M5506</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2015-04-23T12:41:01Z</dc:date>
    </item>
    <item>
      <title>Re: Get Camera FOV from a Rendering addin</title>
      <link>https://community.graphisoft.com/t5/Archicad-C-API/Get-Camera-FOV-from-a-Rendering-addin/m-p/255917#M5507</link>
      <description>Any feedback from GS on this? It seems the rendering and general lib can't be compiled into the same plugin as they have DLL basic export functions (load etc) built in, so there's a name clash. Fetching info such as camera FOV and reading library item data can't be done via the rendering API, so there's a need to call the general API via the ACAP_STAT library. But it won't compile with the rendering libs.&lt;BR /&gt;
&lt;BR /&gt;
UPDATE: need to do it the other way around. Build standard API then link with GSModelerImp.lib.</description>
      <pubDate>Mon, 04 May 2015 07:14:19 GMT</pubDate>
      <guid>https://community.graphisoft.com/t5/Archicad-C-API/Get-Camera-FOV-from-a-Rendering-addin/m-p/255917#M5507</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2015-05-04T07:14:19Z</dc:date>
    </item>
    <item>
      <title>Re: Get Camera FOV from a Rendering addin</title>
      <link>https://community.graphisoft.com/t5/Archicad-C-API/Get-Camera-FOV-from-a-Rendering-addin/m-p/255918#M5508</link>
      <description>&lt;BLOCKQUOTE&gt;MarkHenryC wrote:&lt;BR /&gt;Any feedback from GS on this? It seems the rendering and general lib can't be compiled into the same plugin as they have DLL basic export functions (load etc) built in, so there's a name clash. Fetching info such as camera FOV and reading library item data can't be done via the rendering API, so there's a need to call the general API via the ACAP_STAT library. But it won't compile with the rendering libs.&lt;BR /&gt;
&lt;BR /&gt;
UPDATE: need to do it the other way around. Build standard API then link with GSModelerImp.lib.&lt;/BLOCKQUOTE&gt;

Hi Paul,&lt;BR /&gt;
&lt;BR /&gt;
The FOV is stored as 'eyeAngle' in the ModelerAPI::Environment::ViewSetting class. I found only a way to pass this onto MakePicture, but I couldn't find how to read that from ARCHICAD. BTW, the default value is 60º.&lt;BR /&gt;
&lt;BR /&gt;
Best, Akos</description>
      <pubDate>Fri, 03 Jul 2015 09:34:44 GMT</pubDate>
      <guid>https://community.graphisoft.com/t5/Archicad-C-API/Get-Camera-FOV-from-a-Rendering-addin/m-p/255918#M5508</guid>
      <dc:creator>Akos Somorjai</dc:creator>
      <dc:date>2015-07-03T09:34:44Z</dc:date>
    </item>
    <item>
      <title>Re: Get Camera FOV from a Rendering addin</title>
      <link>https://community.graphisoft.com/t5/Archicad-C-API/Get-Camera-FOV-from-a-Rendering-addin/m-p/255919#M5509</link>
      <description>&lt;BLOCKQUOTE&gt;The FOV is stored as 'eyeAngle' in the ModelerAPI::Environment::ViewSetting class. I found only a way to pass this onto MakePicture, but I couldn't find how to read that from ARCHICAD. BTW, the default value is 60º.&lt;/BLOCKQUOTE&gt;Thanks Akos.  I still do not understand how to get the FOV.  I could not find any way to access the ModelerAPI::Environment::ViewSetting class in MakePicture.  Would you be able to post the code to do this pls?&lt;BR /&gt;
&lt;BR /&gt;
Thanks&lt;BR /&gt;
&lt;BR /&gt;
Paul</description>
      <pubDate>Sat, 04 Jul 2015 23:02:06 GMT</pubDate>
      <guid>https://community.graphisoft.com/t5/Archicad-C-API/Get-Camera-FOV-from-a-Rendering-addin/m-p/255919#M5509</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2015-07-04T23:02:06Z</dc:date>
    </item>
  </channel>
</rss>

