Problem: Could load texture correctly when rendering to framebuffer. However, when framebuffer is used, only left down corner of the texture is displayed. Solve: I loaded a model with some texture initialization before initiating framebuffer. And the model affected the initialization of framebuffer; Should initialize framebuffer before loading the model. Task for tomorrow: Try every … Read more09/05/2017

## KNN

Assignment1: KNN Install BallTree Library: sudo apt-get install python-sklearn list.append(), add new item to the end. numpy.arange(), sort numpy.reshape(), the same with reshape() in matlab numpy.median(numpy.array(outs))???? defaultDict.get(), https://stackoverflow.com/questions/11041405/why-dict-getkey-instead-of-dictkey ballTree.query(X, k == k_in), http://scikit-learn.org/stable/modules/generated/sklearn.neighbors.BallTree.html

## 09/04/2017

BallTree: http://blog.csdn.net/pipisorry/article/details/53156836

## 09/01/2017

Find large model Can load Sponza The loading library is not complete. The .mtl cannot be fully loaded. But the rendering time can achieve >28ms Color: Patney: people can easily find difference if color is changed. Use short in to replace float

## *.mtl content explanation

newmtl mtlName # mtlName is the name of the material Ka 1.000 1.000 1.000 #材质的阴影色（ambient color）用Ka声明。颜色用RGB定义，每条通道的值从0到1之间取。 Kd 1.000 1.000 1.000 #固有色（diffuse color） Ks 0.000 0.000 0.000 #高光色（specular color）, if black {specular color is closed} Ns 10.000 #Use Ns to represent weighted specular color, range 0 – 1000 illum 2 #illumination mode 0. 色彩开，阴影色关 1. 色彩开，阴影色开 … Read more*.mtl content explanation

## 08/30/2017

Plan for tomorrow: try to download dependency of https://github.com/NCCA/Sponza if not work, try to load the textures Change from single float to short in for peripheral pixels finish homework for 726 in python

## OpenGL Commonly Used Models

Crytek Atrium Sponza Rungholt scene

## 08/28/2017

low level Optimization of KFR Optimization of log(|| x – x0, y – y0||) Optimization of log function Optimization of fast atan Make the shader more complex to extend the rendering time to greater than 16ms I will talk about every step in detail Optimization of log(|| x – x0, y – y0||) There is … Read more08/28/2017

## 08/27/2017

Permutation: http://blog.csdn.net/hackbuteer1/article/details/6657435 Tomorrow: CORDIC FastLog Finding integer log base 2 of an integer (aka the position of the highest bit set) Find the log base 2 of an integer with the MSB N set in O(N) operations (the obvious way) Find the integer log base 2 of an integer with an 64-bit IEEE float Find … Read more08/27/2017

## How to build 5d array in C++

If I want to have Arr [const][variable][const][variable][const], what should I do? Use 5-layer typedef typedef int A1 [9]; typedef A1 *A2; typedef A2 A3[8]; typedef A3 *A4; typedef A4 A5 [7]; int main() { A5* x; return 0; } 2. Use only one typedef typedef int(*(*(*B[7])[8])[9]) int main() { B y = 0; }