MythTV  master
Variables
mythopenglvideoshaders.h File Reference
#include <QString>
Include dependency graph for mythopenglvideoshaders.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Variables

static const QString DefaultVertexShader
 
static const QString RGBFragmentShader
 
static const QString YUVFragmentExtensions
 
static const QString YUVFragmentShader
 
static const QString BicubicShader
 
static const QString GLSL300VertexShader
 
static const QString GLSL300YUVFragmentExtensions
 
static const QString GLSL300YUVFragmentShader
 

Variable Documentation

◆ DefaultVertexShader

const QString DefaultVertexShader
static
Initial value:
=
"attribute highp vec2 a_position;\n"
"attribute highp vec2 a_texcoord0;\n"
"varying highp vec2 v_texcoord0;\n"
"uniform highp mat4 u_projection;\n"
"void main()\n"
"{\n"
" gl_Position = u_projection * vec4(a_position, 0.0, 1.0);\n"
" v_texcoord0 = a_texcoord0;\n"
"}\n"

Definition at line 6 of file mythopenglvideoshaders.h.

Referenced by MythOpenGLVideo::CreateVideoShader().

◆ RGBFragmentShader

const QString RGBFragmentShader
static
Initial value:
=
"uniform sampler2D s_texture0;\n"
"varying highp vec2 v_texcoord0;\n"
"void main(void)\n"
"{\n"
" highp vec4 color = texture2D(s_texture0, v_texcoord0);\n"
" gl_FragColor = vec4(color.rgb, 1.0);\n"
"}\n"

Definition at line 17 of file mythopenglvideoshaders.h.

Referenced by MythOpenGLVideo::CreateVideoShader().

◆ YUVFragmentExtensions

const QString YUVFragmentExtensions
static
Initial value:
=
"#define LINEHEIGHT m_frameData.x\n"
"#define COLUMN m_frameData.y\n"
"#define MAXHEIGHT m_frameData.z\n"
"#define FIELDSIZE m_frameData.w\n"
"#ifdef MYTHTV_RECTS\n"
"#extension GL_ARB_texture_rectangle : enable\n"
"#define texture2D texture2DRect\n"
"#define sampler2D sampler2DRect\n"
"#endif\n"
"#ifdef MYTHTV_EXTOES\n"
"#extension GL_OES_EGL_image_external : require\n"
"#define sampler2D samplerExternalOES\n"
"#endif\n"

Definition at line 41 of file mythopenglvideoshaders.h.

Referenced by MythOpenGLVideo::CreateVideoShader().

◆ YUVFragmentShader

const QString YUVFragmentShader
static

Definition at line 56 of file mythopenglvideoshaders.h.

Referenced by MythOpenGLVideo::CreateVideoShader().

◆ BicubicShader

const QString BicubicShader
static
Initial value:
=
"uniform sampler2D s_texture0;\n"
"uniform sampler2D s_texture1;\n"
"varying highp vec2 v_texcoord0;\n"
"void main(void)\n"
"{\n"
" highp vec2 coord = (v_texcoord0 * vec2(%BICUBICWIDTH%, %BICUBICHEIGHT%)) - vec2(0.5, 0.5);\n"
" highp vec4 parmx = texture2D(s_texture1, vec2(coord.x, 0.0));\n"
" highp vec4 parmy = texture2D(s_texture1, vec2(coord.y, 0.0));\n"
" highp vec2 e_x = vec2(%BICUBICCWIDTH%, 0.0);\n"
" highp vec2 e_y = vec2(0.0, LINEHEIGHT);\n"
" highp vec2 coord10 = v_texcoord0 + parmx.x * e_x;\n"
" highp vec2 coord00 = v_texcoord0 - parmx.y * e_x;\n"
" highp vec2 coord11 = coord10 + parmy.x * e_y;\n"
" highp vec2 coord01 = coord00 + parmy.x * e_y;\n"
" coord10 = coord10 - parmy.y * e_y;\n"
" coord00 = coord00 - parmy.y * e_y;\n"
" highp vec4 tex00 = texture2D(s_texture0, coord00);\n"
" highp vec4 tex10 = texture2D(s_texture0, coord10);\n"
" highp vec4 tex01 = texture2D(s_texture0, coord01);\n"
" highp vec4 tex11 = texture2D(s_texture0, coord11);\n"
" tex00 = mix(tex00, tex01, parmy.z);\n"
" tex10 = mix(tex10, tex11, parmy.z);\n"
" gl_FragColor = mix(tex00, tex10, parmx.z);\n"
"}\n"

Definition at line 191 of file mythopenglvideoshaders.h.

◆ GLSL300VertexShader

const QString GLSL300VertexShader
static
Initial value:
=
"in highp vec2 a_position;\n"
"in highp vec2 a_texcoord0;\n"
"out highp vec2 v_texcoord0;\n"
"uniform highp mat4 u_projection;\n"
"void main()\n"
"{\n"
" gl_Position = u_projection * vec4(a_position, 0.0, 1.0);\n"
" v_texcoord0 = a_texcoord0;\n"
"}\n"

Definition at line 244 of file mythopenglvideoshaders.h.

Referenced by MythOpenGLVideo::CreateVideoShader().

◆ GLSL300YUVFragmentExtensions

const QString GLSL300YUVFragmentExtensions
static
Initial value:
=
"#define LINEHEIGHT m_frameData.x\n"
"#define COLUMN m_frameData.y\n"
"#define MAXHEIGHT m_frameData.z\n"
"#define FIELDSIZE m_frameData.w\n"
"#define sampler2D highp usampler2D\n"

Definition at line 255 of file mythopenglvideoshaders.h.

Referenced by MythOpenGLVideo::CreateVideoShader().

◆ GLSL300YUVFragmentShader

const QString GLSL300YUVFragmentShader
static

Definition at line 262 of file mythopenglvideoshaders.h.

Referenced by MythOpenGLVideo::CreateVideoShader().