<div dir="ltr">sorry, I should have read your emails more carefully...<div>so after converting all the .vert and .frag files to UNIX line ending, it works (!!?? windows donesn&#39;t understand itself ???)<br></div><div>and now, all examples work, but the 06., 11. and 12. because of my virtual hardware and the 10. due to this error : &quot;GL: débordement négatif de la pile&quot; (sic)<br>

</div><div><br></div><div class="gmail_extra">Michael, what is your graphic card ? does it support shader ? are the drivers up to date ?</div><div class="gmail_extra"><br></div><div class="gmail_extra">+</div><div class="gmail_extra">

a</div><div class="gmail_extra"><div>--<br>do it yourself                       <br><a href="http://antoine.villeret.free.fr" target="_blank">http://antoine.villeret.free.fr</a><br></div>
<br><br><div class="gmail_quote">2013/9/12 Michael Mihocic <span dir="ltr">&lt;<a href="mailto:michael.mihocic@oeaw.ac.at" target="_blank">michael.mihocic@oeaw.ac.at</a>&gt;</span><br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">


  
    
  
  <div text="#000000" bgcolor="#FFFFFF">
    Thank you Antoine, this error can be fixed, when you replace all
    CRLF by CR in the shader files (eg. with Notepad++).<br>
    <br>
    Does someone else know the error message, when loading shader
    files??<div class="im"><br>
         linking: link 1.5 3.5<br>
         [glsl_program]: Info_log:<br>
         [glsl_program]: Vertex info<br>
         -----------<br>
         (0) : error C5145: must write to gl_Position<br>
         [glsl_program]: Link failed!<br>
    <br></div>
    Br, Michael<br>
    <br>
    <div><div class="im">-------- Original Message --------<br>
      Subject: Re: [GEM-dev] Oculus Rift distortion/support<br></div><div><div class="h5">
      From: Antoine Villeret <a href="mailto:antoine.villeret@gmail.com" target="_blank">&lt;antoine.villeret@gmail.com&gt;</a><br>
      To: Cyrille Henry <a href="mailto:ch@chnry.net" target="_blank">&lt;ch@chnry.net&gt;</a><br>
      Cc: Michael Mihocic <a href="mailto:michael.mihocic@oeaw.ac.at" target="_blank">&lt;michael.mihocic@oeaw.ac.at&gt;</a>, gem-dev
      <a href="mailto:gem-dev@iem.at" target="_blank">&lt;gem-dev@iem.at&gt;</a><br>
      Date: 11.09.2013 20:14<br>
    </div></div></div><div><div class="h5">
    <blockquote type="cite">
      <div dir="ltr">hi, 
        <div><br>
        </div>
        <div>I confirm that the example <span style="font-family:arial,sans-serif;font-size:13px">&quot;01.simple_texture.pd&quot;
            doesn&#39;t work for me on Windows 7 with pd-extended 0.44-0 and
            Gem 0.93.3</span></div>
        <div><span style="font-family:arial,sans-serif">And none of the
            10.glsl/ example work.</span><br>
        </div>
        <div><span style="font-family:arial,sans-serif">All send the
            same errors: </span></div>
        <div><span style="color:rgb(80,0,80);font-family:arial,sans-serif;font-size:13px"> 
             [glsl_vertex]: error reading file</span><br style="color:rgb(80,0,80);font-family:arial,sans-serif;font-size:13px">
          <span style="color:rgb(80,0,80);font-family:arial,sans-serif;font-size:13px"> 
             [glsl_fragment]: error reading file</span><span style="font-family:arial,sans-serif"><br>
          </span></div>
        <div><span style="font-family:arial,sans-serif"><br>
          </span></div>
        <div><font face="arial, sans-serif">+</font></div>
        <div>
          <font face="arial, sans-serif">a</font></div>
        <div><br>
        </div>
        <div class="gmail_extra"><br clear="all">
          <div>--<br>
            do it yourself                       <br>
            <a href="http://antoine.villeret.free.fr" target="_blank">http://antoine.villeret.free.fr</a><br>
          </div>
          <br>
          <br>
          <div class="gmail_quote">2013/9/11 Cyrille Henry <span dir="ltr">&lt;<a href="mailto:ch@chnry.net" target="_blank">ch@chnry.net</a>&gt;</span><br>
            <blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">hello,<br>
              <br>
              this shaders works for me.<br>
              i don&#39;t know the cause of the problem.<br>
              <br>
              cheers<br>
              c<br>
              <br>
              <br>
              Le 11/09/2013 13:40, Michael Mihocic a écrit :
              <div>
                <div><br>
                  <blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">Thanks
                    again for your help!!<br>
                    <br>
                    What I did:<br>
                    - I downloaded and installed Pd-extended for Windows
                    from here: <a href="http://puredata.info/downloads/pd-extended" target="_blank">http://puredata.info/downloads/pd-extended</a>
                    (v0.43.4, Windows Installer)<br>
                    - I started pd with &quot;pd-extended.bat&quot; in pd folder<br>
                    - When I&#39;m running pd all GEM details are displayed
                    (version,...) -&gt; I guess GEM is loaded properly<br>
                    - I opened example patch 01.simple_texture.pd in
                    folder \extra\Gem\examples\10.glsl<br>
                    - I can load the images but when I want to load the
                    shader these error messages are displayed:<br>
                         [glsl_vertex]: error reading file<br>
                         [glsl_fragment]: error reading file<br>
                    - after replacing all CRLF by CR I receive different
                    error messages, as I described below!?<br>
                    I could load neither .vert nor .frag files! I will
                    send them to you in a seperate email.<br>
                    The files are existing and found by pd, otherwise I
                    would receive a different error message....<br>
                    <br>
                    Br, Michael<br>
                    <br>
                    -------- Original Message --------<br>
                    Subject: Re: [GEM-dev] Oculus Rift
                    distortion/support<br>
                    From: Cyrille Henry &lt;<a href="mailto:ch@chnry.net" target="_blank">ch@chnry.net</a>&gt;<br>
                    To: <a href="mailto:gem-dev@iem.at" target="_blank">gem-dev@iem.at</a><br>
                    Date: 11.09.2013 12:03<br>
                    <blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex"><br>
                      <br>
                      Le 11/09/2013 08:35, Michael Mihocic a écrit :<br>
                      <blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">Dear
                        list,<br>
                        <br>
                        I tried to get familiar with shaders in GEM. I
                        started with &quot;01.simple_texture.pd&quot; in folder
                        10.glsl.<br>
                        <br>
                        I can start rendering (checking &quot;rendering&quot;) but
                        I cannot load shaders. After checking the
                        rendering checkbox 2 errors occur:<br>
                             [glsl_vertex]: need to load a shader<br>
                             [glsl_fragment]: need to load a shader<br>
                        <br>
                        When I try to use shaders (click on &quot;load
                        shader&quot;) I receive the error message:<br>
                             linking: link 1.5 3.5<br>
                             [glsl_program]: Info_log:<br>
                             [glsl_program]: Vertex info<br>
                             -----------<br>
                             (0) : error C5145: must write to
                        gl_Position<br>
                             [glsl_program]: Link failed!<br>
                        <br>
                        These errors occur when I either try to open a
                        &quot;.vert&quot; or a &quot;.fraq&quot; file! Do you have any ideas
                        what I could try to use different shaders???
                        Below I&#39;m listing my system details:<br>
                        <br>
                      </blockquote>
                      are you really sure you did not modifies oher
                      things in the shader code?<br>
                      if so, could you send them to me so that i can
                      check.<br>
                      c<br>
                      <br>
                      <br>
                      <blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">-
                        pd: 0.43.4-extended<br>
                        - GEM: 0.93.3<br>
                        - System: Windows 7-64<br>
                        - Folder contains no spaces:
                        &quot;C:\pd-0.43.4\extra\Gem\examples\10.glsl&quot;<br>
                        - I replaced all CRLFs with CRs as I found in <a href="https://sourceforge.net/p/pure-data/bugs/864/?page=2" target="_blank">https://sourceforge.net/p/pure-data/bugs/864/?page=2</a>
                        (otherwise I get the errors<br>
                             [glsl_vertex]: error reading file<br>
                             [glsl_fragment]: error reading file<br>
                        - I also tried to run pd with Admin permissions<br>
                        <br>
                        Thanks in advance!!<br>
                        <br>
                        Br, Michael<br>
                        <br>
                        <br>
                        -------- Original Message --------<br>
                        Subject: Re: [GEM-dev] Oculus Rift
                        distortion/support<br>
                        From: Jack &lt;<a href="mailto:jack@rybn.org" target="_blank">jack@rybn.org</a>&gt;<br>
                        To: <a href="mailto:gem-dev@iem.at" target="_blank">gem-dev@iem.at</a><br>
                        Date: <a href="tel:25.07.2013%2012" value="+12507201312" target="_blank">25.07.2013
                          12</a>:22<br>
                        <blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">Hello,<br>
                          <br>
                          Yep, and if oculus doesn&#39;t provide a shader
                          for barrel distortion, there<br>
                          is plenty of example on the web.<br>
                          ++<br>
                          <br>
                          Jack<br>
                          <br>
                          <br>
                          <br>
                          Le 25/07/2013 12:17, Cyrille Henry a écrit :<br>
                          <blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">hello,<br>
                            <br>
                            one have to use shader in order create the
                            image distortion.<br>
                            <br>
                            i think oculus should provide standard
                            shader that you have to insert<br>
                            in your rendering process.<br>
                            <br>
                            the only problem is that you have to do 2
                            rendering : one for each eye.<br>
                            The best solution is to do a 3 pass
                            rendering :<br>
                            1st : left eye view without distortion,
                            rendered in a frame buffer<br>
                            2nd : right eye view (no distortion /
                            framebuffer)<br>
                            3rd : using the 2 previous texture and a
                            shader, render the final image<br>
                            <br>
                            cheers<br>
                            c<br>
                            <br>
                            <br>
                            Le 25/07/2013 12:04, Michael Mihocic a écrit
                            :<br>
                            <blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">Dear
                              list,<br>
                              <br>
                              we are using GEM with a
                              head-mounted-display to present a virtual<br>
                              world to subjects performing acoustic
                              localization experiments.<br>
                              <br>
                              Now we plan to switch from our current HMD
                              to Oculus Rift (an<br>
                              upcoming virtual reality head-mounted
                              display). Therefore we need to<br>
                              modify our image and add (asymetric)
                              barrel distortion to the<br>
                              represented image. (The image distortion
                              is compensated by the lenses<br>
                              in Oculus Rift.)<br>
                              <br>
                              My questions now:<br>
                              - Is there an easy solution to implement
                              barrel distortion to the<br>
                              rendered window in GEM?<br>
                              - Does anybody of you already have some
                              experience with GEM together<br>
                              with Oculus Rift?<br>
                              <br>
                              Since attachments should be avoided in
                              this list, I do not send any<br>
                              example pictures of the distortion or our
                              current presented world. If<br>
                              you are interested you can either contact
                              me and I can send you some<br>
                              screenshots, or you can google for example
                              images/videos of Oculus<br>
                              Rift distortion.<br>
                              <br>
                              Thanks in advance and best regards,
                              Michael<br>
                              <br>
                            </blockquote>
                            _______________________________________________<br>
                            GEM-dev mailing list<br>
                            <a href="mailto:GEM-dev@iem.at" target="_blank">GEM-dev@iem.at</a><br>
                            <a href="http://lists.puredata.info/listinfo/gem-dev" target="_blank">http://lists.puredata.info/listinfo/gem-dev</a><br>
                          </blockquote>
                          <br>
                          _______________________________________________<br>
                          GEM-dev mailing list<br>
                          <a href="mailto:GEM-dev@iem.at" target="_blank">GEM-dev@iem.at</a><br>
                          <a href="http://lists.puredata.info/listinfo/gem-dev" target="_blank">http://lists.puredata.info/listinfo/gem-dev</a><br>
                        </blockquote>
                        <br>
                        --<br>
                        Michael Mihocic<br>
                        Psychoacoustics &amp; Experimental Audiology<br>
                        Acoustics Research Institute &lt;<a href="http://www.kfs.oeaw.ac.at/" target="_blank">http://www.kfs.oeaw.ac.at/</a>&gt;<br>
                        Austrian Academy Of Sciences &lt;<a href="http://www.oeaw.ac.at/" target="_blank">http://www.oeaw.ac.at/</a>&gt;<br>
                        Wohllebengasse 12-14 / 1<br>
                        A-1040 Vienna, Austria<br>
                        Tel: <a href="tel:%2B43%20%281%29%2051581%202515" value="+431515812515" target="_blank">+43 (1)
                          51581 2515</a> (Office)<br>
                        Tel: <a href="tel:%2B43%20%281%29%2051581%202525" value="+431515812525" target="_blank">+43 (1)
                          51581 2525</a> (Lab)<br>
                        Fax: <a href="tel:%2B43%20%281%29%2051581%202530" value="+431515812530" target="_blank">+43 (1)
                          51581 2530</a><br>
                        <a href="mailto:michael.mihocic@oeaw.ac.at" target="_blank">michael.mihocic@oeaw.ac.at</a>
                        &lt;mailto:<a href="mailto:michael.mihocic@oeaw.ac.at" target="_blank">michael.mihocic@oeaw.ac.at</a>&gt;<br>
                        <br>
                        <br>
                        _______________________________________________<br>
                        GEM-dev mailing list<br>
                        <a href="mailto:GEM-dev@iem.at" target="_blank">GEM-dev@iem.at</a><br>
                        <a href="http://lists.puredata.info/listinfo/gem-dev" target="_blank">http://lists.puredata.info/listinfo/gem-dev</a><br>
                        <br>
                      </blockquote>
                      <br>
                      _______________________________________________<br>
                      GEM-dev mailing list<br>
                      <a href="mailto:GEM-dev@iem.at" target="_blank">GEM-dev@iem.at</a><br>
                      <a href="http://lists.puredata.info/listinfo/gem-dev" target="_blank">http://lists.puredata.info/listinfo/gem-dev</a><br>
                    </blockquote>
                    <br>
                    --<br>
                    Michael Mihocic<br>
                    Psychoacoustics &amp; Experimental Audiology<br>
                    Acoustics Research Institute &lt;<a href="http://www.kfs.oeaw.ac.at/" target="_blank">http://www.kfs.oeaw.ac.at/</a>&gt;<br>
                    Austrian Academy Of Sciences &lt;<a href="http://www.oeaw.ac.at/" target="_blank">http://www.oeaw.ac.at/</a>&gt;<br>
                    Wohllebengasse 12-14 / 1<br>
                    A-1040 Vienna, Austria<br>
                    Tel: <a href="tel:%2B43%20%281%29%2051581%202515" value="+431515812515" target="_blank">+43 (1)
                      51581 2515</a> (Office)<br>
                    Tel: <a href="tel:%2B43%20%281%29%2051581%202525" value="+431515812525" target="_blank">+43 (1)
                      51581 2525</a> (Lab)<br>
                    Fax: <a href="tel:%2B43%20%281%29%2051581%202530" value="+431515812530" target="_blank">+43 (1)
                      51581 2530</a><br>
                    <a href="mailto:michael.mihocic@oeaw.ac.at" target="_blank">michael.mihocic@oeaw.ac.at</a>
                    &lt;mailto:<a href="mailto:michael.mihocic@oeaw.ac.at" target="_blank">michael.mihocic@oeaw.ac.at</a>&gt;<br>
                    <br>
                    <br>
                    _______________________________________________<br>
                    GEM-dev mailing list<br>
                    <a href="mailto:GEM-dev@iem.at" target="_blank">GEM-dev@iem.at</a><br>
                    <a href="http://lists.puredata.info/listinfo/gem-dev" target="_blank">http://lists.puredata.info/listinfo/gem-dev</a><br>
                    <br>
                  </blockquote>
                  <br>
                  _______________________________________________<br>
                  GEM-dev mailing list<br>
                  <a href="mailto:GEM-dev@iem.at" target="_blank">GEM-dev@iem.at</a><br>
                  <a href="http://lists.puredata.info/listinfo/gem-dev" target="_blank">http://lists.puredata.info/listinfo/gem-dev</a><br>
                </div>
              </div>
            </blockquote>
          </div>
          <br>
        </div>
      </div>
    </blockquote>
    <br>
    </div></div><div><div><div class="h5">-- <br>
      Michael Mihocic<br>
      Psychoacoustics &amp; Experimental Audiology<br>
      <a href="http://www.kfs.oeaw.ac.at/" target="_blank">Acoustics Research Institute</a><br>
      </div></div><a href="http://www.oeaw.ac.at/" target="_blank">Austrian Academy Of Sciences</a><div class="im"><br>
      Wohllebengasse 12-14 / 1<br>
      A-1040 Vienna, Austria<br>
      Tel: <a href="tel:%2B43%20%281%29%2051581%202515" value="+431515812515" target="_blank">+43 (1) 51581 2515</a> (Office)<br>
      Tel: <a href="tel:%2B43%20%281%29%2051581%202525" value="+431515812525" target="_blank">+43 (1) 51581 2525</a> (Lab)<br>
      Fax: <a href="tel:%2B43%20%281%29%2051581%202530" value="+431515812530" target="_blank">+43 (1) 51581 2530</a><br>
      <a href="mailto:michael.mihocic@oeaw.ac.at" target="_blank">michael.mihocic@oeaw.ac.at</a><br>
    </div></div>
  </div>

</blockquote></div><br></div></div>