Python
Simple Exercise For Waf Build
Waf is a build automation tool written by Python and designed to assist in the automatic compilation and installation of computer software. You can learn about it at waf tutorial.
Let’s use it to build project.
Waf is a build automation tool written by Python and designed to assist in the automatic compilation and installation of computer software. You can learn about it at waf tutorial.
Let’s use it to build project.
rm is a basic command line tool on Linux OS. It is efficient but can be dangerous if we use incorrectly because it can delete all files and can’t undo. The post shows a way to change its default behavior. Create Shell Script myrm Write a shell script and make Read more…
The geometry meaning of the determinant is the sign volumn value for three vectors in 3D world or a sign area value of two vectors (parallelogram) in the 2D coordinate system. For three points in the 2D world: The triangle is counterclockwise ordered if and clockwise ordered if Read more…
Here is dump log which shows the stack information. The class CBase has OpenModule and CloseModule interfaces, they can be called multible times. exe caused an Access Violation at location 00007FFA62174327 in module vtkCommonCore-8.2.dll Reading from location 0000000000000DA4. AddrPC Params 00007FFA62174327 0000000000000001 00007FFA9011F05B 0000013DF642A190 vtkCommonCore-8.2.dll!vtkCollection::DeleteElement 00007FFA62174155 0000000000000001 00007FFA622D3BFF 0000013DF6429290 vtkCommonCore-8.2.dll!vtkCollection::~vtkCollection Read more…
We have a model looks like in the following scene. It has been cut by a plane but the shape changed after that. So its surface become not flat. I got the cut plane information and planed to project all points on the cut part to the plane. The code Read more…
I find a old C plus plus project wrote all log to a local file, it didn’t truncate the local file but just append strings. Here is a simple file, I used the string “finished” to split it to different parts. this is a story about history haha finished the Read more…
The article is similar to my old post C++: Save Data To A Local File That Humans Can Read. I want to save a little data into a local file that human can’t read it. It is best done conveniently through C Plus Plus.The following example shows the entire logic. Read more…
The article describe a simple way to display point id list on the original model. We use VTK to draw and show all scenes. vtkSmartPointer<vtkPolyData> UShowData::ShowListByPoints(vtkSmartPointer<vtkPolyData> polyData, vtkSmartPointer<vtkIdList> list) { vSPNew( result, vtkPolyData ); vSPNew( resultPts, vtkPoints ); vSPNew( resultVerts, vtkCellArray ); for( int i = 0; i < list->GetNumberOfIds(); Read more…
Rotate Vector To Orthogonal Direction Just like in the picture, we will rotate vector to which is orthogonal to the neighbor . The vector is the cross product of and . #include <iostream> #include “point.hpp” int main() { Point m( 1, 0, 0 ); Point n( 1, 0.5, 0 ); Read more…