📄 tiny2.cpp
字号:
#define BZ_DISABLE_KCC_COPY_PROPAGATION_KLUDGE#include <blitz/tinyvec-et.h>using namespace blitz;typedef TinyVector<double,3> vec;inline void reflect(vec& reflection, const vec& incident, const vec& surfaceNormal){ // The surface normal must be unit length to use this equation. reflection = incident - 2 * dot(incident,surfaceNormal) * surfaceNormal;}template<typename T>void optimizationSink(T&);void foo(TinyVector<double,3>& x){ TinyVector<double,3> y, z; y = 1.00, 0.40, -1.00; z = 0.31, 0.20, 0.93; reflect(x, y, z);}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -