mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-12-24 17:20:36 +00:00
gleffects: fix gleffects fisheye shader compile error
On some embedded systems, sqrt() is not supported in the shader, use the actual value of sqrt(2) instead. Signed-off-by: Haihua Hu <b55597@freescale.com> Bugzilla: https://bugzilla.gnome.org/show_bug.cgi?id=761271
This commit is contained in:
parent
931090bf18
commit
3fb60ac10c
1 changed files with 1 additions and 1 deletions
|
@ -152,7 +152,7 @@ const gchar *fisheye_fragment_source_gles2 =
|
||||||
" vec2 normcoord;"
|
" vec2 normcoord;"
|
||||||
" normcoord = texturecoord - 0.5;"
|
" normcoord = texturecoord - 0.5;"
|
||||||
" float r = length (normcoord);"
|
" float r = length (normcoord);"
|
||||||
" normcoord *= r * sqrt(2);"
|
" normcoord *= r * 1.41421;" /* sqrt (2) */
|
||||||
" texturecoord = normcoord + 0.5;"
|
" texturecoord = normcoord + 0.5;"
|
||||||
" gl_FragColor = texture2D (tex, texturecoord);"
|
" gl_FragColor = texture2D (tex, texturecoord);"
|
||||||
"}";
|
"}";
|
||||||
|
|
Loading…
Reference in a new issue