Don’t forget to check out my new TextureMesh program to texture mesh your point cloud with RunSFM !
Please check out VisualSFM at http://www.cs.washington.edu/homes/ccwu/vsfm before trying RunSFM. VisualSFM is much more advance than RunSFM, though it still uses CMVS/PMVS to do the dense reconstruction.
I have put together my own package of Bundler and CMVS, unimaginatively named RunSFM, that will hopefully be easy to get up and running.
Just type make to compile. Then copy bundler-v0.4-source/lib/libANN_char.so to /usr/local/lib and run ldconfig . By default RunSFM is configured for a 64bit machine. To change this, edit the two files:
Change occurrences of -DNUMBITS=64 to -DNUMBITS=32.
Go to the directory containing all your images. Then type:
cd directory_containing_images (path to RunSFM)/RunSFM.sh
Grab some coffee …and that’s it!
The 3D model files will be in pmvs/models
RunSFM.sh has optional input arguments, which you can pass:
RunSFM.sh [IMAGES_PER_CLUSTER=100] [CPU_CORES=8] [MAX_MATCHING_SEQ=-1]
The default is 100 images and 8 CPU cores. If you have limited RAM then reduce the images per CMVS cluster.
MAX_MATCHING_SEQ limits the matching of an image to the last N images, useful if the images were captured sequentially eg. video. A value of -1 will do the full permutation and match every image pair possible. This has a time complexity of O(N*N/2), so be careful!
- TreeStump.zip (7MB, I’ve lost the full resolution images, so your results won’t be the same as in the video. There will be a small chunk missing from the trunk.)
- statue.zip (40MB)
- my_hand.zip (33MB)
Click on the thumbnails to launch the video. I used MeshLab to do the surface reconstruction and tidying up of the model.
Download mesh models
Some mesh models available for download. They can be viewed using Meshlab.
Download simple ply viewer
For those interested, here’s the program that I wrote to generate the image sequences for the animation. It was something I wrote in like an hour so don’t expect it to the a robust program. I assumed the input ply file is a text format outputted from Meshlab, in a very very strict format, the slightest change to the header format will cause the program to fail. You can download one of the mesh models to see what the header file looks like or change the source code to suit you,
Run the program by passing the ply file as the programs argument eg.
Use the mouse to navigate, all three mouse buttons control zoom/pan/rotate. Press ESC to exit the program, it will output a playback.bin file. You must press ESC to save the OpenGL view states to generate the animation frames. Now run the program again as follows
./simple_ply_viewer tree_stump_mesh.ply playback.bin
This will dump a whole bunch of frame-xxxx.png images in the current directory. I use mencoder to generate the video eg.
mencoder mf://*.png -fps 25 -ovc x264 -o video.avi