<?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: GDL-Object always looking to camera in Libraries &amp; objects</title>
    <link>https://community.graphisoft.com/t5/Libraries-objects/GDL-Object-always-looking-to-camera/m-p/80123#M33752</link>
    <description>Hi Dan,&lt;BR /&gt;
&lt;BR /&gt;
Many, many thanks - it works!&lt;BR /&gt;
&lt;BR /&gt;
Have a wonderful day&lt;BR /&gt;
&lt;BR /&gt;
Macangelo</description>
    <pubDate>Fri, 26 May 2006 07:40:38 GMT</pubDate>
    <dc:creator>Anonymous</dc:creator>
    <dc:date>2006-05-26T07:40:38Z</dc:date>
    <item>
      <title>GDL-Object always looking to camera</title>
      <link>https://community.graphisoft.com/t5/Libraries-objects/GDL-Object-always-looking-to-camera/m-p/80116#M33745</link>
      <description>&lt;DIV class="actalk-migrated-content"&gt;&lt;T&gt;Hi,&lt;BR /&gt;
&lt;BR /&gt;
I want my (Bitmap)GDL-object always to look into the camera. I know I can Use GLOB_EYEPOS_X or _Y or _Z. But how do I do that? I don't find it in the manual...&lt;BR /&gt;
&lt;BR /&gt;
thanks a lot&lt;BR /&gt;
&lt;BR /&gt;
Macangelo&lt;/T&gt;&lt;/DIV&gt;</description>
      <pubDate>Thu, 25 May 2006 07:05:58 GMT</pubDate>
      <guid>https://community.graphisoft.com/t5/Libraries-objects/GDL-Object-always-looking-to-camera/m-p/80116#M33745</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2006-05-25T07:05:58Z</dc:date>
    </item>
    <item>
      <title>Re: GDL-Object always looking to camera</title>
      <link>https://community.graphisoft.com/t5/Libraries-objects/GDL-Object-always-looking-to-camera/m-p/80117#M33746</link>
      <description>I don't have the code by the hand, but you should find it in the gdl cookbook or by search in this forum.</description>
      <pubDate>Thu, 25 May 2006 09:04:27 GMT</pubDate>
      <guid>https://community.graphisoft.com/t5/Libraries-objects/GDL-Object-always-looking-to-camera/m-p/80117#M33746</guid>
      <dc:creator>Frank Beister</dc:creator>
      <dc:date>2006-05-25T09:04:27Z</dc:date>
    </item>
    <item>
      <title>Re: GDL-Object always looking to camera</title>
      <link>https://community.graphisoft.com/t5/Libraries-objects/GDL-Object-always-looking-to-camera/m-p/80118#M33747</link>
      <description>&lt;BLOCKQUOTE&gt;macangelo wrote:&lt;BR /&gt;Hi,&lt;BR /&gt;
&lt;BR /&gt;
I want my (Bitmap)GDL-object always to look into the camera. I know I can Use GLOB_EYEPOS_X or _Y or _Z. But how do I do that? I don't find it in the manual...&lt;BR /&gt;
&lt;BR /&gt;
thanks a lot&lt;BR /&gt;
&lt;BR /&gt;
Macangelo&lt;/BLOCKQUOTE&gt;

Macangelo,&lt;BR /&gt;
Here's part of one of my scripts that rotate. I developed it so long ago, I don't really remember how to explain it...I think I go the concept from DNC.&lt;BR /&gt;
&lt;BR /&gt;
anyway, here it is:&lt;BR /&gt;
&lt;BR /&gt;
dkx=K~-X~:if dkx=0 then dkx=1&lt;BR /&gt;
dly=L~-Y~:if dly=0 then dly=1&lt;BR /&gt;
dazi=ATN(dly/dkx)&lt;BR /&gt;
&lt;BR /&gt;
    if (dazi+90) &amp;gt;90 then rotz 180&lt;BR /&gt;
    if (dazi+90) &amp;lt;90 then rotz 0&lt;BR /&gt;
&lt;BR /&gt;
HTH,&lt;BR /&gt;
dan K</description>
      <pubDate>Thu, 25 May 2006 16:24:00 GMT</pubDate>
      <guid>https://community.graphisoft.com/t5/Libraries-objects/GDL-Object-always-looking-to-camera/m-p/80118#M33747</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2006-05-25T16:24:00Z</dc:date>
    </item>
    <item>
      <title>Re: GDL-Object always looking to camera</title>
      <link>https://community.graphisoft.com/t5/Libraries-objects/GDL-Object-always-looking-to-camera/m-p/80119#M33748</link>
      <description>Hi Dan,&lt;BR /&gt;
&lt;BR /&gt;
Thanks for your try.&lt;BR /&gt;
&lt;BR /&gt;
I copied and pasted your code and get the error message:&lt;BR /&gt;
"Die Verwendung von realen Typen kann zu Präzisionsproblemen führen." meaning something like "The usage of real types can lead to precision problems." or something &lt;E&gt;&lt;span class="lia-unicode-emoji" title=":winking_face:"&gt;😉&lt;/span&gt;&lt;/E&gt;&lt;BR /&gt;
&lt;BR /&gt;
I replaced K~ with GLOB_EYEPOS_X and L~ with GLOB_EYEPOS_Y - same result.&lt;BR /&gt;
&lt;BR /&gt;
And it does not turn my object.&lt;BR /&gt;
&lt;BR /&gt;
Any ideas?&lt;BR /&gt;
&lt;BR /&gt;
Thanks a lot and have wonderful day&lt;BR /&gt;
&lt;BR /&gt;
Macangelo</description>
      <pubDate>Thu, 25 May 2006 18:00:02 GMT</pubDate>
      <guid>https://community.graphisoft.com/t5/Libraries-objects/GDL-Object-always-looking-to-camera/m-p/80119#M33748</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2006-05-25T18:00:02Z</dc:date>
    </item>
    <item>
      <title>Re: GDL-Object always looking to camera</title>
      <link>https://community.graphisoft.com/t5/Libraries-objects/GDL-Object-always-looking-to-camera/m-p/80120#M33749</link>
      <description>&lt;BLOCKQUOTE&gt;macangelo wrote:&lt;BR /&gt;Hi Dan,&lt;BR /&gt;
&lt;BR /&gt;
I copied and pasted your code and get the error message:&lt;BR /&gt;
"Die Verwendung von realen Typen kann zu Präzisionsproblemen führen." meaning something like "The usage of real types can lead to precision problems." or something &lt;E&gt;&lt;span class="lia-unicode-emoji" title=":winking_face:"&gt;😉&lt;/span&gt;&lt;/E&gt;&lt;BR /&gt;
&lt;BR /&gt;
I replaced K~ with GLOB_EYEPOS_X and L~ with GLOB_EYEPOS_Y - same result.&lt;BR /&gt;
&lt;BR /&gt;
...Macangelo&lt;/BLOCKQUOTE&gt;

You can ignore the "The usage of real types can lead to precision problems" message.&lt;BR /&gt;
&lt;BR /&gt;
Sometimes you need to rebuild the window for the object to turn. &lt;BR /&gt;
&lt;BR /&gt;
The older K~ and L~ global variables should still work. If you still cant get it to work post your full 3d script here for us to see and comment.&lt;BR /&gt;
&lt;BR /&gt;
Dan K</description>
      <pubDate>Thu, 25 May 2006 18:33:21 GMT</pubDate>
      <guid>https://community.graphisoft.com/t5/Libraries-objects/GDL-Object-always-looking-to-camera/m-p/80120#M33749</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2006-05-25T18:33:21Z</dc:date>
    </item>
    <item>
      <title>Re: GDL-Object always looking to camera</title>
      <link>https://community.graphisoft.com/t5/Libraries-objects/GDL-Object-always-looking-to-camera/m-p/80121#M33750</link>
      <description>Macangelo,&lt;BR /&gt;
Try this ... I know it works... just remember that you will probably need to do a &lt;B&gt;"rebuild and regenerate"&lt;/B&gt; to see the rotation.&lt;BR /&gt;
&lt;BR /&gt;
P.S. note that it even works correctly if the symbol is mirrored!&lt;BR /&gt;
&lt;BR /&gt;
&lt;B&gt;2d Script:&lt;/B&gt;&lt;BR /&gt;
&lt;FONT color="#0900ff"&gt;project2 2,270,1&lt;/FONT&gt;&lt;BR /&gt;
&lt;BR /&gt;
&lt;B&gt;3d Script:&lt;/B&gt;&lt;BR /&gt;
&lt;FONT color="#0900ff"&gt;dkx=K~-X~:if dkx=0 then dkx=1&lt;BR /&gt;
dly=L~-Y~:if dly=0 then dly=1&lt;BR /&gt;
dazi=ATN(dly/dkx)&lt;BR /&gt;
&lt;BR /&gt;
    if (dazi+90) &amp;gt;90 then rotz 180&lt;BR /&gt;
    if (dazi+90) &amp;lt;90 then rotz 0&lt;BR /&gt;
    &lt;BR /&gt;
if SYMB_MIRRORED goto 20&lt;BR /&gt;
rotz 90+dazi-W~ &lt;BR /&gt;
goto 30&lt;BR /&gt;
&lt;BR /&gt;
20:&lt;BR /&gt;
rotz -90-dazi+W~&lt;BR /&gt;
&lt;BR /&gt;
30:&lt;BR /&gt;
ADDX -A/2&lt;BR /&gt;
&lt;BR /&gt;
block a,1',1'&lt;/FONT&gt;</description>
      <pubDate>Thu, 25 May 2006 18:56:44 GMT</pubDate>
      <guid>https://community.graphisoft.com/t5/Libraries-objects/GDL-Object-always-looking-to-camera/m-p/80121#M33750</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2006-05-25T18:56:44Z</dc:date>
    </item>
    <item>
      <title>Re: GDL-Object always looking to camera</title>
      <link>https://community.graphisoft.com/t5/Libraries-objects/GDL-Object-always-looking-to-camera/m-p/80122#M33751</link>
      <description>Hi Dan,&lt;BR /&gt;
&lt;BR /&gt;
thanks for the offer. Here's my full code. I try your new code as soon as I'm back at my desk.&lt;BR /&gt;
&lt;BR /&gt;
Best&lt;BR /&gt;
Macangelo&lt;BR /&gt;
&lt;BR /&gt;
SHADOW on&lt;BR /&gt;
&lt;BR /&gt;
dkx=GLOB_EYEPOS_X-X~:if dkx=0 then dkx=1&lt;BR /&gt;
dly=GLOB_EYEPOS_Y-Y~:if dly=0 then dly=1&lt;BR /&gt;
dazi=ATN(dly/dkx)&lt;BR /&gt;
&lt;BR /&gt;
if (dazi+90) &amp;gt;90 then rotz 180&lt;BR /&gt;
if (dazi+90) &amp;lt;90 then rotz 0 &lt;BR /&gt;
&lt;BR /&gt;
rotx 90&lt;BR /&gt;
&lt;BR /&gt;
&lt;BR /&gt;
&lt;BR /&gt;
B=199*ZZYZX/480&lt;BR /&gt;
ADDX -B/2&lt;BR /&gt;
&lt;BR /&gt;
PICTURE  "PEOPLE10.TIF", B, ZZYZX, 1</description>
      <pubDate>Thu, 25 May 2006 19:19:23 GMT</pubDate>
      <guid>https://community.graphisoft.com/t5/Libraries-objects/GDL-Object-always-looking-to-camera/m-p/80122#M33751</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2006-05-25T19:19:23Z</dc:date>
    </item>
    <item>
      <title>Re: GDL-Object always looking to camera</title>
      <link>https://community.graphisoft.com/t5/Libraries-objects/GDL-Object-always-looking-to-camera/m-p/80123#M33752</link>
      <description>Hi Dan,&lt;BR /&gt;
&lt;BR /&gt;
Many, many thanks - it works!&lt;BR /&gt;
&lt;BR /&gt;
Have a wonderful day&lt;BR /&gt;
&lt;BR /&gt;
Macangelo</description>
      <pubDate>Fri, 26 May 2006 07:40:38 GMT</pubDate>
      <guid>https://community.graphisoft.com/t5/Libraries-objects/GDL-Object-always-looking-to-camera/m-p/80123#M33752</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2006-05-26T07:40:38Z</dc:date>
    </item>
  </channel>
</rss>

