123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116 |
- // This file was created by Filewrap 1.1
- // Little endian mode
- // DO NOT EDIT
- #include "../PVRTMemoryFileSystem.h"
- // using 32 bit to guarantee alignment.
- #ifndef A32BIT
- #define A32BIT static const unsigned int
- #endif
- // ******** Start: SHVertShader.vsh ********
- // File data
- static const char _SHVertShader_vsh[] =
- "attribute highp vec3 inVertex;\r\n"
- "attribute mediump vec3 inNormal;\r\n"
- "attribute mediump vec2 inTexCoord;\r\n"
- "\r\n"
- "uniform highp mat4 MVPMatrix;\r\n"
- "uniform highp mat3 Model;\r\n"
- "\r\n"
- "// Precalculated constants used for lighting\r\n"
- "uniform highp vec4 cAr;\r\n"
- "uniform highp vec4 cAg;\r\n"
- "uniform highp vec4 cAb;\r\n"
- "\r\n"
- "uniform highp\tvec4 cBr;\r\n"
- "uniform highp\tvec4 cBg;\r\n"
- "uniform highp\tvec4 cBb;\r\n"
- "\r\n"
- "uniform highp\tvec3 cC;\r\n"
- "\r\n"
- "// varyings\r\n"
- "varying lowp vec4 LightColour;\r\n"
- "varying mediump vec2 TexCoord;\r\n"
- "\r\n"
- "void main()\r\n"
- "{\r\n"
- "\thighp vec4 r0, r1;\r\n"
- "\thighp vec3 r2, r3;\r\n"
- "\t\r\n"
- "\t// Transform position\r\n"
- "\tgl_Position = MVPMatrix * vec4(inVertex, 1.0);\r\n"
- "\r\n"
- "\t// Transform the Normal and add a homogenous 1\r\n"
- "\tr0 = vec4(Model * inNormal, 1.0);\r\n"
- "\r\n"
- "\t// Compute 1st 4 basis functions - linear + constant\r\n"
- "\t// r0 is the normal with a homegenous 1\r\n"
- "\t// c* are precomputed constants\r\n"
- "\tr2.x = dot(cAr, r0);\r\n"
- "\tr2.y = dot(cAg, r0);\r\n"
- "\tr2.z = dot(cAb, r0);\r\n"
- "\t\r\n"
- "\t// Compute polynomials for the next 4 basis functions\r\n"
- "\tr1 = r0.yzzx * r0.xyzz; // r1 is { yx, zy, z^2, xz}\r\n"
- "\r\n"
- "\t// Add contributions and store them in r3\r\n"
- "\tr3.x = dot(cBr, r1);\r\n"
- "\tr3.y = dot(cBg, r1);\r\n"
- "\tr3.z = dot(cBb, r1);\r\n"
- "\r\n"
- "\t// Compute the final basis function x^2 - y^2\r\n"
- "\tr0.z = r0.y * r0.y;\r\n"
- "\tr0.w = (r0.x * r0.x) - r0.z;\r\n"
- "\t\r\n"
- "\t// Combine the first 2 sets : 8 basis functions\r\n"
- "\tr1.xyz = r2 + r3;\r\n"
- "\r\n"
- "\t// Add in the final 9th basis function to create the final RGB Lighting\r\n"
- "\tLightColour.xyz = (cC * r0.w) + r1.xyz;\r\n"
- "\t\r\n"
- "\t// Set light alpha to 1.0\r\n"
- "\tLightColour.a = 1.0;\r\n"
- "\r\n"
- "\t// Pass through texcoords\r\n"
- "\tTexCoord = inTexCoord;\r\n"
- "}";
- // Register SHVertShader.vsh in memory file system at application startup time
- static CPVRTMemoryFileSystem RegisterFile_SHVertShader_vsh("SHVertShader.vsh", _SHVertShader_vsh, 1553);
- // ******** End: SHVertShader.vsh ********
- // This file was created by Filewrap 1.1
- // Little endian mode
- // DO NOT EDIT
- #include "../PVRTMemoryFileSystem.h"
- // using 32 bit to guarantee alignment.
- #ifndef A32BIT
- #define A32BIT static const unsigned int
- #endif
- // ******** Start: SHVertShader.vsc ********
- // File data
- A32BIT _SHVertShader_vsc[] = {
- 0x10fab438,0xdfaa00f0,0x30050100,0x2501,0xd363e337,0x2000000,0x20000000,0xf9060000,0x0,0x4000000,0x0,0x19000000,0x204,0x0,0x2010000,0x0,0x0,0x66040000,0x55535020,0x20,0x45a,0x1,0x1,0x0,0x204,0x0,0x2,0x7d,0x0,0x8,0x0,0xffffffff,0x0,0x122000a,0xffff,0x3000a,0x0,0x0,0x35,0x0,0x0,0x0,0x0,0xfffc,0x0,0x0,0x0,0xffff0003,0xffffffff,0x350001,0x80000a,0x10001,0x0,0x20001,0x1,0x30001,0x2,0x40001,0x3,0x50001,0x4,0x60001,0x5,0x70001,
- 0x6,0x80001,0x7,0x90001,0x8,0xa0001,0x9,0xb0001,0xa,0xc0001,0xb,0xd0001,0xc,0xe0001,0xd,0xf0001,0xe,0x100001,0xf,0x110001,0x10,0x120001,0x11,0x130001,0x12,0x140001,0x13,0x150001,0x14,0x160001,0x15,0x180001,0x16,0x190001,0x17,0x1a0001,0x18,0x1c0001,0x19,0x1d0001,0x1a,0x1e0001,0x1b,0x200001,0x1c,0x210001,0x1d,0x220001,0x1e,0x230001,0x1f,0x240001,0x20,0x250001,0x21,0x260001,0x22,0x270001,0x23,0x280001,0x24,0x290001,0x25,0x2a0001,
- 0x26,0x2b0001,0x27,0x2c0001,0x28,0x2d0001,0x29,0x2e0001,0x2a,0x2f0001,0x2b,0x300001,0x2c,0x310001,0x2d,0x320001,0x2e,0x330001,0x2f,0x340001,0x30,0x350001,0x31,0x360001,0x32,0x370001,0x33,0x3b0003,0x340000,0x1f000000,0x1fbea7c4,0x3774081,0xffff0000,0xffffffff,0xffff,0x0,0x40000,0x30000,0x2,0x20002,0x80018000,0x80018003,0x0,0x0,0x4,0x10301,0xfa100000,0xe0400f84,0x10a02000,0x2,0x2001a,0x80018001,0x80018001,0x0,0x0,0x4,0x0,0x10001,0x1,0x10001,0x10001,0x10001,0x10001,0x10001,
- 0x10001,0x10001,0x10001,0x10001,0x1010101,0xfa100000,0xe0e01f00,0x28811001,0xa1000400,0x28a11001,0xf0600790,0x38ab0606,0xf0604994,0x38820606,0xf0608b98,0x38820606,0x705f1a1b,0xa21001,0xf0610e9e,0x38ab0606,0xf0615021,0x38820606,0xf0a191a4,0x38a20606,0x10014130,0x811004,0xe0c15700,0x3898c606,0xa0214306,0x801424,0xc0e19782,0x389e0606,0xd061dd30,0x811006,0xc1209802,0x389e0602,0x709f1a31,0x821002,0xe0625d83,0x801006,0xf100068e,0x38980606,0xe0021e03,0x801006,0xe0001e80,0x801002,0x60011a00,0x821006,0xe0c04600,0x801001,0xf0004892,0x38820606,0xf0008a96,0x38820606,0x701f1a19,0xa21001,0x2,0x20005,0x80018001,0x80048000,0x0,0x0,0x4,0x10001,
- 0x40001,0x101,0x532afa10,0x606f001,0x93ab38ab,0x606f001,0x942c3882,0x602f000,0x1a293882,0x1002703f,0x200a2,0x60000,0x80010002,0x80008001,0x8001,0x0,0x40000,0x10000,0x10001,0x10001,0x101,0xd936fa10,0x606f001,0x59b738ab,0x606f002,0x1a383882,0x606f002,0x1ab93882,0x602f000,0x5a003882,0x10067000,0x200a3,0x20000,0x80010002,0x80018000,0x8001,0x0,0x40000,0x1010000,0x100,0x4500fa10,0x1001e080,0x600a0,0x3c000000,0x803f,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,
- 0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x803f,0x6e690f00,0x74726556,0x7865,0x3040400,0x10000,0x100,0x70004,0x5f6c6700,0x69736f50,0x6e6f6974,0x5010000,0x305,0x1000001,0x40000,0x4d00000f,0x614d5056,0x78697274,0x16000000,0x303,0x1000001,0xff100400,0x690000ff,0x726f4e6e,0x6c616d,
- 0x4040000,0x1000002,0x10000,0x7000404,0x6f4d0000,0x6c6564,0x3120000,0x1000003,0x10000,0x77070c14,0x41630000,0x72,0x30305,0x100,0x4200001,0xf00,0x674163,0x3050000,0x1000003,0x10000,0xf000424,0x41630000,0x62,0x30305,0x100,0x4280001,0xf00,0x724263,0x3050000,0x1000003,0x10000,0xf00042c,0x42630000,0x67,0x30305,0x100,0x4300001,0xf00,0x624263,0x3050000,0x1000003,0x10000,0xf000434,0x43630000,0x4000000,0x303,0x1000001,0x30100,0x4c000007,0x74686769,0x6f6c6f43,0x7275,0x1050500,0x10000,0x100,0xf0004,0x78655400,0x726f6f43,0x64,0x20503,0x100,0x2040001,0x300,0x65546e69,
- 0x6f6f4378,0x6472,0x2040300,0x10000,0x8000100,0x30004,0x0,
- };
- // Register SHVertShader.vsc in memory file system at application startup time
- static CPVRTMemoryFileSystem RegisterFile_SHVertShader_vsc("SHVertShader.vsc", _SHVertShader_vsc, 1817);
- // ******** End: SHVertShader.vsc ********
|