11/16/2016

Third Party software policy

Policy Overview

  • AGPL: do not use
  • GPL/GPL2/GPL3 : avoid unless absolutely necessary. May be ok on server.
  • LGPL: ok for server/internal clients.
MIT, BSD, Boost, Apache, OpenLDAP: ok in general

11/11/2016

Use emacs on windows

Get Emacs from http://www.gnu.org/software/emacs/download.html
Create a command alias e.bat under C:/bin/e.bat, with content:
@echo off
chcp 437
@echo on

C:\emacs\bin\emacs.exe -nw %1

Add HOME to environment variable: HOME: C:\Users\liangzou.
Add .emacs to this folder. (See the content here)

How to customize the emacs application (GUI version):
Open regedit, find HKEY_CURRENT_USER\SOFTWARE\Classes\Applications\runemacs.exe\shell\open\command, change the value to:
"C:\emacs\bin\runemacs.exe" -fh -geometry 120x59 --load "C:\Users\liangzou\.emacs" "%1"

How to use it in MobaXterm/Cygwin:
===========================
Copy the same .emacs file from C:\Users\liangzou\.emacs to the home directory of MobaXterm.
Add the alias: 
alias ew='/drives/c/emacs/bin/runemacs.exe -fh -geometry 120x53' to the MobaXterm .bashrc file.
Or
/cygdrive/c/emacs/bin/runemacs.exe for Cygwin

How to create a palette from an image

Load the image in GIMP

Image | Mode | Indexed

Windows | Dockable Dialogs | Palettes, right click on the Colormap, then Export as ...

Done

11/03/2016

All you need to know about Synergy

Synergy is a very good program to share keyboard and mouse, but there are somethings you need to know:

1. Running synergy on Windows will prevent the computer from sleeping
2. On Mac, using Synergy as a client may cause Laggy or sluggish cursor. This is the workaround command: ping -i 0.1 192.168.1.26 > /dev/null &

11/01/2016

How to find all client IP address from Asus Wireless Router

For some reason, the clients won't show all connected clients.
To find all of the connected clients:
http://192.168.1.1

System Logs | DHCP leases

10/28/2016

Best Point Cloud Viewer

http://www.danielgm.net/cc/release/

How to install:
https://github.com/cloudcompare/trunk/blob/master/BUILD.md


Needed to manually specify the Qt locations:
QT5_ROOT_PATH: /Users/liangzou/Qt/5.7/clang_64/lib/cmake
QT5_Concurrent_DIR: /Users/liangzou/Qt/5.7/clang_64/lib/cmake/Qt5Concurrent
...

Need to install to build: Qt5.7 and libqt5opengl5-dev

OPTION_BUILD_CCVIEWER should be FALSE.

The default installation location is /usr/local.
After running:
sudo make install, you can go to /usr/local/bin/CloudCompare and open the application.

Common issues:
How to install the latest QT?
https://www1.qt.io/download-open-source/#section-3
Run with sudo qt-opensource-linux-x64-5.9.2.run to install it in /opt/Qt5.9.2

How to fix libQt5Concurrent.so.5: cannot open shared object file: No such file or directory?
Add export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/opt/Qt5.9.2/5.9.2/gcc_64/lib

Also need to build with LAS library support.
Download and install liblas.
https://liblas.org/download.html

This requires boost, which can be provided by using our own precompiled boost library.

So need to fill:
LIBLAS_INCLUDE_DIR: /usr/local/include/liblas
LIBLAS_RELEASE_LIBRARY_FIELD: /usr/local/lib/liblas.so
Boost_INCLUDE_DIR: /home/liangzou/gitreview/deepmap/bazel-deepmap/external/precompiled_boost/linux/include

9/30/2016

How to copy string as a word on Mac

It's annoying to double click to select text on Mac because when you double click, it only selects a single word, instead of the whole connected words. Here is the trick:

Shift + Cmd and then double click to select the text.