⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 hmatrix3.h

📁 用于GPU通用计算的编程语言BrookGPU 0.4
💻 H
字号:
#ifndef HMATRIX3_H
#define HMATRIX3_H


#include "Types.h"
#include <math.h>

#define FWD 0
#define BACK 1

class HMatrix3{
public:
  HMatrix3();
  ~HMatrix3();
  
  void setIdentity();
  Tuple3f apply(const Tuple3f &p);
  static HMatrix3 multiply(const HMatrix3 &m1, const HMatrix3 &m2);
  void translate(float tx, float ty, float tz, int dir);
  void scale(float sx, float sy, float sz, int dir);
  void rotatex(float theta, int dir);
  void rotatey(float theta, int dir);
  void rotatez(float theta, int dir);
  void rotate(const Vector3 &ax, float theta, int dir);
  static HMatrix3 Transpose(HMatrix3 M);
  float data[4][4];
};

#endif /* HMATRIX3_H */

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -