Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(3493)

Unified Diff: cc/output/shader.h

Issue 2647743002: The great shader refactor: Finish merging YUV shaders (Closed)
Patch Set: Rebase Created 3 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « cc/output/program_binding.h ('k') | cc/output/shader.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/output/shader.h
diff --git a/cc/output/shader.h b/cc/output/shader.h
index e69d4f4d16e7d635431134e3445a6975d6cf8644..6be4c5d83848ff7429974bc54df8a1b405146dae 100644
--- a/cc/output/shader.h
+++ b/cc/output/shader.h
@@ -134,7 +134,7 @@ enum ColorConversionMode {
COLOR_CONVERSION_MODE_NONE,
// Conversion is done directly from YUV to output RGB space, via a 3D texture
// represented as a 2D texture.
- COLOR_CONVERSION_MODE_2D_LUT_AS_3D_FROM_YUV,
+ COLOR_CONVERSION_MODE_LUT_FROM_YUV,
};
// TODO(ccameron): Merge this with BlendMode.
@@ -290,23 +290,22 @@ class FragmentShader {
int v_texture_location_ = -1;
int uv_texture_location_ = -1;
int a_texture_location_ = -1;
- int lut_texture_location_ = -1;
- int yuv_matrix_location_ = -1;
- int yuv_adj_location_ = -1;
int ya_clamp_rect_location_ = -1;
int uv_clamp_rect_location_ = -1;
+
+ // Analytic YUV to RGB convertion.
+ int yuv_matrix_location_ = -1;
+ int yuv_adj_location_ = -1;
+
+ // LUT YUV to color-converted RGB.
+ int lut_texture_location_ = -1;
+ int lut_size_location_ = -1;
int resource_multiplier_location_ = -1;
int resource_offset_location_ = -1;
private:
friend class Program;
- // Functions specific to YUV video.
- std::string GetShaderStringYUVVideo() const;
- void InitYUVVideo(gpu::gles2::GLES2Interface* context,
- unsigned program,
- int* base_uniform_index);
-
std::string GetHelperFunctions() const;
std::string GetBlendFunction() const;
std::string GetBlendFunctionBodyForRGB() const;
« no previous file with comments | « cc/output/program_binding.h ('k') | cc/output/shader.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698