From: Brian P. <br...@vm...> - 2010-04-14 20:54:25
|
Joe Miller wrote: > Hi, > > I just downloaded Mesa 7.8.1 and built it on Solaris 10. After getting the libraries to compile, I attempted to verify the build using the demo apps. In particular I use the offscreen rendering mesa libraries provide. However, when I ran the ostest1 demo, the test program fails on to retrieve the correct size for the GL_RED_BITS. It seems to always be returning 8 even though the context was set to a large data type. > > In particular the lines of code that are failing include > > <snip> > /* Bind the buffer to the context and make it current */ > if (!OSMesaMakeCurrent( ctx, buffer, type, WIDTH, HEIGHT )) { > printf("OSMesaMakeCurrent (%d bits/channel) failed!\n", bits); > free(buffer); > OSMesaDestroyContext(ctx); > return 0; > } > > /* sanity checks */ > glGetIntegerv(GL_RED_BITS, &cBits); > assert(cBits == bits); > <snip> > > where type would be something other than GL_UNSIGNED_BYTE and therefore bits something larger than 8. The assert fails. I have version 7.0.3 running and this test passes. Furthermore, if I remove the sanity check the images come out correct. > > I was wondering if anyone has exprienced the same issue? I've built on Solaris 10 using SunStudio 12 compiler. If you need any more information. Please let me know. > > Thanks for the help. Mesa must be specially compiled to support 16 and 32-bit / channel rendering. Specifically, pass -DCHAN_BITS=16 or -DCHAN_BITS=32 to the compiler. The linux-osmesa16 and linux-osmes32 configs are examples. It should be easy to adapt one of those to Solaris. -Brian |