OpenGL 如何解析像素格式基于整数的多重采样 FBO 附加颜色缓冲区?

How does OpenGL resolve a multisampled FBO-attached color buffer whose pixel format is integer-based?

假设我像这样格式化 renderbuffer

glRenderbufferStorageMultisample(GL_RENDERBUFFER, sampleCount, GL_R32UI, imageWidth, imageHeight);

where sampleCount >= 2.

然后假设我将它附加到一个 FBO,在其中绘制一些东西,将其 blit 到一个非多重采样的 FBO 以解析多重采样,最后调用 glReadPixels 从结果图像。

我会得到什么整数?

它们中的一些可能是多个样本的混合,或者在这种情况下每个像素只选择一个样本(大概是因为在这种情况下基于整数的格式不被认为是可混合的),与其他样本被丢弃?还是发生了其他事情?

在 OpenGL 4.5 规范的第 511 页,第 18.3.1 节 "Blitting Pixel Rectangles" 下,它说(强调):

If the read framebuffer is multisampled (its effective value of SAMPLE_BUFFERS is one) and the draw framebuffer is not (its value of SAMPLE_BUFFERS is zero), the samples corresponding to each pixel location in the source are converted to a single sample before being written to the destination. filter is ignored. If the source formats are integer types or stencil values, a single sample’s value is selected for each pixel.

所以它为每个像素选择一个样本,但没有指定是哪个样本。