48 if (baseFormat == GL_RGB
49 || baseFormat == GL_BGR
50 || baseFormat == GL_YCBCR_422_APPLE)
52 if (imageColorDepth == VuoImageColorDepth_16)
54 if (imageColorDepth == VuoImageColorDepth_32)
58 else if (baseFormat == GL_RGBA
59 || baseFormat == GL_BGRA)
61 if (imageColorDepth == VuoImageColorDepth_16)
62 return GL_RGBA16F_ARB;
63 if (imageColorDepth == VuoImageColorDepth_32)
64 return GL_RGBA32F_ARB;
67 else if (baseFormat == GL_LUMINANCE)
69 if (imageColorDepth == VuoImageColorDepth_16)
70 return GL_LUMINANCE16F_ARB;
71 if (imageColorDepth == VuoImageColorDepth_32)
72 return GL_LUMINANCE32F_ARB;
75 else if (baseFormat == GL_LUMINANCE_ALPHA)
77 if (imageColorDepth == VuoImageColorDepth_16)
78 return GL_LUMINANCE_ALPHA16F_ARB;
79 if (imageColorDepth == VuoImageColorDepth_32)
80 return GL_LUMINANCE_ALPHA32F_ARB;
81 return GL_LUMINANCE8_ALPHA8;
85 VUserLog(
"Error: Unknown baseFormat %x (%s)", baseFormat, formatString);