Skip to content

Instantly share code, notes, and snippets.

View patriciogonzalezvivo's full-sized avatar

Patricio Gonzalez Vivo patriciogonzalezvivo

View GitHub Profile
@patriciogonzalezvivo
patriciogonzalezvivo / toxic
Created June 27, 2015 12:55
Compiling a Tox Client in RPi
git clone git://github.com/jedisct1/libsodium.git
cd libsodium
git checkout tags/1.0.0
./autogen.sh
./configure && make check
sudo checkinstall --install --pkgname libsodium --pkgversion 1.0.0 --nodoc
sudo ldconfig
cd ..
git clone git://github.com/irungentoo/toxcore.git
// Author: @patriciogv ( patricio.io )
#include <stdio.h> // standard input / output functions
#include <iostream>
#include <sstream>
#include <stdlib.h>
#include <string.h> // string function definitions
#include <unistd.h> // UNIX standard function definitions
#include <fcntl.h> // File control definitions
#include <errno.h> // Error number definitions
@patriciogonzalezvivo
patriciogonzalezvivo / ubuntu.md
Last active August 29, 2015 14:19
Ubuntu post-installs

Sysadmin

sudo apt-get install nmap iptraf tcpdump dstat ngrep mtr nc lftp irssi iotop

IDE station

sudo apt-get install git-core tmux mc htop vim zsh lsof
@patriciogonzalezvivo
patriciogonzalezvivo / SFM.md
Last active January 10, 2024 12:29
SfM Tools

Probably the most straight forward way to start generating Point Clouds from a set of pictures.

VisualSFM is a GUI application for 3D reconstruction using structure from motion (SFM). The reconstruction system integrates several of my previous projects: SIFT on GPU(SiftGPU), Multicore Bundle Adjustment, and Towards Linear-time Incremental Structure from Motion. VisualSFM runs fast by exploiting multicore parallelism for feature detection, feature matching, and bundle adjustment.

For dense reconstruction, this program supports Yasutaka Furukawa's PMVS/CMVS tool chain, and can prepare data for Michal Jancosek's CMP-MVS. In addition, the output of VisualSFM is natively supported by Mathias Rothermel and Konrad Wenzel's [SURE]

@patriciogonzalezvivo
patriciogonzalezvivo / postgisOSM-LAS.md
Last active May 10, 2022 08:55
Loading OSM and LIDar to PostGIS
@patriciogonzalezvivo
patriciogonzalezvivo / PythonSetup.md
Created October 7, 2014 23:17
How to install Python correctly on Mac OSX

Install Homebrew

ruby -e "$(curl -fsSL https://raw.github.com/mxcl/homebrew/go)"

Add PATH to ~/.bash_profile and ~/.zshrc

export PATH=/usr/local/bin:$PATH
@patriciogonzalezvivo
patriciogonzalezvivo / SimpleCameraFollower.md
Last active September 19, 2021 19:20
Simple Camara Follow in OF
cam.setPosition( cam.getPosition()+(targetPos-cam.getPosition())*0.01 );
cam.lookAt(targetPos);

Simple Quad

glBegin(GL_QUADS);
glTexCoord2f(0, 0); glVertex3f(0, 0, 0);
glTexCoord2f(width, 0); glVertex3f(width, 0, 0);
glTexCoord2f(width, height); glVertex3f(width, height, 0);
glTexCoord2f(0,height);  glVertex3f(0,height, 0);
glEnd();

First :

git submodule add ...

Then:

git clone ...
git pull && git submodule init && git submodule update && git submodule status
git submodule foreach git checkout master
@patriciogonzalezvivo
patriciogonzalezvivo / GLSL-geom-billboard.md
Last active February 27, 2021 14:04
GLSL Geom shader billboard
    vec2 offSet[4];
 	offSet[0] = vec2(0.,0.);
    offSet[1] = vec2(0.,1.);
    offSet[2] = vec2(1.,0.);
    offSet[3] = vec2(1.,1.);

	vec3 zAxis = normalize( vNormal[0] );
    vec3 yAxis = vec3( 0.0, 1.0, 0.0 );
 vec3 xAxis = normalize( cross(zAxis, yAxis) );