Re: [PyOpenGL-Users] GL_VENDOR
Brought to you by:
mcfletch
From: Mads I. <mp...@co...> - 2009-09-25 12:31:47
|
Greg Ewing wrote: > Mads Ipsen wrote: > >> How come glGetString(GL_VENDOR) returns None if I don't have an OpenGL >> context? >> > > Because you don't *have* an OpenGL vendor until you > have a context. Contexts belonging to different > display devices can be using drivers from different > vendors, so it's a property of the context rather > than something global. > > Something it's easy to overlook about OpenGL is > that it's really an object-oriented system, with > almost all of the functions being methods of the > context. But the API does a good job of hiding this > by making the current context an implicit global > parameter. > > Thanks for the answer. My question can then be boiled down to: How do I in the simplest possible manner set up an OpenGL context so I can query the vendor string? Best regards, Mads -- +------------------------------------------------------------+ | Mads Ipsen, Scientific developer | +------------------------------+-----------------------------+ | QuantumWise A/S | phone: +45-29716388 | | Nørresøgade 27A | www: www.quantumwise.com | | DK-1370 Copenhagen, Denmark | email: mp...@qu... | +------------------------------+-----------------------------+ |