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

Unified Diff: chrome/browser/android/vr_shell/vr_shell_renderer.h

Issue 2795793002: Implementation of elbow model for the controller position and rotation. (Closed)
Patch Set: Rebasing. Created 3 years, 8 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
Index: chrome/browser/android/vr_shell/vr_shell_renderer.h
diff --git a/chrome/browser/android/vr_shell/vr_shell_renderer.h b/chrome/browser/android/vr_shell/vr_shell_renderer.h
index 98714797e3da986267b1ff2e6dc213ef2804a86c..35dd11ca0e9f78fe457978935a2419f12eb6f6a2 100644
--- a/chrome/browser/android/vr_shell/vr_shell_renderer.h
+++ b/chrome/browser/android/vr_shell/vr_shell_renderer.h
@@ -158,7 +158,7 @@ class LaserRenderer : public BaseQuadRenderer {
LaserRenderer();
~LaserRenderer() override;
- void Draw(const vr::Mat4f& view_proj_matrix);
+ void Draw(float opacity, const vr::Mat4f& view_proj_matrix);
private:
GLuint model_view_proj_matrix_handle_;
@@ -167,6 +167,7 @@ class LaserRenderer : public BaseQuadRenderer {
GLuint color_handle_;
GLuint fade_point_handle_;
GLuint fade_end_handle_;
+ GLuint opacity_handle_;
DISALLOW_COPY_AND_ASSIGN(LaserRenderer);
};
@@ -177,12 +178,15 @@ class ControllerRenderer : public BaseRenderer {
~ControllerRenderer() override;
void SetUp(std::unique_ptr<VrControllerModel> model);
- void Draw(VrControllerModel::State state, const vr::Mat4f& view_proj_matrix);
+ void Draw(VrControllerModel::State state,
+ float opacity,
+ const vr::Mat4f& view_proj_matrix);
bool IsSetUp() const { return setup_; }
private:
GLuint model_view_proj_matrix_handle_;
GLuint tex_uniform_handle_;
+ GLuint opacity_handle_;
GLuint indices_buffer_ = 0;
GLuint vertex_buffer_ = 0;
GLint position_components_ = 0;

Powered by Google App Engine
This is Rietveld 408576698