Re: How to send matrices to GLSL uniform variables

Jason Dagit <[email protected]> Wed, 12 Sep 2012 20:21:27 -0700
Newsgroups gmane.comp.lang.haskell.hopengl
Message-ID <CAJ-DSyzET8BgqRL_f6YHVp2VLEO+MvhYFTZWMUQKwVv4tYnh8w@mail.gmail.com>
--===============4835939883989856939==
Content-Type: multipart/alternative; boundary=e89a8f2345178f56a104c98ccd3c

--e89a8f2345178f56a104c98ccd3c
Content-Type: text/plain; charset=ISO-8859-1

On Fri, Aug 24, 2012 at 11:40 PM, L Corbijn <[email protected]> wrote:

> On Fri, Aug 24, 2012 at 6:56 PM, Myles C. Maxfield
> <[email protected]> wrote:
> > According to http://hackage.haskell.org/package/OpenGL, it claims to
> support
> > version 3.2, so a lack of glUniformMatrix seems like a huge oversight.
> This
> > makes me think that one of two things is the case:
> >
> > 1. There is a way to do it, but it's non-obvious. Hopefully documentation
> > could fix this.
> > 2. There isn't a way to do it, so either
> >   a. the OpenGL package shouldn't claim to be 3.2 compliant, or
> >   b. the functionality should be added ;-)
> >
> > Does anyone know which case the current package falls into? And/or what
> can
> > be done about making sure no one else in the future has the same problem
> > that Yusuke has? I'd be willing to help out, but I don't know where to
> > start.
> >
> > Thanks,
> > Myles
>
> It's point 2. The cabal package claims 3.2 compliance, though it's at
> most 2.1 compliant (HOpenGLRaw is 3.2 compliant). I've written code
> for 3.0 compliance (see github [pull request]), but that doens't
> include it either yet. It should be incorporated in the Uniform
> typeclass (see Shaders.hs or Sharders/Uniform.hs), but there should be
> a extra typeclass for matrices or it should be added to the tensor
> package.
>
> Lars
>
> [pull request] https://github.com/haskell-opengl/OpenGL/pull/27


Merged. The reminder helped, otherwise I would have continued to forget
about it.

Jason

--e89a8f2345178f56a104c98ccd3c
Content-Type: text/html; charset=ISO-8859-1
Content-Transfer-Encoding: quoted-printable

<br><br><div class=3D"gmail_quote">On Fri, Aug 24, 2012 at 11:40 PM, L Corb=
ijn <span dir=3D"ltr">&lt;<a href=3D"mailto:[email protected]" target=
=3D"_blank">[email protected]</a>&gt;</span> wrote:<br><blockquote cl=
ass=3D"gmail_quote" style=3D"margin:0 0 0 .8ex;border-left:1px #ccc solid;p=
adding-left:1ex">
<div class=3D"im">On Fri, Aug 24, 2012 at 6:56 PM, Myles C. Maxfield<br>
&lt;<a href=3D"mailto:[email protected]">[email protected]</a=
>&gt; wrote:<br>
&gt; According to <a href=3D"http://hackage.haskell.org/package/OpenGL" tar=
get=3D"_blank">http://hackage.haskell.org/package/OpenGL</a>, it claims to =
support<br>
&gt; version 3.2, so a lack of glUniformMatrix seems like a huge oversight.=
 This<br>
&gt; makes me think that one of two things is the case:<br>
&gt;<br>
&gt; 1. There is a way to do it, but it&#39;s non-obvious. Hopefully docume=
ntation<br>
&gt; could fix this.<br>
&gt; 2. There isn&#39;t a way to do it, so either<br>
&gt; =A0 a. the OpenGL package shouldn&#39;t claim to be 3.2 compliant, or<=
br>
&gt; =A0 b. the functionality should be added ;-)<br>
&gt;<br>
&gt; Does anyone know which case the current package falls into? And/or wha=
t can<br>
&gt; be done about making sure no one else in the future has the same probl=
em<br>
&gt; that Yusuke has? I&#39;d be willing to help out, but I don&#39;t know =
where to<br>
&gt; start.<br>
&gt;<br>
&gt; Thanks,<br>
&gt; Myles<br>
<br>
</div>It&#39;s point 2. The cabal package claims 3.2 compliance, though it&=
#39;s at<br>
most 2.1 compliant (HOpenGLRaw is 3.2 compliant). I&#39;ve written code<br>
for 3.0 compliance (see github [pull request]), but that doens&#39;t<br>
include it either yet. It should be incorporated in the Uniform<br>
typeclass (see Shaders.hs or Sharders/Uniform.hs), but there should be<br>
a extra typeclass for matrices or it should be added to the tensor<br>
package.<br>
<br>
Lars<br>
<br>
[pull request] <a href=3D"https://github.com/haskell-opengl/OpenGL/pull/27"=
 target=3D"_blank">https://github.com/haskell-opengl/OpenGL/pull/27</a></bl=
ockquote><div><br></div><div>Merged. The reminder helped, otherwise I would=
 have continued to forget about it.</div>
<div><br></div><div>Jason</div></div>

--e89a8f2345178f56a104c98ccd3c--


--===============4835939883989856939==
Content-Type: text/plain; charset="us-ascii"
MIME-Version: 1.0
Content-Transfer-Encoding: 7bit
Content-Disposition: inline

_______________________________________________
HOpenGL mailing list
[email protected]
http://www.haskell.org/mailman/listinfo/hopengl

--===============4835939883989856939==--