diff options
author | bunnei <bunneidev@gmail.com> | 2015-10-10 01:32:38 +0200 |
---|---|---|
committer | bunnei <bunneidev@gmail.com> | 2015-10-22 03:54:56 +0200 |
commit | 71edb55114af129d6f580e271ad5196043342abe (patch) | |
tree | 73cd89075909781d728e92cfe121eee92effe84b /src/video_core/renderer_opengl/gl_rasterizer.h | |
parent | gl_shader_gen: Rename 'o' to 'attr' in vertex/fragment shaders. (diff) | |
download | yuzu-71edb55114af129d6f580e271ad5196043342abe.tar yuzu-71edb55114af129d6f580e271ad5196043342abe.tar.gz yuzu-71edb55114af129d6f580e271ad5196043342abe.tar.bz2 yuzu-71edb55114af129d6f580e271ad5196043342abe.tar.lz yuzu-71edb55114af129d6f580e271ad5196043342abe.tar.xz yuzu-71edb55114af129d6f580e271ad5196043342abe.tar.zst yuzu-71edb55114af129d6f580e271ad5196043342abe.zip |
Diffstat (limited to 'src/video_core/renderer_opengl/gl_rasterizer.h')
-rw-r--r-- | src/video_core/renderer_opengl/gl_rasterizer.h | 40 |
1 files changed, 14 insertions, 26 deletions
diff --git a/src/video_core/renderer_opengl/gl_rasterizer.h b/src/video_core/renderer_opengl/gl_rasterizer.h index 484579d82..79c34944a 100644 --- a/src/video_core/renderer_opengl/gl_rasterizer.h +++ b/src/video_core/renderer_opengl/gl_rasterizer.h @@ -153,36 +153,24 @@ public: /// Notify rasterizer that a 3DS memory region has been changed void NotifyFlush(PAddr addr, u32 size) override; -private: - /// Structure used for managing texture environment states - struct TEVConfigUniforms { - GLuint enabled; - GLuint color_sources; - GLuint alpha_sources; - GLuint color_modifiers; - GLuint alpha_modifiers; - GLuint color_alpha_op; - GLuint color_alpha_multiplier; - GLuint const_color; - GLuint updates_combiner_buffer_color_alpha; - }; - - struct TEVShader { + /// OpenGL shader generated for a given Pica register state + struct PicaShader { + /// OpenGL shader resource OGLShader shader; - // Hardware fragment shader - GLuint uniform_alphatest_ref; - GLuint uniform_tex; - GLuint uniform_tev_combiner_buffer_color; - GLuint uniform_tev_const_colors; - - TEVShader() = default; - TEVShader(TEVShader&& o) : shader(std::move(o.shader)), - uniform_alphatest_ref(o.uniform_alphatest_ref), uniform_tex(o.uniform_tex), - uniform_tev_combiner_buffer_color(o.uniform_tev_combiner_buffer_color), - uniform_tev_const_colors(o.uniform_tev_const_colors) {} + /// Fragment shader uniforms + enum Uniform : GLuint { + AlphaTestRef = 0, + TevConstColors = 1, + Texture0 = 7, + Texture1 = 8, + Texture2 = 9, + TevCombinerBufferColor = 10, + }; }; +private: + /// Structure used for storing information about color textures struct TextureInfo { OGLTexture texture; |