NSOpenGLView is an NSView subclass in the Apple Appkit framework. It provides an easy way to create an OpenGL context and embed it inside a Cocoa application.
We have an application that has a full screen video player and a floating window (pallet) can be brought up to give users tools to modify the video, there is only one view for video playback and all the drawing occur in there, its an NSOpenGLView…
I am working on an app that uses 2D textures to create animated kaleidoscopes. It starts out displaying to an NSOpenGLView. I am adding an option to switch to full-screen mode.
I would prefer to use the OS 10.5 approach to full screen so I can…
I've overridden an NSOpenGLView to handle keyboard events. The event detection is working fine, but every time I press a key I hear and annoying bump sound. How can I tell my view to chill out?
Here's what my keyUp: method looks like:
-(void)…
I'm translating the Objective-C code in this repo into Swift, in order to learn some of the basics of OpenGL. I'm totally new to it. I've got a working project that compiles and produces a working NSOpenGLView with a floating rectangle, but the…
I've been trying to get the NSOpenGLView to resize correctly when resizing the window, but I keep getting weird behaviour which I cannot explain. It looks like so:
Original (What it looks like at the beginning):
After resize:
This is my resize…
I have managed to set up an NSOpenGLView using CVDisplayLinkSetOutputCallback as a method to render a scene in my application. Everything appears to be working correctly and the callback method is firing at a pretty decent rate.
So far, I have…
I have a raw bitmap image of RGBA malloc-ed data; rows are obviously a multiple of 4 bytes. This data actually originates from an AVI (24-bit BGR format), but I convert it to 32-bit ARGB. There's about 8mb of 32-bit data (1920x1080) per…
I'm using OpengGL on a Mac OS X application to draw texture on a NSOpenGLView.
The app is a movie player. It decodes movie frames into CVOpenGLTextureRef (which are OpenGL texture) and I draw them directly to the view using GL_QUAD. Everything works…
I work on AudioVisualizer in objective c on Mac OS.
I have 2 NSWindows what has NSOpenGLView in it.
If open only 1 NSWindow with NSOpenGLView, it shows shapes without any issues.
But if open 2 NSWindows what has NSOpenGLView on it, only one GLView…
In IB I placed an NSOpenGLView instance into the window.
I have all of my drawing code inside a custom NSViewController like so:
// MyOpenGLViewController.h
@interface MyOpenGLViewController : NSViewController
{
IBOutlet NSOpenGLView *glView; …
I am developing an interface for an OpenGL Simulation on the Mac using Interface Builder. All OpenGL stuff is being written in C++ (which I know fairly well). Unfortunately I have no idea about Objective-C.
Basically, I have a few NSTextField…
I have two NSOpenGLViews, named myView1 and myView2. myView2 is a sub view of myView1. Then I use CVDisplayLinkCreateWithCGDisplay to create a display link for the main display. Both myView1 and myView2 will draw something in the main thread(i.e. in…
I'm trying to create an OpenGL application using Cocoa API, and by now everything works fine, except for one thing. When the main window is resized the GL context seems not be updated properly.
Here's is the code used to setup window and render…
I want to display something in an NSOpenGLView, but since there is a total of zero bytes of documentation on it, and the sample code is as big and complex as the documentation should be, I can't get any wise out of it. This is my code so far, and my…
I'm working on a Cocoa application that leverages NSOpenGLView driven from a CVDisplayLink thread.
We've recently seen a number of crash reports (in the wild) with the following stack trace. 10.11 only.
#29. Crashed: com.apple.root.default-qos
0 …