English 中文(简体)
OpenGLView没有显示
原标题:OpenGLView fails to display

之后,我收到了,该指南

Whereas I sincerely failed to understand what it says at point 13, I just have opened the pane of the inspector, but it doesn t say what attributes to set. However, I have copied and pasted the code in the proper classes. But it appears a normal window, without the triangle draw, just like when I make a normal program in Objective-C having an empty window.

Edit:

我认为,问题在于窗户的初始化,因此,我撰写了一种觉醒基金从尼伯开始的方法:

- (void) awakeFromNib
{
    NSRect rect=NSMakeRect(100.0, 100.0, 100.0, 100.0);
    [self drawRect: rect];
}

但是,在第一项指示中, Rect I have an EXC_BAD_ 缩略语

glClearColor(0, 0, 0, 0);

Maybe the window is not initialized properly?

最佳回答

也许你会受到指责,因为开放式利比里亚联盟试图在目前情况下改变某些状态,而目前的情况却不存在(因为你寄了<代码>-drawRect:,而没有首先确定目前的情况)。

www.un.org/spanish/ecosoc 页: 1

- (void)awakeFromNib {
  self.needsDisplay = YES;
}
问题回答

暂无回答




相关问题
OpenGL 3D Selection

I am trying to create a 3D robot that should perform certain actions when certain body parts are clicked. I have successfully (sort of) implemented picking in that if you click on any x-plane part, it ...

CVDisplayLink instead of NSTimer

I have started to implement cvDisplayLink to drive the render loop instead of nstimer, as detailed in this technical note https://developer.apple.com/library/archive/qa/qa1385/_index.html Is it ...

Can the iPhone simulator handle PVR textures?

I have a really weird problem with PVR textures on the iPhone simulator- the framerate falls through the floor on the iPhone simulator, but on the iPhone itself it works just fine. Has anyone had any ...

Calculate fps (frames per second) for iphone app

I am using an opengl es iphone application. What is the most accurate way to calculate the frames per second of my application for performance tuning?

Java - Zoom / 3D Data Visualization Libraries

What are the best libraries/frameworks for doing 3D and/or Zoom interfaces in Java? I d like to be able to do some prototyping of creating new types of interfaces for navigating within data and ...

FLTK in Cygwin using Eclipse (Linking errors)

I have this assignment due that requires the usage of FLTK. The code is given to us and it should compile straight off of the bat, but I am having linking errors and do not know which other libraries ...

热门标签