Browse Source

rename draw_* to set_*

Former-commit-id: d664c18435deda8341e27f01875d2c6df5dc2010
Alec Jacobson 11 years ago
parent
commit
16b48a59f5
2 changed files with 13 additions and 13 deletions
  1. 8 8
      include/igl/viewer/Viewer.cpp
  2. 5 5
      include/igl/viewer/Viewer.h

+ 8 - 8
include/igl/viewer/Viewer.cpp

@@ -2166,7 +2166,7 @@ namespace igl
     data.dirty |= DIRTY_FACE | DIRTY_POSITION;
     data.dirty |= DIRTY_FACE | DIRTY_POSITION;
   }
   }
 
 
-  void Viewer::draw_normals(const Eigen::MatrixXd& N)
+  void Viewer::set_normals(const Eigen::MatrixXd& N)
   {
   {
     using namespace std;
     using namespace std;
     if (N.rows() == data.V.rows())
     if (N.rows() == data.V.rows())
@@ -2180,11 +2180,11 @@ namespace igl
       data.F_normals = N;
       data.F_normals = N;
     }
     }
     else
     else
-      cerr << "ERROR (draw_normals): Please provide a normal per face or a normal per vertex.";
+      cerr << "ERROR (set_normals): Please provide a normal per face or a normal per vertex.";
     data.dirty |= DIRTY_NORMAL;
     data.dirty |= DIRTY_NORMAL;
   }
   }
 
 
-  void Viewer::draw_colors(Eigen::MatrixXd C)
+  void Viewer::set_colors(Eigen::MatrixXd C)
   {
   {
     using namespace std;
     using namespace std;
     if (C.rows() == 1)
     if (C.rows() == 1)
@@ -2206,11 +2206,11 @@ namespace igl
       data.F_material_diffuse = C;
       data.F_material_diffuse = C;
     }
     }
     else
     else
-      cerr << "ERROR (draw_colors): Please provide a single color, or a color per face or per vertex.";
+      cerr << "ERROR (set_colors): Please provide a single color, or a color per face or per vertex.";
     data.dirty |= DIRTY_DIFFUSE;
     data.dirty |= DIRTY_DIFFUSE;
   }
   }
 
 
-  void Viewer::draw_UV(const Eigen::MatrixXd& UV)
+  void Viewer::set_UV(const Eigen::MatrixXd& UV)
   {
   {
     using namespace std;
     using namespace std;
     if (UV.rows() == data.V.rows())
     if (UV.rows() == data.V.rows())
@@ -2219,11 +2219,11 @@ namespace igl
       data.V_uv = UV;
       data.V_uv = UV;
     }
     }
     else
     else
-      cerr << "ERROR (draw_UV): Please provide uv per vertex.";
+      cerr << "ERROR (set_UV): Please provide uv per vertex.";
     data.dirty |= DIRTY_UV;
     data.dirty |= DIRTY_UV;
   }
   }
 
 
-  void Viewer::draw_UV(const Eigen::MatrixXd& UV_V, const Eigen::MatrixXi& UV_F)
+  void Viewer::set_UV(const Eigen::MatrixXd& UV_V, const Eigen::MatrixXi& UV_F)
   {
   {
     options.face_based = true;
     options.face_based = true;
     data.V_uv = UV_V;
     data.V_uv = UV_V;
@@ -2232,7 +2232,7 @@ namespace igl
   }
   }
 
 
 
 
-  void Viewer::draw_texture(
+  void Viewer::set_texture(
     const Eigen::Matrix<char,Eigen::Dynamic,Eigen::Dynamic>& R,
     const Eigen::Matrix<char,Eigen::Dynamic,Eigen::Dynamic>& R,
     const Eigen::Matrix<char,Eigen::Dynamic,Eigen::Dynamic>& G,
     const Eigen::Matrix<char,Eigen::Dynamic,Eigen::Dynamic>& G,
     const Eigen::Matrix<char,Eigen::Dynamic,Eigen::Dynamic>& B)
     const Eigen::Matrix<char,Eigen::Dynamic,Eigen::Dynamic>& B)

+ 5 - 5
include/igl/viewer/Viewer.h

@@ -347,11 +347,11 @@ namespace igl
 
 
     // Helpers that can draw the most common meshes
     // Helpers that can draw the most common meshes
     void draw_mesh(const Eigen::MatrixXd& V, const Eigen::MatrixXi& F);
     void draw_mesh(const Eigen::MatrixXd& V, const Eigen::MatrixXi& F);
-    void draw_normals(const Eigen::MatrixXd& N);
-    void draw_colors(Eigen::MatrixXd C);
-    void draw_UV(const Eigen::MatrixXd& UV);
-    void draw_UV(const Eigen::MatrixXd& UV_V, const Eigen::MatrixXi& UV_F);
-    void draw_texture(
+    void set_normals(const Eigen::MatrixXd& N);
+    void set_colors(Eigen::MatrixXd C);
+    void set_UV(const Eigen::MatrixXd& UV);
+    void set_UV(const Eigen::MatrixXd& UV_V, const Eigen::MatrixXi& UV_F);
+    void set_texture(
                       const Eigen::Matrix<char,Eigen::Dynamic,Eigen::Dynamic>& R,
                       const Eigen::Matrix<char,Eigen::Dynamic,Eigen::Dynamic>& R,
                       const Eigen::Matrix<char,Eigen::Dynamic,Eigen::Dynamic>& G,
                       const Eigen::Matrix<char,Eigen::Dynamic,Eigen::Dynamic>& G,
                       const Eigen::Matrix<char,Eigen::Dynamic,Eigen::Dynamic>& B);
                       const Eigen::Matrix<char,Eigen::Dynamic,Eigen::Dynamic>& B);