src/render/opengles2/SDL_shaders_gles2.c
author Sam Lantinga <slouken@libsdl.org>
Fri, 11 Feb 2011 19:11:27 -0800
changeset 5260 62d2bc792002
parent 5226 710d00cb3a6a
child 5262 b530ef003506
permissions -rw-r--r--
itsnotabigtruck has given me permission to replace the license for his contribution.
slouken@5201
     1
/*
slouken@5201
     2
    SDL - Simple DirectMedia Layer
slouken@5260
     3
    Copyright (C) 1997-2010 Sam Lantinga
slouken@5201
     4
    Copyright (C) 2010 itsnotabigtruck.
slouken@5201
     5
slouken@5260
     6
    This library is free software; you can redistribute it and/or
slouken@5260
     7
    modify it under the terms of the GNU Lesser General Public
slouken@5260
     8
    License as published by the Free Software Foundation; either
slouken@5260
     9
    version 2.1 of the License, or (at your option) any later version.
slouken@5201
    10
slouken@5260
    11
    This library is distributed in the hope that it will be useful,
slouken@5260
    12
    but WITHOUT ANY WARRANTY; without even the implied warranty of
slouken@5260
    13
    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
slouken@5260
    14
    Lesser General Public License for more details.
slouken@5201
    15
slouken@5260
    16
    You should have received a copy of the GNU Lesser General Public
slouken@5260
    17
    License along with this library; if not, write to the Free Software
slouken@5260
    18
    Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
slouken@5260
    19
slouken@5260
    20
    Sam Lantinga
slouken@5260
    21
    slouken@libsdl.org
slouken@5201
    22
*/
slouken@5201
    23
#include "SDL_config.h"
slouken@5201
    24
slouken@5226
    25
#if SDL_VIDEO_RENDER_OGL_ES2 && !SDL_RENDER_DISABLED
slouken@5201
    26
slouken@5201
    27
#include "SDL_video.h"
slouken@5204
    28
#include "SDL_opengles2.h"
slouken@5201
    29
#include "SDL_shaders_gles2.h"
slouken@5201
    30
#include "SDL_stdinc.h"
slouken@5201
    31
slouken@5201
    32
/*************************************************************************************************
slouken@5201
    33
 * Vertex/fragment shader source                                                                 *
slouken@5201
    34
 *************************************************************************************************/
slouken@5201
    35
slouken@5201
    36
static const Uint8 GLES2_VertexSrc_Default_[] = " \
slouken@5201
    37
    uniform mat4 u_projection; \
slouken@5201
    38
    attribute vec4 a_position; \
slouken@5201
    39
    attribute vec2 a_texCoord; \
slouken@5201
    40
    varying vec2 v_texCoord; \
slouken@5201
    41
    \
slouken@5201
    42
    void main() \
slouken@5201
    43
    { \
slouken@5201
    44
        v_texCoord = a_texCoord; \
slouken@5201
    45
        gl_Position = u_projection * a_position; \
slouken@5201
    46
        gl_PointSize = 1.0; \
slouken@5201
    47
    } \
slouken@5201
    48
";
slouken@5201
    49
slouken@5201
    50
static const Uint8 GLES2_FragmentSrc_SolidSrc_[] = " \
slouken@5201
    51
    precision mediump float; \
slouken@5201
    52
    uniform vec4 u_color; \
slouken@5201
    53
    \
slouken@5201
    54
    void main() \
slouken@5201
    55
    { \
slouken@5201
    56
        gl_FragColor = u_color; \
slouken@5201
    57
    } \
slouken@5201
    58
";
slouken@5201
    59
slouken@5201
    60
static const Uint8 GLES2_FragmentSrc_TextureSrc_[] = " \
slouken@5201
    61
    precision mediump float; \
slouken@5201
    62
    uniform sampler2D u_texture; \
slouken@5201
    63
    uniform vec4 u_modulation; \
slouken@5201
    64
    varying vec2 v_texCoord; \
slouken@5201
    65
    \
slouken@5201
    66
    void main() \
slouken@5201
    67
    { \
slouken@5201
    68
        gl_FragColor = texture2D(u_texture, v_texCoord); \
slouken@5201
    69
        gl_FragColor *= u_modulation; \
slouken@5201
    70
    } \
slouken@5201
    71
";
slouken@5201
    72
slouken@5201
    73
static const GLES2_ShaderInstance GLES2_VertexSrc_Default = {
slouken@5201
    74
    GL_VERTEX_SHADER,
slouken@5201
    75
    GLES2_SOURCE_SHADER,
slouken@5201
    76
    sizeof(GLES2_VertexSrc_Default_),
slouken@5201
    77
    GLES2_VertexSrc_Default_
slouken@5201
    78
};
slouken@5201
    79
slouken@5201
    80
static const GLES2_ShaderInstance GLES2_FragmentSrc_SolidSrc = {
slouken@5201
    81
    GL_FRAGMENT_SHADER,
slouken@5201
    82
    GLES2_SOURCE_SHADER,
slouken@5201
    83
    sizeof(GLES2_FragmentSrc_SolidSrc_),
slouken@5201
    84
    GLES2_FragmentSrc_SolidSrc_
slouken@5201
    85
};
slouken@5201
    86
slouken@5201
    87
static const GLES2_ShaderInstance GLES2_FragmentSrc_TextureSrc = {
slouken@5201
    88
    GL_FRAGMENT_SHADER,
slouken@5201
    89
    GLES2_SOURCE_SHADER,
slouken@5201
    90
    sizeof(GLES2_FragmentSrc_TextureSrc_),
slouken@5201
    91
    GLES2_FragmentSrc_TextureSrc_
slouken@5201
    92
};
slouken@5201
    93
slouken@5201
    94
/*************************************************************************************************
slouken@5201
    95
 * Vertex/fragment shader binaries (NVIDIA Tegra 1/2)                                            *
slouken@5201
    96
 *************************************************************************************************/
slouken@5201
    97
slouken@5201
    98
#if GLES2_INCLUDE_NVIDIA_SHADERS
slouken@5201
    99
slouken@5201
   100
#define GL_NVIDIA_PLATFORM_BINARY_NV 0x890B
slouken@5201
   101
slouken@5201
   102
static const Uint8 GLES2_VertexTegra_Default_[] = {
slouken@5201
   103
    243, 193, 1, 142, 31, 109, 131, 38, 6, 0, 1, 0, 5, 0, 0, 0, 17, 0, 0, 0, 1, 0, 0, 0, 73, 0,
slouken@5201
   104
    0, 0, 46, 0, 0, 0, 48, 0, 0, 0, 2, 0, 0, 0, 85, 0, 0, 0, 2, 0, 0, 0, 24, 0, 0, 0, 3, 0, 0, 0,
slouken@5201
   105
    91, 0, 0, 0, 1, 0, 0, 0, 16, 0, 0, 0, 5, 0, 0, 0, 95, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
slouken@5201
   106
    0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 95, 0, 0, 0, 1, 0, 0, 0, 28, 0, 0, 0,
slouken@5201
   107
    13, 0, 0, 0, 102, 0, 0, 0, 2, 0, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
slouken@5201
   108
    0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
slouken@5201
   109
    0, 0, 0, 16, 0, 0, 0, 104, 0, 0, 0, 1, 0, 0, 0, 32, 0, 0, 0, 17, 0, 0, 0, 112, 0, 0, 0, 0, 0,
slouken@5201
   110
    0, 0, 0, 0, 0, 0, 18, 0, 0, 0, 112, 0, 0, 0, 80, 0, 0, 0, 80, 0, 0, 0, 19, 0, 0, 0, 132, 0,
slouken@5201
   111
    0, 0, 104, 0, 0, 0, 104, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
slouken@5201
   112
    0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 109, 97, 110, 70, 73, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 97,
slouken@5201
   113
    95, 112, 111, 115, 105, 116, 105, 111, 110, 0, 97, 95, 116, 101, 120, 67, 111, 111, 114, 100,
slouken@5201
   114
    0, 118, 95, 116, 101, 120, 67, 111, 111, 114, 100, 0, 117, 95, 112, 114, 111, 106, 101, 99,
slouken@5201
   115
    116, 105, 111, 110, 0, 0, 0, 0, 0, 0, 0, 82, 139, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 80, 139, 0,
slouken@5201
   116
    0, 1, 0, 0, 0, 22, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 2, 0, 0, 0, 33, 0, 0, 0, 92, 139, 0, 0,
slouken@5201
   117
    1, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 240, 0, 0, 0, 0, 0, 0, 1, 0,
slouken@5201
   118
    0, 0, 64, 0, 0, 0, 80, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 3, 0, 0, 0, 193, 0, 0, 0,
slouken@5201
   119
    0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
slouken@5201
   120
    0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
slouken@5201
   121
    0, 0, 0, 0, 128, 63, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5, 66, 24, 0, 6, 34, 108, 28,
slouken@5201
   122
    0, 0, 42, 16, 128, 0, 195, 192, 6, 129, 252, 255, 65, 96, 108, 28, 0, 0, 0, 0, 0, 1, 195, 192,
slouken@5201
   123
    6, 1, 252, 255, 33, 96, 108, 156, 31, 64, 8, 1, 64, 0, 131, 192, 6, 1, 156, 159, 65, 96, 108,
slouken@5201
   124
    28, 0, 0, 85, 32, 0, 1, 195, 192, 6, 1, 252, 255, 33, 96, 108, 156, 31, 64, 0, 64, 64, 0, 131,
slouken@5201
   125
    192, 134, 1, 152, 31, 65, 96, 108, 156, 31, 64, 127, 48, 0, 1, 195, 192, 6, 129, 129, 255, 33,
slouken@5201
   126
    96
slouken@5201
   127
};
slouken@5201
   128
slouken@5201
   129
static const Uint8 GLES2_FragmentTegra_None_SolidSrc_[] = {
slouken@5201
   130
    155, 191, 159, 1, 47, 109, 131, 38, 6, 0, 1, 0, 5, 0, 0, 0, 17, 0, 0, 0, 1, 0, 0, 0, 73, 0,
slouken@5201
   131
    0, 0, 8, 0, 0, 0, 8, 0, 0, 0, 2, 0, 0, 0, 75, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 75,
slouken@5201
   132
    0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0, 0, 75, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 0, 0,
slouken@5201
   133
    75, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 75, 0, 0, 0, 1, 0, 0, 0, 28, 0, 0, 0, 13, 0,
slouken@5201
   134
    0, 0, 82, 0, 0, 0, 2, 0, 0, 0, 8, 0, 0, 0, 14, 0, 0, 0, 84, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
slouken@5201
   135
    22, 0, 0, 0, 84, 0, 0, 0, 8, 0, 0, 0, 32, 0, 0, 0, 23, 0, 0, 0, 92, 0, 0, 0, 1, 0, 0, 0, 4,
slouken@5201
   136
    0, 0, 0, 15, 0, 0, 0, 93, 0, 0, 0, 1, 0, 0, 0, 80, 0, 0, 0, 17, 0, 0, 0, 113, 0, 0, 0, 0, 0,
slouken@5201
   137
    0, 0, 0, 0, 0, 0, 18, 0, 0, 0, 113, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 19, 0, 0, 0, 113, 0, 0,
slouken@5201
   138
    0, 108, 0, 0, 0, 108, 0, 0, 0, 20, 0, 0, 0, 113, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 21, 0, 0,
slouken@5201
   139
    0, 113, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 109, 97, 110, 70, 73, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
slouken@5201
   140
    0, 117, 95, 99, 111, 108, 111, 114, 0, 0, 0, 0, 0, 82, 139, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 0,
slouken@5201
   141
    0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5, 48, 0, 0, 0, 0, 0, 0, 0, 0, 0, 241, 0, 0, 0, 240, 0, 0,
slouken@5201
   142
    0, 240, 0, 0, 0, 240, 0, 0, 0, 240, 0, 0, 0, 240, 0, 0, 0, 240, 0, 0, 0, 240, 0, 0, 0, 0, 0,
slouken@5201
   143
    0, 0, 0, 1, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 21, 32, 0, 0, 0, 0, 0,
slouken@5201
   144
    0, 0, 0, 0, 0, 20, 0, 0, 0, 16, 0, 0, 0, 16, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0,
slouken@5201
   145
    0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 65, 82, 50, 48, 45, 66, 73, 78, 1,
slouken@5201
   146
    0, 0, 0, 1, 0, 0, 0, 1, 0, 65, 37, 0, 0, 0, 0, 1, 0, 0, 21, 0, 0, 0, 0, 1, 0, 1, 38, 0, 0, 0,
slouken@5201
   147
    0, 1, 0, 1, 39, 0, 0, 0, 0, 1, 0, 1, 40, 1, 0, 0, 0, 8, 0, 4, 40, 0, 40, 0, 0, 0, 242, 65, 63,
slouken@5201
   148
    192, 200, 0, 0, 0, 242, 65, 63, 128, 168, 0, 0, 0, 242, 65, 63, 64, 72, 0, 0, 0, 242, 65, 63,
slouken@5201
   149
    1, 0, 6, 40, 0, 0, 0, 0, 1, 0, 1, 41, 5, 0, 2, 0
slouken@5201
   150
};
slouken@5201
   151
slouken@5201
   152
static const Uint8 GLES2_FragmentTegra_Alpha_SolidSrc_[] = {
slouken@5201
   153
    169, 153, 195, 28, 47, 109, 131, 38, 6, 0, 1, 0, 5, 0, 0, 0, 17, 0, 0, 0, 1, 0, 0, 0, 73, 0,
slouken@5201
   154
    0, 0, 8, 0, 0, 0, 8, 0, 0, 0, 2, 0, 0, 0, 75, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 75,
slouken@5201
   155
    0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0, 0, 75, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 0, 0,
slouken@5201
   156
    75, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 75, 0, 0, 0, 1, 0, 0, 0, 28, 0, 0, 0, 13, 0,
slouken@5201
   157
    0, 0, 82, 0, 0, 0, 2, 0, 0, 0, 8, 0, 0, 0, 14, 0, 0, 0, 84, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
slouken@5201
   158
    22, 0, 0, 0, 84, 0, 0, 0, 8, 0, 0, 0, 32, 0, 0, 0, 23, 0, 0, 0, 92, 0, 0, 0, 1, 0, 0, 0, 4,
slouken@5201
   159
    0, 0, 0, 15, 0, 0, 0, 93, 0, 0, 0, 1, 0, 0, 0, 80, 0, 0, 0, 17, 0, 0, 0, 113, 0, 0, 0, 0, 0,
slouken@5201
   160
    0, 0, 0, 0, 0, 0, 18, 0, 0, 0, 113, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 19, 0, 0, 0, 113, 0, 0,
slouken@5201
   161
    0, 220, 0, 0, 0, 220, 0, 0, 0, 20, 0, 0, 0, 113, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 21, 0, 0,
slouken@5201
   162
    0, 113, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 109, 97, 110, 70, 73, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
slouken@5201
   163
    0, 117, 95, 99, 111, 108, 111, 114, 0, 0, 0, 0, 0, 82, 139, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 0,
slouken@5201
   164
    0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5, 48, 0, 0, 0, 0, 0, 0, 118, 118, 17, 241, 0, 0, 0, 240, 0,
slouken@5201
   165
    0, 0, 240, 0, 0, 0, 240, 0, 0, 0, 240, 0, 0, 0, 240, 0, 0, 0, 240, 0, 0, 0, 240, 0, 0, 0, 0,
slouken@5201
   166
    0, 0, 0, 0, 1, 0, 0, 0, 7, 0, 0, 0, 2, 0, 0, 0, 1, 0, 0, 0, 3, 0, 0, 0, 21, 32, 0, 0, 0, 0,
slouken@5201
   167
    0, 0, 0, 0, 0, 0, 20, 0, 0, 0, 16, 0, 0, 0, 16, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0,
slouken@5201
   168
    0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 65, 82, 50, 48, 45, 66, 73, 78,
slouken@5201
   169
    1, 0, 0, 0, 3, 0, 0, 0, 3, 0, 65, 37, 8, 0, 129, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 21, 0,
slouken@5201
   170
    0, 0, 0, 3, 0, 1, 38, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3, 0, 1, 39, 0, 0, 0, 0, 0, 0, 0,
slouken@5201
   171
    0, 0, 0, 0, 0, 3, 0, 1, 40, 1, 0, 0, 0, 5, 0, 0, 0, 9, 0, 0, 0, 24, 0, 4, 40, 232, 231, 15,
slouken@5201
   172
    0, 0, 242, 65, 62, 194, 72, 1, 0, 0, 250, 65, 63, 194, 40, 1, 0, 0, 250, 65, 63, 192, 168, 1,
slouken@5201
   173
    0, 0, 242, 1, 64, 192, 168, 1, 0, 0, 242, 1, 68, 168, 32, 0, 0, 0, 50, 64, 0, 192, 168, 15,
slouken@5201
   174
    0, 0, 242, 1, 66, 168, 64, 0, 16, 0, 242, 65, 1, 232, 231, 15, 0, 0, 242, 65, 62, 168, 160,
slouken@5201
   175
    0, 0, 0, 50, 64, 2, 104, 192, 0, 0, 36, 48, 66, 4, 232, 231, 15, 0, 0, 242, 65, 62, 3, 0, 6,
slouken@5201
   176
    40, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3, 0, 1, 41, 0, 0, 0, 0, 0, 0, 0, 0, 5, 0, 2, 0
slouken@5201
   177
};
slouken@5201
   178
slouken@5201
   179
static const Uint8 GLES2_FragmentTegra_Additive_SolidSrc_[] = {
slouken@5201
   180
    59, 71, 42, 17, 47, 109, 131, 38, 6, 0, 1, 0, 5, 0, 0, 0, 17, 0, 0, 0, 1, 0, 0, 0, 73, 0, 0,
slouken@5201
   181
    0, 8, 0, 0, 0, 8, 0, 0, 0, 2, 0, 0, 0, 75, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 75,
slouken@5201
   182
    0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0, 0, 75, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 0, 0,
slouken@5201
   183
    75, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 75, 0, 0, 0, 1, 0, 0, 0, 28, 0, 0, 0, 13, 0,
slouken@5201
   184
    0, 0, 82, 0, 0, 0, 2, 0, 0, 0, 8, 0, 0, 0, 14, 0, 0, 0, 84, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
slouken@5201
   185
    22, 0, 0, 0, 84, 0, 0, 0, 8, 0, 0, 0, 32, 0, 0, 0, 23, 0, 0, 0, 92, 0, 0, 0, 1, 0, 0, 0, 4,
slouken@5201
   186
    0, 0, 0, 15, 0, 0, 0, 93, 0, 0, 0, 1, 0, 0, 0, 80, 0, 0, 0, 17, 0, 0, 0, 113, 0, 0, 0, 0, 0,
slouken@5201
   187
    0, 0, 0, 0, 0, 0, 18, 0, 0, 0, 113, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 19, 0, 0, 0, 113, 0, 0,
slouken@5201
   188
    0, 108, 0, 0, 0, 108, 0, 0, 0, 20, 0, 0, 0, 113, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 21, 0, 0,
slouken@5201
   189
    0, 113, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 109, 97, 110, 70, 73, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
slouken@5201
   190
    0, 117, 95, 99, 111, 108, 111, 114, 0, 0, 0, 0, 0, 82, 139, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 0,
slouken@5201
   191
    0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5, 48, 0, 0, 0, 0, 0, 0, 22, 22, 17, 241, 0, 0, 0, 240, 0,
slouken@5201
   192
    0, 0, 240, 0, 0, 0, 240, 0, 0, 0, 240, 0, 0, 0, 240, 0, 0, 0, 240, 0, 0, 0, 240, 0, 0, 0, 0,
slouken@5201
   193
    0, 0, 0, 0, 1, 0, 0, 0, 7, 0, 0, 0, 2, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 21, 32, 0, 0, 0, 0,
slouken@5201
   194
    0, 0, 0, 0, 0, 0, 20, 0, 0, 0, 16, 0, 0, 0, 16, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0,
slouken@5201
   195
    0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 65, 82, 50, 48, 45, 66, 73, 78,
slouken@5201
   196
    1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 65, 37, 8, 0, 129, 0, 1, 0, 0, 21, 0, 0, 0, 0, 1, 0, 1, 38, 0,
slouken@5201
   197
    0, 0, 0, 1, 0, 1, 39, 0, 0, 0, 0, 1, 0, 1, 40, 1, 0, 0, 0, 8, 0, 4, 40, 192, 200, 0, 0, 0, 26,
slouken@5201
   198
    0, 70, 192, 40, 0, 0, 0, 2, 0, 64, 192, 72, 0, 0, 0, 10, 0, 66, 192, 168, 0, 0, 0, 18, 0, 68,
slouken@5201
   199
    1, 0, 6, 40, 0, 0, 0, 0, 1, 0, 1, 41, 5, 0, 2, 0
slouken@5201
   200
};
slouken@5201
   201
slouken@5201
   202
static const Uint8 GLES2_FragmentTegra_Modulated_SolidSrc_[] = {
slouken@5201
   203
    37, 191, 49, 17, 47, 109, 131, 38, 6, 0, 1, 0, 5, 0, 0, 0, 17, 0, 0, 0, 1, 0, 0, 0, 73, 0, 0,
slouken@5201
   204
    0, 8, 0, 0, 0, 8, 0, 0, 0, 2, 0, 0, 0, 75, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 75,
slouken@5201
   205
    0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0, 0, 75, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 0, 0,
slouken@5201
   206
    75, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 75, 0, 0, 0, 1, 0, 0, 0, 28, 0, 0, 0, 13, 0,
slouken@5201
   207
    0, 0, 82, 0, 0, 0, 2, 0, 0, 0, 8, 0, 0, 0, 14, 0, 0, 0, 84, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
slouken@5201
   208
    22, 0, 0, 0, 84, 0, 0, 0, 8, 0, 0, 0, 32, 0, 0, 0, 23, 0, 0, 0, 92, 0, 0, 0, 1, 0, 0, 0, 4,
slouken@5201
   209
    0, 0, 0, 15, 0, 0, 0, 93, 0, 0, 0, 1, 0, 0, 0, 80, 0, 0, 0, 17, 0, 0, 0, 113, 0, 0, 0, 0, 0,
slouken@5201
   210
    0, 0, 0, 0, 0, 0, 18, 0, 0, 0, 113, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 19, 0, 0, 0, 113, 0, 0,
slouken@5201
   211
    0, 108, 0, 0, 0, 108, 0, 0, 0, 20, 0, 0, 0, 113, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 21, 0, 0,
slouken@5201
   212
    0, 113, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 109, 97, 110, 70, 73, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
slouken@5201
   213
    0, 117, 95, 99, 111, 108, 111, 114, 0, 0, 0, 0, 0, 82, 139, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 0,
slouken@5201
   214
    0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5, 48, 0, 0, 0, 0, 0, 0, 32, 32, 17, 241, 0, 0, 0, 240, 0,
slouken@5201
   215
    0, 0, 240, 0, 0, 0, 240, 0, 0, 0, 240, 0, 0, 0, 240, 0, 0, 0, 240, 0, 0, 0, 240, 0, 0, 0, 0,
slouken@5201
   216
    0, 0, 0, 0, 1, 0, 0, 0, 7, 0, 0, 0, 2, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 21, 32, 0, 0, 0, 0,
slouken@5201
   217
    0, 0, 0, 0, 0, 0, 20, 0, 0, 0, 16, 0, 0, 0, 16, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0,
slouken@5201
   218
    0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 65, 82, 50, 48, 45, 66, 73, 78,
slouken@5201
   219
    1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 65, 37, 8, 0, 129, 0, 1, 0, 0, 21, 0, 0, 0, 0, 1, 0, 1, 38, 0,
slouken@5201
   220
    0, 0, 0, 1, 0, 1, 39, 0, 0, 0, 0, 1, 0, 1, 40, 1, 0, 0, 0, 8, 0, 4, 40, 104, 192, 0, 0, 0, 242,
slouken@5201
   221
    1, 70, 8, 32, 0, 0, 0, 242, 1, 64, 40, 64, 0, 0, 0, 242, 1, 66, 72, 160, 0, 0, 0, 242, 1, 68,
slouken@5201
   222
    1, 0, 6, 40, 0, 0, 0, 0, 1, 0, 1, 41, 5, 0, 2, 0
slouken@5201
   223
};
slouken@5201
   224
slouken@5201
   225
static const Uint8 GLES2_FragmentTegra_None_TextureSrc_[] = {
slouken@5201
   226
    220, 217, 41, 211, 47, 109, 131, 38, 6, 0, 1, 0, 5, 0, 0, 0, 17, 0, 0, 0, 1, 0, 0, 0, 73, 0,
slouken@5201
   227
    0, 0, 34, 0, 0, 0, 36, 0, 0, 0, 2, 0, 0, 0, 82, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0,
slouken@5201
   228
    82, 0, 0, 0, 1, 0, 0, 0, 20, 0, 0, 0, 6, 0, 0, 0, 87, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0,
slouken@5201
   229
    0, 0, 87, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 87, 0, 0, 0, 2, 0, 0, 0, 56, 0, 0, 0,
slouken@5201
   230
    13, 0, 0, 0, 101, 0, 0, 0, 4, 0, 0, 0, 16, 0, 0, 0, 14, 0, 0, 0, 105, 0, 0, 0, 1, 0, 0, 0, 4,
slouken@5201
   231
    0, 0, 0, 22, 0, 0, 0, 106, 0, 0, 0, 8, 0, 0, 0, 32, 0, 0, 0, 23, 0, 0, 0, 114, 0, 0, 0, 1, 0,
slouken@5201
   232
    0, 0, 4, 0, 0, 0, 15, 0, 0, 0, 115, 0, 0, 0, 1, 0, 0, 0, 80, 0, 0, 0, 17, 0, 0, 0, 135, 0, 0,
slouken@5201
   233
    0, 0, 0, 0, 0, 0, 0, 0, 0, 18, 0, 0, 0, 135, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 19, 0, 0, 0, 135,
slouken@5201
   234
    0, 0, 0, 120, 0, 0, 0, 120, 0, 0, 0, 20, 0, 0, 0, 135, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 21,
slouken@5201
   235
    0, 0, 0, 135, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 109, 97, 110, 70, 73, 0, 0, 0, 0, 0, 0, 0, 0,
slouken@5201
   236
    0, 0, 0, 118, 95, 116, 101, 120, 67, 111, 111, 114, 100, 0, 117, 95, 109, 111, 100, 117, 108,
slouken@5201
   237
    97, 116, 105, 111, 110, 0, 117, 95, 116, 101, 120, 116, 117, 114, 101, 0, 0, 0, 0, 0, 0, 0,
slouken@5201
   238
    2, 0, 0, 0, 0, 0, 0, 0, 220, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 82, 139, 0, 0, 1, 0, 0, 0, 1,
slouken@5201
   239
    0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 24, 0, 0, 0, 94, 139, 0, 0, 1, 0, 0, 0, 1, 0, 0,
slouken@5201
   240
    0, 2, 0, 0, 0, 16, 0, 0, 0, 0, 0, 0, 0, 5, 48, 0, 0, 0, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0,
slouken@5201
   241
    0, 0, 1, 0, 0, 0, 241, 0, 0, 0, 240, 0, 0, 0, 240, 0, 0, 0, 240, 0, 0, 0, 240, 0, 0, 0, 240,
slouken@5201
   242
    0, 0, 0, 240, 0, 0, 0, 240, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 1, 0,
slouken@5201
   243
    0, 0, 1, 0, 0, 0, 21, 32, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 24, 0, 0, 0, 16, 0, 0, 0, 16, 0, 0,
slouken@5201
   244
    0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
slouken@5201
   245
    0, 0, 65, 82, 50, 48, 45, 66, 73, 78, 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 65, 37, 0, 0, 0, 0, 1, 0,
slouken@5201
   246
    0, 21, 0, 0, 0, 0, 1, 0, 1, 38, 1, 0, 0, 0, 2, 0, 4, 38, 186, 81, 78, 16, 2, 1, 0, 0, 1, 0,
slouken@5201
   247
    1, 39, 0, 4, 0, 0, 1, 0, 1, 40, 1, 0, 0, 0, 8, 0, 4, 40, 104, 192, 0, 0, 0, 242, 1, 70, 8, 32,
slouken@5201
   248
    0, 0, 0, 242, 1, 64, 40, 64, 0, 0, 0, 242, 1, 66, 72, 160, 0, 0, 0, 242, 1, 68, 1, 0, 6, 40,
slouken@5201
   249
    0, 0, 0, 0, 1, 0, 1, 41, 5, 0, 2, 0
slouken@5201
   250
};
slouken@5201
   251
slouken@5201
   252
static const Uint8 GLES2_FragmentTegra_Alpha_TextureSrc_[] = {
slouken@5201
   253
    71, 202, 114, 229, 47, 109, 131, 38, 6, 0, 1, 0, 5, 0, 0, 0, 17, 0, 0, 0, 1, 0, 0, 0, 73, 0,
slouken@5201
   254
    0, 0, 34, 0, 0, 0, 36, 0, 0, 0, 2, 0, 0, 0, 82, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0,
slouken@5201
   255
    82, 0, 0, 0, 1, 0, 0, 0, 20, 0, 0, 0, 6, 0, 0, 0, 87, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0,
slouken@5201
   256
    0, 0, 87, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 87, 0, 0, 0, 2, 0, 0, 0, 56, 0, 0, 0,
slouken@5201
   257
    13, 0, 0, 0, 101, 0, 0, 0, 4, 0, 0, 0, 16, 0, 0, 0, 14, 0, 0, 0, 105, 0, 0, 0, 1, 0, 0, 0, 4,
slouken@5201
   258
    0, 0, 0, 22, 0, 0, 0, 106, 0, 0, 0, 8, 0, 0, 0, 32, 0, 0, 0, 23, 0, 0, 0, 114, 0, 0, 0, 1, 0,
slouken@5201
   259
    0, 0, 4, 0, 0, 0, 15, 0, 0, 0, 115, 0, 0, 0, 1, 0, 0, 0, 80, 0, 0, 0, 17, 0, 0, 0, 135, 0, 0,
slouken@5201
   260
    0, 0, 0, 0, 0, 0, 0, 0, 0, 18, 0, 0, 0, 135, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 19, 0, 0, 0, 135,
slouken@5201
   261
    0, 0, 0, 176, 0, 0, 0, 176, 0, 0, 0, 20, 0, 0, 0, 135, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 21,
slouken@5201
   262
    0, 0, 0, 135, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 109, 97, 110, 70, 73, 0, 0, 0, 0, 0, 0, 0, 0,
slouken@5201
   263
    0, 0, 0, 118, 95, 116, 101, 120, 67, 111, 111, 114, 100, 0, 117, 95, 109, 111, 100, 117, 108,
slouken@5201
   264
    97, 116, 105, 111, 110, 0, 117, 95, 116, 101, 120, 116, 117, 114, 101, 0, 0, 0, 0, 0, 0, 0,
slouken@5201
   265
    2, 0, 0, 0, 0, 0, 0, 0, 220, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 82, 139, 0, 0, 1, 0, 0, 0, 1,
slouken@5201
   266
    0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 24, 0, 0, 0, 94, 139, 0, 0, 1, 0, 0, 0, 1, 0, 0,
slouken@5201
   267
    0, 2, 0, 0, 0, 16, 0, 0, 0, 0, 0, 0, 0, 5, 48, 0, 0, 0, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0,
slouken@5201
   268
    0, 0, 1, 118, 118, 17, 241, 0, 0, 0, 240, 0, 0, 0, 240, 0, 0, 0, 240, 0, 0, 0, 240, 0, 0, 0,
slouken@5201
   269
    240, 0, 0, 0, 240, 0, 0, 0, 240, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 7, 0, 0, 0, 2, 0, 0, 0,
slouken@5201
   270
    1, 0, 0, 0, 2, 0, 0, 0, 21, 32, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 24, 0, 0, 0, 16, 0, 0, 0, 16,
slouken@5201
   271
    0, 0, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
slouken@5201
   272
    0, 0, 0, 0, 65, 82, 50, 48, 45, 66, 73, 78, 1, 0, 0, 0, 2, 0, 0, 0, 2, 0, 65, 37, 0, 0, 0, 0,
slouken@5201
   273
    8, 0, 129, 0, 1, 0, 0, 21, 0, 0, 0, 0, 2, 0, 1, 38, 1, 0, 0, 0, 0, 0, 0, 0, 2, 0, 4, 38, 186,
slouken@5201
   274
    81, 78, 16, 2, 1, 0, 0, 2, 0, 1, 39, 0, 4, 0, 0, 0, 0, 0, 0, 2, 0, 1, 40, 1, 0, 0, 0, 5, 0,
slouken@5201
   275
    0, 0, 16, 0, 4, 40, 40, 160, 1, 0, 0, 242, 1, 66, 8, 192, 1, 0, 0, 242, 1, 64, 104, 32, 1, 0,
slouken@5201
   276
    0, 242, 1, 70, 72, 64, 1, 0, 0, 242, 1, 68, 154, 192, 0, 0, 37, 34, 64, 3, 8, 32, 0, 0, 5, 58,
slouken@5201
   277
    208, 4, 40, 64, 0, 0, 5, 50, 208, 4, 72, 160, 0, 0, 37, 42, 208, 4, 2, 0, 6, 40, 0, 0, 0, 0,
slouken@5201
   278
    0, 0, 0, 0, 2, 0, 1, 41, 0, 0, 0, 0, 5, 0, 2, 0
slouken@5201
   279
};
slouken@5201
   280
slouken@5201
   281
static const Uint8 GLES2_FragmentTegra_Additive_TextureSrc_[] = {
slouken@5201
   282
    161, 234, 193, 234, 47, 109, 131, 38, 6, 0, 1, 0, 5, 0, 0, 0, 17, 0, 0, 0, 1, 0, 0, 0, 73, 0,
slouken@5201
   283
    0, 0, 34, 0, 0, 0, 36, 0, 0, 0, 2, 0, 0, 0, 82, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0,
slouken@5201
   284
    82, 0, 0, 0, 1, 0, 0, 0, 20, 0, 0, 0, 6, 0, 0, 0, 87, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0,
slouken@5201
   285
    0, 0, 87, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 87, 0, 0, 0, 2, 0, 0, 0, 56, 0, 0, 0,
slouken@5201
   286
    13, 0, 0, 0, 101, 0, 0, 0, 4, 0, 0, 0, 16, 0, 0, 0, 14, 0, 0, 0, 105, 0, 0, 0, 1, 0, 0, 0, 4,
slouken@5201
   287
    0, 0, 0, 22, 0, 0, 0, 106, 0, 0, 0, 8, 0, 0, 0, 32, 0, 0, 0, 23, 0, 0, 0, 114, 0, 0, 0, 1, 0,
slouken@5201
   288
    0, 0, 4, 0, 0, 0, 15, 0, 0, 0, 115, 0, 0, 0, 1, 0, 0, 0, 80, 0, 0, 0, 17, 0, 0, 0, 135, 0, 0,
slouken@5201
   289
    0, 0, 0, 0, 0, 0, 0, 0, 0, 18, 0, 0, 0, 135, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 19, 0, 0, 0, 135,
slouken@5201
   290
    0, 0, 0, 176, 0, 0, 0, 176, 0, 0, 0, 20, 0, 0, 0, 135, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 21,
slouken@5201
   291
    0, 0, 0, 135, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 109, 97, 110, 70, 73, 0, 0, 0, 0, 0, 0, 0, 0,
slouken@5201
   292
    0, 0, 0, 118, 95, 116, 101, 120, 67, 111, 111, 114, 100, 0, 117, 95, 109, 111, 100, 117, 108,
slouken@5201
   293
    97, 116, 105, 111, 110, 0, 117, 95, 116, 101, 120, 116, 117, 114, 101, 0, 0, 0, 0, 0, 0, 0,
slouken@5201
   294
    2, 0, 0, 0, 0, 0, 0, 0, 220, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 82, 139, 0, 0, 1, 0, 0, 0, 1,
slouken@5201
   295
    0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 24, 0, 0, 0, 94, 139, 0, 0, 1, 0, 0, 0, 1, 0, 0,
slouken@5201
   296
    0, 2, 0, 0, 0, 16, 0, 0, 0, 0, 0, 0, 0, 5, 48, 0, 0, 0, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0,
slouken@5201
   297
    0, 0, 1, 22, 22, 17, 241, 0, 0, 0, 240, 0, 0, 0, 240, 0, 0, 0, 240, 0, 0, 0, 240, 0, 0, 0, 240,
slouken@5201
   298
    0, 0, 0, 240, 0, 0, 0, 240, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 7, 0, 0, 0, 2, 0, 0, 0, 1, 0,
slouken@5201
   299
    0, 0, 2, 0, 0, 0, 21, 32, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 24, 0, 0, 0, 16, 0, 0, 0, 16, 0, 0,
slouken@5201
   300
    0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
slouken@5201
   301
    0, 0, 65, 82, 50, 48, 45, 66, 73, 78, 1, 0, 0, 0, 2, 0, 0, 0, 2, 0, 65, 37, 0, 0, 0, 0, 8, 0,
slouken@5201
   302
    129, 0, 1, 0, 0, 21, 0, 0, 0, 0, 2, 0, 1, 38, 1, 0, 0, 0, 0, 0, 0, 0, 2, 0, 4, 38, 186, 81,
slouken@5201
   303
    78, 16, 2, 1, 0, 0, 2, 0, 1, 39, 0, 4, 0, 0, 0, 0, 0, 0, 2, 0, 1, 40, 1, 0, 0, 0, 5, 0, 0, 0,
slouken@5201
   304
    16, 0, 4, 40, 40, 160, 1, 0, 0, 242, 1, 66, 104, 32, 1, 0, 0, 242, 1, 70, 8, 192, 1, 0, 0, 242,
slouken@5201
   305
    1, 64, 72, 64, 1, 0, 0, 242, 1, 68, 136, 192, 0, 0, 0, 26, 64, 4, 136, 32, 0, 0, 0, 2, 64, 7,
slouken@5201
   306
    136, 64, 0, 0, 0, 10, 64, 6, 136, 160, 0, 0, 0, 18, 64, 5, 2, 0, 6, 40, 0, 0, 0, 0, 0, 0, 0,
slouken@5201
   307
    0, 2, 0, 1, 41, 0, 0, 0, 0, 5, 0, 2, 0
slouken@5201
   308
};
slouken@5201
   309
slouken@5201
   310
static const Uint8 GLES2_FragmentTegra_Modulated_TextureSrc_[] = {
slouken@5201
   311
    75, 132, 201, 227, 47, 109, 131, 38, 6, 0, 1, 0, 5, 0, 0, 0, 17, 0, 0, 0, 1, 0, 0, 0, 73, 0,
slouken@5201
   312
    0, 0, 34, 0, 0, 0, 36, 0, 0, 0, 2, 0, 0, 0, 82, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0,
slouken@5201
   313
    82, 0, 0, 0, 1, 0, 0, 0, 20, 0, 0, 0, 6, 0, 0, 0, 87, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0,
slouken@5201
   314
    0, 0, 87, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 87, 0, 0, 0, 2, 0, 0, 0, 56, 0, 0, 0,
slouken@5201
   315
    13, 0, 0, 0, 101, 0, 0, 0, 4, 0, 0, 0, 16, 0, 0, 0, 14, 0, 0, 0, 105, 0, 0, 0, 1, 0, 0, 0, 4,
slouken@5201
   316
    0, 0, 0, 22, 0, 0, 0, 106, 0, 0, 0, 8, 0, 0, 0, 32, 0, 0, 0, 23, 0, 0, 0, 114, 0, 0, 0, 1, 0,
slouken@5201
   317
    0, 0, 4, 0, 0, 0, 15, 0, 0, 0, 115, 0, 0, 0, 1, 0, 0, 0, 80, 0, 0, 0, 17, 0, 0, 0, 135, 0, 0,
slouken@5201
   318
    0, 0, 0, 0, 0, 0, 0, 0, 0, 18, 0, 0, 0, 135, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 19, 0, 0, 0, 135,
slouken@5201
   319
    0, 0, 0, 176, 0, 0, 0, 176, 0, 0, 0, 20, 0, 0, 0, 135, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 21,
slouken@5201
   320
    0, 0, 0, 135, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 109, 97, 110, 70, 73, 0, 0, 0, 0, 0, 0, 0, 0,
slouken@5201
   321
    0, 0, 0, 118, 95, 116, 101, 120, 67, 111, 111, 114, 100, 0, 117, 95, 109, 111, 100, 117, 108,
slouken@5201
   322
    97, 116, 105, 111, 110, 0, 117, 95, 116, 101, 120, 116, 117, 114, 101, 0, 0, 0, 0, 0, 0, 0,
slouken@5201
   323
    2, 0, 0, 0, 0, 0, 0, 0, 220, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 82, 139, 0, 0, 1, 0, 0, 0, 1,
slouken@5201
   324
    0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 24, 0, 0, 0, 94, 139, 0, 0, 1, 0, 0, 0, 1, 0, 0,
slouken@5201
   325
    0, 2, 0, 0, 0, 16, 0, 0, 0, 0, 0, 0, 0, 5, 48, 0, 0, 0, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0,
slouken@5201
   326
    0, 0, 1, 32, 32, 17, 241, 0, 0, 0, 240, 0, 0, 0, 240, 0, 0, 0, 240, 0, 0, 0, 240, 0, 0, 0, 240,
slouken@5201
   327
    0, 0, 0, 240, 0, 0, 0, 240, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 7, 0, 0, 0, 2, 0, 0, 0, 1, 0,
slouken@5201
   328
    0, 0, 2, 0, 0, 0, 21, 32, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 24, 0, 0, 0, 16, 0, 0, 0, 16, 0, 0,
slouken@5201
   329
    0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
slouken@5201
   330
    0, 0, 65, 82, 50, 48, 45, 66, 73, 78, 1, 0, 0, 0, 2, 0, 0, 0, 2, 0, 65, 37, 0, 0, 0, 0, 8, 0,
slouken@5201
   331
    129, 0, 1, 0, 0, 21, 0, 0, 0, 0, 2, 0, 1, 38, 1, 0, 0, 0, 0, 0, 0, 0, 2, 0, 4, 38, 186, 81,
slouken@5201
   332
    78, 16, 2, 1, 0, 0, 2, 0, 1, 39, 0, 4, 0, 0, 0, 0, 0, 0, 2, 0, 1, 40, 1, 0, 0, 0, 5, 0, 0, 0,
slouken@5201
   333
    16, 0, 4, 40, 40, 160, 1, 0, 0, 242, 1, 66, 8, 192, 1, 0, 0, 242, 1, 64, 104, 32, 1, 0, 0, 242,
slouken@5201
   334
    1, 70, 72, 64, 1, 0, 0, 242, 1, 68, 104, 192, 0, 0, 0, 242, 65, 4, 232, 32, 0, 0, 0, 242, 65,
slouken@5201
   335
    0, 40, 64, 0, 0, 0, 242, 65, 6, 72, 160, 0, 0, 0, 242, 65, 5, 2, 0, 6, 40, 0, 0, 0, 0, 0, 0,
slouken@5201
   336
    0, 0, 2, 0, 1, 41, 0, 0, 0, 0, 5, 0, 2, 0
slouken@5201
   337
};
slouken@5201
   338
slouken@5201
   339
static const GLES2_ShaderInstance GLES2_VertexTegra_Default = {
slouken@5201
   340
    GL_VERTEX_SHADER,
slouken@5201
   341
    GL_NVIDIA_PLATFORM_BINARY_NV,
slouken@5201
   342
    sizeof(GLES2_VertexTegra_Default_),
slouken@5201
   343
    GLES2_VertexTegra_Default_
slouken@5201
   344
};
slouken@5201
   345
slouken@5201
   346
static const GLES2_ShaderInstance GLES2_FragmentTegra_None_SolidSrc = {
slouken@5201
   347
    GL_FRAGMENT_SHADER,
slouken@5201
   348
    GL_NVIDIA_PLATFORM_BINARY_NV,
slouken@5201
   349
    sizeof(GLES2_FragmentTegra_None_SolidSrc_),
slouken@5201
   350
    GLES2_FragmentTegra_None_SolidSrc_
slouken@5201
   351
};
slouken@5201
   352
slouken@5201
   353
static const GLES2_ShaderInstance GLES2_FragmentTegra_Alpha_SolidSrc = {
slouken@5201
   354
    GL_FRAGMENT_SHADER,
slouken@5201
   355
    GL_NVIDIA_PLATFORM_BINARY_NV,
slouken@5201
   356
    sizeof(GLES2_FragmentTegra_Alpha_SolidSrc_),
slouken@5201
   357
    GLES2_FragmentTegra_Alpha_SolidSrc_
slouken@5201
   358
};
slouken@5201
   359
slouken@5201
   360
static const GLES2_ShaderInstance GLES2_FragmentTegra_Additive_SolidSrc = {
slouken@5201
   361
    GL_FRAGMENT_SHADER,
slouken@5201
   362
    GL_NVIDIA_PLATFORM_BINARY_NV,
slouken@5201
   363
    sizeof(GLES2_FragmentTegra_Additive_SolidSrc_),
slouken@5201
   364
    GLES2_FragmentTegra_Additive_SolidSrc_
slouken@5201
   365
};
slouken@5201
   366
slouken@5201
   367
static const GLES2_ShaderInstance GLES2_FragmentTegra_Modulated_SolidSrc = {
slouken@5201
   368
    GL_FRAGMENT_SHADER,
slouken@5201
   369
    GL_NVIDIA_PLATFORM_BINARY_NV,
slouken@5201
   370
    sizeof(GLES2_FragmentTegra_Modulated_SolidSrc_),
slouken@5201
   371
    GLES2_FragmentTegra_Modulated_SolidSrc_
slouken@5201
   372
};
slouken@5201
   373
slouken@5201
   374
static const GLES2_ShaderInstance GLES2_FragmentTegra_None_TextureSrc = {
slouken@5201
   375
    GL_FRAGMENT_SHADER,
slouken@5201
   376
    GL_NVIDIA_PLATFORM_BINARY_NV,
slouken@5201
   377
    sizeof(GLES2_FragmentTegra_None_TextureSrc_),
slouken@5201
   378
    GLES2_FragmentTegra_None_TextureSrc_
slouken@5201
   379
};
slouken@5201
   380
slouken@5201
   381
static const GLES2_ShaderInstance GLES2_FragmentTegra_Alpha_TextureSrc = {
slouken@5201
   382
    GL_FRAGMENT_SHADER,
slouken@5201
   383
    GL_NVIDIA_PLATFORM_BINARY_NV,
slouken@5201
   384
    sizeof(GLES2_FragmentTegra_Alpha_TextureSrc_),
slouken@5201
   385
    GLES2_FragmentTegra_Alpha_TextureSrc_
slouken@5201
   386
};
slouken@5201
   387
slouken@5201
   388
static const GLES2_ShaderInstance GLES2_FragmentTegra_Additive_TextureSrc = {
slouken@5201
   389
    GL_FRAGMENT_SHADER,
slouken@5201
   390
    GL_NVIDIA_PLATFORM_BINARY_NV,
slouken@5201
   391
    sizeof(GLES2_FragmentTegra_Additive_TextureSrc_),
slouken@5201
   392
    GLES2_FragmentTegra_Additive_TextureSrc_
slouken@5201
   393
};
slouken@5201
   394
slouken@5201
   395
static const GLES2_ShaderInstance GLES2_FragmentTegra_Modulated_TextureSrc = {
slouken@5201
   396
    GL_FRAGMENT_SHADER,
slouken@5201
   397
    GL_NVIDIA_PLATFORM_BINARY_NV,
slouken@5201
   398
    sizeof(GLES2_FragmentTegra_Modulated_TextureSrc_),
slouken@5201
   399
    GLES2_FragmentTegra_Modulated_TextureSrc_
slouken@5201
   400
};
slouken@5201
   401
slouken@5201
   402
#endif /* GLES2_INCLUDE_NVIDIA_SHADERS */
slouken@5201
   403
slouken@5201
   404
/*************************************************************************************************
slouken@5201
   405
 * Vertex/fragment shader definitions                                                            *
slouken@5201
   406
 *************************************************************************************************/
slouken@5201
   407
slouken@5201
   408
static GLES2_Shader GLES2_VertexShader_Default = {
slouken@5201
   409
    2,
slouken@5201
   410
    {
slouken@5201
   411
#if GLES2_INCLUDE_NVIDIA_SHADERS
slouken@5201
   412
        &GLES2_VertexTegra_Default,
slouken@5201
   413
#endif
slouken@5201
   414
        &GLES2_VertexSrc_Default
slouken@5201
   415
    }
slouken@5201
   416
};
slouken@5201
   417
slouken@5201
   418
static GLES2_Shader GLES2_FragmentShader_None_SolidSrc = {
slouken@5201
   419
    2,
slouken@5201
   420
    {
slouken@5201
   421
#if GLES2_INCLUDE_NVIDIA_SHADERS
slouken@5201
   422
        &GLES2_FragmentTegra_None_SolidSrc,
slouken@5201
   423
#endif
slouken@5201
   424
        &GLES2_FragmentSrc_SolidSrc
slouken@5201
   425
    }
slouken@5201
   426
};
slouken@5201
   427
slouken@5201
   428
static GLES2_Shader GLES2_FragmentShader_Alpha_SolidSrc = {
slouken@5201
   429
    2,
slouken@5201
   430
    {
slouken@5201
   431
#if GLES2_INCLUDE_NVIDIA_SHADERS
slouken@5201
   432
        &GLES2_FragmentTegra_Alpha_SolidSrc,
slouken@5201
   433
#endif
slouken@5201
   434
        &GLES2_FragmentSrc_SolidSrc
slouken@5201
   435
    }
slouken@5201
   436
};
slouken@5201
   437
slouken@5201
   438
static GLES2_Shader GLES2_FragmentShader_Additive_SolidSrc = {
slouken@5201
   439
    2,
slouken@5201
   440
    {
slouken@5201
   441
#if GLES2_INCLUDE_NVIDIA_SHADERS
slouken@5201
   442
        &GLES2_FragmentTegra_Additive_SolidSrc,
slouken@5201
   443
#endif
slouken@5201
   444
        &GLES2_FragmentSrc_SolidSrc
slouken@5201
   445
    }
slouken@5201
   446
};
slouken@5201
   447
slouken@5201
   448
static GLES2_Shader GLES2_FragmentShader_Modulated_SolidSrc = {
slouken@5201
   449
    2,
slouken@5201
   450
    {
slouken@5201
   451
#if GLES2_INCLUDE_NVIDIA_SHADERS
slouken@5201
   452
        &GLES2_FragmentTegra_Modulated_SolidSrc,
slouken@5201
   453
#endif
slouken@5201
   454
        &GLES2_FragmentSrc_SolidSrc
slouken@5201
   455
    }
slouken@5201
   456
};
slouken@5201
   457
slouken@5201
   458
static GLES2_Shader GLES2_FragmentShader_None_TextureSrc = {
slouken@5201
   459
    2,
slouken@5201
   460
    {
slouken@5201
   461
#if GLES2_INCLUDE_NVIDIA_SHADERS
slouken@5201
   462
        &GLES2_FragmentTegra_None_TextureSrc,
slouken@5201
   463
#endif
slouken@5201
   464
        &GLES2_FragmentSrc_TextureSrc
slouken@5201
   465
    }
slouken@5201
   466
};
slouken@5201
   467
slouken@5201
   468
static GLES2_Shader GLES2_FragmentShader_Alpha_TextureSrc = {
slouken@5201
   469
    2,
slouken@5201
   470
    {
slouken@5201
   471
#if GLES2_INCLUDE_NVIDIA_SHADERS
slouken@5201
   472
        &GLES2_FragmentTegra_Alpha_TextureSrc,
slouken@5201
   473
#endif
slouken@5201
   474
        &GLES2_FragmentSrc_TextureSrc
slouken@5201
   475
    }
slouken@5201
   476
};
slouken@5201
   477
slouken@5201
   478
static GLES2_Shader GLES2_FragmentShader_Additive_TextureSrc = {
slouken@5201
   479
    2,
slouken@5201
   480
    {
slouken@5201
   481
#if GLES2_INCLUDE_NVIDIA_SHADERS
slouken@5201
   482
        &GLES2_FragmentTegra_Additive_TextureSrc,
slouken@5201
   483
#endif
slouken@5201
   484
        &GLES2_FragmentSrc_TextureSrc
slouken@5201
   485
    }
slouken@5201
   486
};
slouken@5201
   487
slouken@5201
   488
static GLES2_Shader GLES2_FragmentShader_Modulated_TextureSrc = {
slouken@5201
   489
    2,
slouken@5201
   490
    {
slouken@5201
   491
#if GLES2_INCLUDE_NVIDIA_SHADERS
slouken@5201
   492
        &GLES2_FragmentTegra_Modulated_TextureSrc,
slouken@5201
   493
#endif
slouken@5201
   494
        &GLES2_FragmentSrc_TextureSrc
slouken@5201
   495
    }
slouken@5201
   496
};
slouken@5201
   497
slouken@5201
   498
/*************************************************************************************************
slouken@5201
   499
 * Shader selector                                                                               *
slouken@5201
   500
 *************************************************************************************************/
slouken@5201
   501
slouken@5201
   502
const GLES2_Shader *GLES2_GetShader(GLES2_ShaderType type, SDL_BlendMode blendMode)
slouken@5201
   503
{
slouken@5201
   504
    switch (type)
slouken@5201
   505
    {
slouken@5201
   506
    case GLES2_SHADER_VERTEX_DEFAULT:
slouken@5201
   507
        return &GLES2_VertexShader_Default;
slouken@5201
   508
    case GLES2_SHADER_FRAGMENT_SOLID_SRC:
slouken@5201
   509
        switch (blendMode)
slouken@5201
   510
        {
slouken@5201
   511
        case SDL_BLENDMODE_NONE:
slouken@5201
   512
            return &GLES2_FragmentShader_None_SolidSrc;
slouken@5201
   513
        case SDL_BLENDMODE_BLEND:
slouken@5201
   514
            return &GLES2_FragmentShader_Alpha_SolidSrc;
slouken@5201
   515
        case SDL_BLENDMODE_ADD:
slouken@5201
   516
            return &GLES2_FragmentShader_Additive_SolidSrc;
slouken@5201
   517
        case SDL_BLENDMODE_MOD:
slouken@5201
   518
            return &GLES2_FragmentShader_Modulated_SolidSrc;
slouken@5201
   519
        default:
slouken@5201
   520
            return NULL;
slouken@5201
   521
        }
slouken@5201
   522
    case GLES2_SHADER_FRAGMENT_TEXTURE_SRC:
slouken@5201
   523
        switch (blendMode)
slouken@5201
   524
        {
slouken@5201
   525
        case SDL_BLENDMODE_NONE:
slouken@5201
   526
            return &GLES2_FragmentShader_None_TextureSrc;
slouken@5201
   527
        case SDL_BLENDMODE_BLEND:
slouken@5201
   528
            return &GLES2_FragmentShader_Alpha_TextureSrc;
slouken@5201
   529
        case SDL_BLENDMODE_ADD:
slouken@5201
   530
            return &GLES2_FragmentShader_Additive_TextureSrc;
slouken@5201
   531
        case SDL_BLENDMODE_MOD:
slouken@5201
   532
            return &GLES2_FragmentShader_Modulated_TextureSrc;
slouken@5201
   533
        default:
slouken@5201
   534
            return NULL;
slouken@5201
   535
        }
slouken@5201
   536
    default:
slouken@5201
   537
        return NULL;
slouken@5201
   538
    }
slouken@5201
   539
}
slouken@5201
   540
slouken@5226
   541
#endif /* SDL_VIDEO_RENDER_OGL_ES2 && !SDL_RENDER_DISABLED */
slouken@5201
   542
slouken@5201
   543
/* vi: set ts=4 sw=4 expandtab: */