Преглед на файлове

st/mesa: consolidate listing of depth formats

Reviewed-by: Brian Paul <brianp@vmware.com>
tags/mesa-7.11-rc1
Marek Olšák преди 14 години
родител
ревизия
6c638b7ca1
променени са 1 файла, в които са добавени 12 реда и са изтрити 11 реда
  1. 12
    11
      src/mesa/state_tracker/st_format.c

+ 12
- 11
src/mesa/state_tracker/st_format.c Целия файл

@@ -595,6 +595,14 @@ struct format_mapping
PIPE_FORMAT_A8B8G8R8_SRGB, \
0

#define DEFAULT_DEPTH_FORMATS \
PIPE_FORMAT_Z24X8_UNORM, \
PIPE_FORMAT_X8Z24_UNORM, \
PIPE_FORMAT_Z16_UNORM, \
PIPE_FORMAT_Z24_UNORM_S8_USCALED, \
PIPE_FORMAT_S8_USCALED_Z24_UNORM, \
0

/**
* This table maps OpenGL texture format enums to Gallium pipe_format enums.
* Multiple GL enums might map to multiple pipe_formats.
@@ -736,27 +744,20 @@ static struct format_mapping format_map[] = {
/* Depth formats */
{
{ GL_DEPTH_COMPONENT16, 0 },
{ PIPE_FORMAT_Z16_UNORM, PIPE_FORMAT_Z24_UNORM_S8_USCALED,
PIPE_FORMAT_S8_USCALED_Z24_UNORM, PIPE_FORMAT_Z32_UNORM, 0 }
{ PIPE_FORMAT_Z16_UNORM, DEFAULT_DEPTH_FORMATS }
},
{
{ GL_DEPTH_COMPONENT24, 0 },
{ PIPE_FORMAT_Z24X8_UNORM, PIPE_FORMAT_X8Z24_UNORM,
PIPE_FORMAT_Z24_UNORM_S8_USCALED, PIPE_FORMAT_S8_USCALED_Z24_UNORM,
PIPE_FORMAT_Z32_UNORM, 0 }
DEFAULT_DEPTH_FORMATS }
},
{
{ GL_DEPTH_COMPONENT32, 0 },
{ PIPE_FORMAT_Z32_UNORM,
PIPE_FORMAT_Z24X8_UNORM, PIPE_FORMAT_X8Z24_UNORM,
PIPE_FORMAT_Z16_UNORM,
PIPE_FORMAT_Z24_UNORM_S8_USCALED, PIPE_FORMAT_S8_USCALED_Z24_UNORM, 0 }
{ PIPE_FORMAT_Z32_UNORM, DEFAULT_DEPTH_FORMATS }
},
{
{ GL_DEPTH_COMPONENT, 0 },
{ PIPE_FORMAT_Z24X8_UNORM, PIPE_FORMAT_X8Z24_UNORM,
PIPE_FORMAT_Z32_UNORM, PIPE_FORMAT_Z16_UNORM,
PIPE_FORMAT_Z24_UNORM_S8_USCALED, PIPE_FORMAT_S8_USCALED_Z24_UNORM, 0 }
{ DEFAULT_DEPTH_FORMATS }
},

/* stencil formats */

Loading…
Отказ
Запис