mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-08 11:18:08 +02:00
added a couple new assertions to help debug XGL problem
This commit is contained in:
parent
2d4ff6a8cf
commit
1814d6541b
1 changed files with 2 additions and 0 deletions
|
|
@ -253,6 +253,7 @@ static int bits_per_pixel( XMesaVisual xmv )
|
|||
{
|
||||
const int depth = xmv->nplanes;
|
||||
int i;
|
||||
assert(depth > 0);
|
||||
for (i = 0; i < screenInfo.numPixmapFormats; i++) {
|
||||
if (screenInfo.formats[i].depth == depth)
|
||||
return screenInfo.formats[i].bitsPerPixel;
|
||||
|
|
@ -1563,6 +1564,7 @@ XMesaVisual XMesaCreateVisual( XMesaDisplay *display,
|
|||
* ColormapEntries is either (1U << index_bits) or
|
||||
* (1U << max(redBits, greenBits, blueBits)).
|
||||
*/
|
||||
assert(visinfo->nplanes > 0);
|
||||
v->nplanes = visinfo->nplanes;
|
||||
v->ColormapEntries = visinfo->ColormapEntries;
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue