OLD | NEW |
1 /* | 1 /* |
2 * Copyright 2010, Google Inc. | 2 * Copyright 2010, Google Inc. |
3 * All rights reserved. | 3 * All rights reserved. |
4 * | 4 * |
5 * Redistribution and use in source and binary forms, with or without | 5 * Redistribution and use in source and binary forms, with or without |
6 * modification, are permitted provided that the following conditions are | 6 * modification, are permitted provided that the following conditions are |
7 * met: | 7 * met: |
8 * | 8 * |
9 * * Redistributions of source code must retain the above copyright | 9 * * Redistributions of source code must retain the above copyright |
10 * notice, this list of conditions and the following disclaimer. | 10 * notice, this list of conditions and the following disclaimer. |
(...skipping 199 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
210 * [0,1] to [-.5,.5] as part of the transform. | 210 * [0,1] to [-.5,.5] as part of the transform. |
211 */ | 211 */ |
212 vec4 channels = vec4(yChannel, uChannel, vChannel, 1.0); | 212 vec4 channels = vec4(yChannel, uChannel, vChannel, 1.0); |
213 mat4 conversion = mat4( 1.0, 1.0, 1.0, 0.0, | 213 mat4 conversion = mat4( 1.0, 1.0, 1.0, 0.0, |
214 0.0, -0.344, 1.772, 0.0, | 214 0.0, -0.344, 1.772, 0.0, |
215 1.402, -0.714, 0.0, 0.0, | 215 1.402, -0.714, 0.0, 0.0, |
216 -0.701, 0.529, -0.886, 1.0); | 216 -0.701, 0.529, -0.886, 1.0); |
217 | 217 |
218 gl_FragColor = conversion * channels; | 218 gl_FragColor = conversion * channels; |
219 } | 219 } |
OLD | NEW |