Yeah, thanks, I already had to override that method for resizing the viewport.
2016-10-04 15:36 GMT+02:00 Benjamin Moran <[email protected]>: > By the way, if you are using a modern OpenGL context (3.2+) you may have > to override the default pyglet window's "on_resize" method. This is becuase > it contains some legacy OpenGL code to reset the view when you resize the > window. Since you're using shaders this will be unnecessary, so you can > just bypass it with: > > @window.event > def on_resize(w, h): > return pyglet.event.EVENT_HANDLED > > > Of course, replace the @window.event with whatever your window instance is > named, or just make this method in your class if you're subclassing > pyglet.window.Window. You may also want to put some code in here for > updating your shader uniforms and such with the w & h values, if needed. > > -Ben > > > > On Tuesday, October 4, 2016 at 10:29:48 PM UTC+9, Gábor Fekete wrote: >> >> It seems I got it working using pyopengl shaders. A simple passthrough >> shader program with vertex,geometry and fragment shaders does work. Now I >> only have to switch rendering from immediate mode to modern buffers. >> Thank you Adam Bark! >> >> 2016-10-03 10:13 GMT+02:00 Gábor Fekete <[email protected]>: >> >>> Do I just import pyopengl and call gl* functions and it will be the >>> same? I couldn't find the usage of pyglet and pyopengl together. >>> >>> 2016-09-30 15:44 GMT+02:00 Adam Bark <[email protected]>: >>> >>>> Have you tried pyopengl for your rendering? >>>> >>>> On 29 September 2016 23:41:00 BST, "Gábor Fekete" < >>>> [email protected]> wrote: >>>>> >>>>> I'm working on a little project as hobby. It uses pyglet mostly and I >>>>> want to render procedural planets and stuff with it. >>>>> My main problem is that pyglet does not support geometry shaders. >>>>> >>>>> Why is that? Is there any way that it will be supported in the near >>>>> future? >>>>> I really need this feature and I don't want to move to another >>>>> language. >>>>> >>>>> If there is nobody on this feature, may I try to get to it? >>>>> >>>>> Thanks! >>>>> >>>>> >>>> -- >>>> Sent from my Android device with K-9 Mail. Please excuse my brevity. >>>> >>>> -- >>>> You received this message because you are subscribed to a topic in the >>>> Google Groups "pyglet-users" group. >>>> To unsubscribe from this topic, visit https://groups.google.com/d/to >>>> pic/pyglet-users/qKam91KNBnE/unsubscribe. >>>> To unsubscribe from this group and all its topics, send an email to >>>> [email protected]. >>>> To post to this group, send email to [email protected]. >>>> Visit this group at https://groups.google.com/group/pyglet-users. >>>> For more options, visit https://groups.google.com/d/optout. >>>> >>> >>> >> -- > You received this message because you are subscribed to a topic in the > Google Groups "pyglet-users" group. > To unsubscribe from this topic, visit https://groups.google.com/d/ > topic/pyglet-users/qKam91KNBnE/unsubscribe. > To unsubscribe from this group and all its topics, send an email to > [email protected]. > To post to this group, send email to [email protected]. > Visit this group at https://groups.google.com/group/pyglet-users. > For more options, visit https://groups.google.com/d/optout. > -- You received this message because you are subscribed to the Google Groups "pyglet-users" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected]. Visit this group at https://groups.google.com/group/pyglet-users. For more options, visit https://groups.google.com/d/optout.
