[Lazarus] TOpenGLControl.DepthBits default value

Reimar Grabowski reimgrab at web.de
Wed Jan 23 19:39:59 CET 2013


On Wed, 23 Jan 2013 00:21:44 +0100
Michalis Kamburelis <michalis.kambi at gmail.com> wrote:

First of all thanks for the explanation.

> The general idea is that TOpenGLControl has safe default values, that 
> are guaranteed to work (and be fast) even on really really ancient 
> graphic cards or when the system is running under virtual machine (which 
> often means you don't get hardware-accelarated 3D until you explicitly 
> install/enable something).
Well "really, really ancient" is the correct term and in my experience 3D on virtual machines even if supported is not really that useful.

> For the same reason e.g. 
> TOpenGLControl.StencilBits is by default 0, even though all modern GPUs 
> can give you at least 8-bit stencil buffer.
This I think is absolutely correct as the stencil buffer is only used for special/advanced stuff that in general not many people need. And if they do they should know how to get one.

> That said, I would be personally fine with changing this default to 24, 
> if others think it's a good idea. A developer can always lower it to 16 
> when that's enough. So, I don't really have a strong preference about it.
I think that it would be good for people new to OpenGL to give them the better depth buffer precision as default. Z-Fighting and other nasty stuff happens much earlier on the lower precision one. Personally I can live with the 16 bit default as well. It is just a slight inconvenience that I have to change it for every new project.
So I vote for 24 as default.

R.




More information about the Lazarus mailing list