diff options
Diffstat (limited to 'src/mesa/swrast')
-rw-r--r-- | src/mesa/swrast/s_drawpix.c | 8 | ||||
-rw-r--r-- | src/mesa/swrast/s_renderbuffer.c | 4 | ||||
-rw-r--r-- | src/mesa/swrast/s_texfetch.c | 16 | ||||
-rw-r--r-- | src/mesa/swrast/s_texfetch_tmp.h | 12 | ||||
-rw-r--r-- | src/mesa/swrast/s_texfilter.c | 8 | ||||
-rw-r--r-- | src/mesa/swrast/s_triangle.c | 16 |
6 files changed, 32 insertions, 32 deletions
diff --git a/src/mesa/swrast/s_drawpix.c b/src/mesa/swrast/s_drawpix.c index 1786de1a397..ce15f02e35b 100644 --- a/src/mesa/swrast/s_drawpix.c +++ b/src/mesa/swrast/s_drawpix.c @@ -223,8 +223,8 @@ fast_draw_rgba_pixels(struct gl_context *ctx, GLint x, GLint y, if (format == GL_RGB && type == GL_UNSIGNED_BYTE && - (rb->Format == MESA_FORMAT_XRGB8888 || - rb->Format == MESA_FORMAT_ARGB8888)) { + (rb->Format == MESA_FORMAT_B8G8R8X8_UNORM || + rb->Format == MESA_FORMAT_B8G8R8A8_UNORM)) { fast_draw_rgb_ubyte_pixels(ctx, rb, x, y, width, height, &unpack, pixels); return GL_TRUE; @@ -232,8 +232,8 @@ fast_draw_rgba_pixels(struct gl_context *ctx, GLint x, GLint y, if (format == GL_RGBA && type == GL_UNSIGNED_BYTE && - (rb->Format == MESA_FORMAT_XRGB8888 || - rb->Format == MESA_FORMAT_ARGB8888)) { + (rb->Format == MESA_FORMAT_B8G8R8X8_UNORM || + rb->Format == MESA_FORMAT_B8G8R8A8_UNORM)) { fast_draw_rgba_ubyte_pixels(ctx, rb, x, y, width, height, &unpack, pixels); return GL_TRUE; diff --git a/src/mesa/swrast/s_renderbuffer.c b/src/mesa/swrast/s_renderbuffer.c index a19d02ac0cd..28c1eb07be9 100644 --- a/src/mesa/swrast/s_renderbuffer.c +++ b/src/mesa/swrast/s_renderbuffer.c @@ -81,9 +81,9 @@ soft_renderbuffer_storage(struct gl_context *ctx, struct gl_renderbuffer *rb, case GL_RGBA12: #endif if (_mesa_little_endian()) - rb->Format = MESA_FORMAT_RGBA8888_REV; + rb->Format = MESA_FORMAT_R8G8B8A8_UNORM; else - rb->Format = MESA_FORMAT_RGBA8888; + rb->Format = MESA_FORMAT_A8B8G8R8_UNORM; break; case GL_RGBA16: case GL_RGBA16_SNORM: diff --git a/src/mesa/swrast/s_texfetch.c b/src/mesa/swrast/s_texfetch.c index 7f9d3860ec5..7a5ff447c34 100644 --- a/src/mesa/swrast/s_texfetch.c +++ b/src/mesa/swrast/s_texfetch.c @@ -149,49 +149,49 @@ texfetch_funcs[] = }, { - MESA_FORMAT_RGBA8888, + MESA_FORMAT_A8B8G8R8_UNORM, fetch_texel_1d_f_rgba8888, fetch_texel_2d_f_rgba8888, fetch_texel_3d_f_rgba8888 }, { - MESA_FORMAT_RGBA8888_REV, + MESA_FORMAT_R8G8B8A8_UNORM, fetch_texel_1d_f_rgba8888_rev, fetch_texel_2d_f_rgba8888_rev, fetch_texel_3d_f_rgba8888_rev }, { - MESA_FORMAT_ARGB8888, + MESA_FORMAT_B8G8R8A8_UNORM, fetch_texel_1d_f_argb8888, fetch_texel_2d_f_argb8888, fetch_texel_3d_f_argb8888 }, { - MESA_FORMAT_ARGB8888_REV, + MESA_FORMAT_A8R8G8B8_UNORM, fetch_texel_1d_f_argb8888_rev, fetch_texel_2d_f_argb8888_rev, fetch_texel_3d_f_argb8888_rev }, { - MESA_FORMAT_RGBX8888, + MESA_FORMAT_X8B8G8R8_UNORM, fetch_texel_1d_f_rgbx8888, fetch_texel_2d_f_rgbx8888, fetch_texel_3d_f_rgbx8888 }, { - MESA_FORMAT_RGBX8888_REV, + MESA_FORMAT_R8G8B8X8_UNORM, fetch_texel_1d_f_rgbx8888_rev, fetch_texel_2d_f_rgbx8888_rev, fetch_texel_3d_f_rgbx8888_rev }, { - MESA_FORMAT_XRGB8888, + MESA_FORMAT_B8G8R8X8_UNORM, fetch_texel_1d_f_xrgb8888, fetch_texel_2d_f_xrgb8888, fetch_texel_3d_f_xrgb8888 }, { - MESA_FORMAT_XRGB8888_REV, + MESA_FORMAT_X8R8G8B8_UNORM, fetch_texel_1d_f_xrgb8888_rev, fetch_texel_2d_f_xrgb8888_rev, fetch_texel_3d_f_xrgb8888_rev diff --git a/src/mesa/swrast/s_texfetch_tmp.h b/src/mesa/swrast/s_texfetch_tmp.h index e2521b50c22..c5171ecd1ee 100644 --- a/src/mesa/swrast/s_texfetch_tmp.h +++ b/src/mesa/swrast/s_texfetch_tmp.h @@ -388,7 +388,7 @@ static void FETCH(f_rg_f16)( const struct swrast_texture_image *texImage, * Begin Hardware formats */ -/* MESA_FORMAT_RGBA8888 ******************************************************/ +/* MESA_FORMAT_A8B8G8R8_UNORM ******************************************************/ /* Fetch texel from 1D, 2D or 3D rgba8888 texture, return 4 GLfloats */ static void FETCH(f_rgba8888)( const struct swrast_texture_image *texImage, @@ -422,7 +422,7 @@ static void FETCH(f_rgba8888_rev)( const struct swrast_texture_image *texImage, -/* MESA_FORMAT_ARGB8888 ******************************************************/ +/* MESA_FORMAT_B8G8R8A8_UNORM ******************************************************/ /* Fetch texel from 1D, 2D or 3D argb8888 texture, return 4 GLchans */ static void FETCH(f_argb8888)( const struct swrast_texture_image *texImage, @@ -438,7 +438,7 @@ static void FETCH(f_argb8888)( const struct swrast_texture_image *texImage, -/* MESA_FORMAT_ARGB8888_REV **************************************************/ +/* MESA_FORMAT_A8R8G8B8_UNORM **************************************************/ /* Fetch texel from 1D, 2D or 3D argb8888_rev texture, return 4 GLfloats */ static void FETCH(f_argb8888_rev)( const struct swrast_texture_image *texImage, @@ -454,7 +454,7 @@ static void FETCH(f_argb8888_rev)( const struct swrast_texture_image *texImage, -/* MESA_FORMAT_RGBX8888 ******************************************************/ +/* MESA_FORMAT_X8B8G8R8_UNORM ******************************************************/ /* Fetch texel from 1D, 2D or 3D rgbx8888 texture, return 4 GLfloats */ static void FETCH(f_rgbx8888)( const struct swrast_texture_image *texImage, @@ -486,7 +486,7 @@ static void FETCH(f_rgbx8888_rev)( const struct swrast_texture_image *texImage, -/* MESA_FORMAT_XRGB8888 ******************************************************/ +/* MESA_FORMAT_B8G8R8X8_UNORM ******************************************************/ /* Fetch texel from 1D, 2D or 3D xrgb8888 texture, return 4 GLchans */ static void FETCH(f_xrgb8888)( const struct swrast_texture_image *texImage, @@ -502,7 +502,7 @@ static void FETCH(f_xrgb8888)( const struct swrast_texture_image *texImage, -/* MESA_FORMAT_XRGB8888_REV **************************************************/ +/* MESA_FORMAT_X8R8G8B8_UNORM **************************************************/ /* Fetch texel from 1D, 2D or 3D xrgb8888_rev texture, return 4 GLfloats */ static void FETCH(f_xrgb8888_rev)( const struct swrast_texture_image *texImage, diff --git a/src/mesa/swrast/s_texfilter.c b/src/mesa/swrast/s_texfilter.c index 312b9ce9bf7..6e87fc910e4 100644 --- a/src/mesa/swrast/s_texfilter.c +++ b/src/mesa/swrast/s_texfilter.c @@ -1473,7 +1473,7 @@ opt_sample_rgba_2d(struct gl_context *ctx, ASSERT(samp->WrapS==GL_REPEAT); ASSERT(samp->WrapT==GL_REPEAT); ASSERT(img->Border==0); - ASSERT(img->TexFormat == MESA_FORMAT_RGBA8888); + ASSERT(img->TexFormat == MESA_FORMAT_A8B8G8R8_UNORM); ASSERT(swImg->_IsPowerOfTwo); (void) swImg; @@ -1525,7 +1525,7 @@ sample_lambda_2d(struct gl_context *ctx, opt_sample_rgb_2d(ctx, samp, tObj, m, texcoords + minStart, NULL, rgba + minStart); break; - case MESA_FORMAT_RGBA8888: + case MESA_FORMAT_A8B8G8R8_UNORM: opt_sample_rgba_2d(ctx, samp, tObj, m, texcoords + minStart, NULL, rgba + minStart); break; @@ -1582,7 +1582,7 @@ sample_lambda_2d(struct gl_context *ctx, opt_sample_rgb_2d(ctx, samp, tObj, m, texcoords + magStart, NULL, rgba + magStart); break; - case MESA_FORMAT_RGBA8888: + case MESA_FORMAT_A8B8G8R8_UNORM: opt_sample_rgba_2d(ctx, samp, tObj, m, texcoords + magStart, NULL, rgba + magStart); break; @@ -3762,7 +3762,7 @@ _swrast_choose_texture_sample_func( struct gl_context *ctx, img->Border == 0) { if (img->TexFormat == MESA_FORMAT_RGB888) func = &opt_sample_rgb_2d; - else if (img->TexFormat == MESA_FORMAT_RGBA8888) + else if (img->TexFormat == MESA_FORMAT_A8B8G8R8_UNORM) func = &opt_sample_rgba_2d; } diff --git a/src/mesa/swrast/s_triangle.c b/src/mesa/swrast/s_triangle.c index 69c812f97f8..b694bbe6188 100644 --- a/src/mesa/swrast/s_triangle.c +++ b/src/mesa/swrast/s_triangle.c @@ -437,7 +437,7 @@ affine_span(struct gl_context *ctx, SWspan *span, return; } break; - case MESA_FORMAT_RGBA8888: + case MESA_FORMAT_A8B8G8R8_UNORM: switch(info->envmode) { case GL_MODULATE: SPAN_NEAREST(NEAREST_RGBA;MODULATE,4); @@ -486,7 +486,7 @@ affine_span(struct gl_context *ctx, SWspan *span, return; } break; - case MESA_FORMAT_RGBA8888: + case MESA_FORMAT_A8B8G8R8_UNORM: switch (info->envmode) { case GL_MODULATE: SPAN_LINEAR(LINEAR_RGBA;MODULATE,4); @@ -575,7 +575,7 @@ affine_span(struct gl_context *ctx, SWspan *span, case MESA_FORMAT_RGB888: \ info.tbytesline = texImg->Width * 3; \ break; \ - case MESA_FORMAT_RGBA8888: \ + case MESA_FORMAT_A8B8G8R8_UNORM: \ info.tbytesline = texImg->Width * 4; \ break; \ default: \ @@ -709,7 +709,7 @@ fast_persp_span(struct gl_context *ctx, SWspan *span, return; } break; - case MESA_FORMAT_RGBA8888: + case MESA_FORMAT_A8B8G8R8_UNORM: switch(info->envmode) { case GL_MODULATE: SPAN_NEAREST(NEAREST_RGBA;MODULATE,4); @@ -756,7 +756,7 @@ fast_persp_span(struct gl_context *ctx, SWspan *span, return; } break; - case MESA_FORMAT_RGBA8888: + case MESA_FORMAT_A8B8G8R8_UNORM: switch (info->envmode) { case GL_MODULATE: SPAN_LINEAR(LINEAR_RGBA;MODULATE,4); @@ -841,7 +841,7 @@ fast_persp_span(struct gl_context *ctx, SWspan *span, case MESA_FORMAT_RGB888: \ info.tbytesline = texImg->Width * 3; \ break; \ - case MESA_FORMAT_RGBA8888: \ + case MESA_FORMAT_A8B8G8R8_UNORM: \ info.tbytesline = texImg->Width * 4; \ break; \ default: \ @@ -1080,7 +1080,7 @@ _swrast_choose_triangle( struct gl_context *ctx ) && texImg->Border == 0 && (_mesa_format_row_stride(format, texImg->Width) == swImg->RowStride) - && (format == MESA_FORMAT_RGB888 || format == MESA_FORMAT_RGBA8888) + && (format == MESA_FORMAT_RGB888 || format == MESA_FORMAT_A8B8G8R8_UNORM) && minFilter == magFilter && ctx->Light.Model.ColorControl == GL_SINGLE_COLOR && !swrast->_FogEnabled @@ -1107,7 +1107,7 @@ _swrast_choose_triangle( struct gl_context *ctx ) #if CHAN_BITS != 8 USE(general_triangle); #else - if (format == MESA_FORMAT_RGBA8888 && !_mesa_little_endian()) { + if (format == MESA_FORMAT_A8B8G8R8_UNORM && !_mesa_little_endian()) { /* We only handle RGBA8888 correctly on little endian * in the optimized code above. */ |