pyopengltk icon indicating copy to clipboard operation
pyopengltk copied to clipboard

[WIP] First rushed attempt getting os x frame working

Open einarf opened this issue 5 years ago • 5 comments

Work in progress

Leaving this PR here hanging for a bit to share what I have done so far.

If anyone have any input on how to get the surface of the tkinter window and register it in the context?

CGLSetSurface connects a surface that is part of a window to a GL context

einarf avatar Oct 15 '19 17:10 einarf

I have no idea yet. Thanks for the links. Will add that to the list of things to dig into.

Can let this PR hang here for a while. We can merge it if I give up this attempt, but we should probably disable the darwin import.

einarf avatar Oct 15 '19 20:10 einarf

An alternative is using AGL : https://developer.apple.com/documentation/agl/agl

Probabably a good idea to do a deep dive into the internals in TkInter. I'll make a Frame implementation for both cgl and agl. Time will see what works out.

The togl 2.0 source is using agl and is a great reference!

einarf avatar Oct 18 '19 14:10 einarf

Still have not forgotten about this one. I think using agl is the right path. Still doing local experiments for now until I figure out the best solution.

einarf avatar Nov 23 '19 00:11 einarf

AGL seem to be the way to go. I just need to figure out how to get the proper window pointer.

einarf avatar Jan 10 '20 17:01 einarf

Hi mate, what is the status on this PR? Just ran into this today while running vispy

mitchell-merry avatar Oct 23 '23 02:10 mitchell-merry