Rahul Prabala
EE367 Final Project

---Full Requirements---
Ubuntu 14.04 (host)
Jetson TX1 (running Ubuntu 16.04)
RealSense SR300
DLP3000
Python
OpenCV 2.14.13

---Demo Requirements---
Ubuntu 14.04
Python
OpenCV 2.14.13

---Overview-----
The code for this project is intended to run on the NVIDIA Jetson TX1, with both an Intel RealSense TX1 and a TI DLP3000 connected to it. However, for purposes of demonstration, I have included a script to run a set of images on a Linux machine running Ubuntu 14.04. This will run all of the image processing and rectangle detection on an example set of images captured from the RealSense camera. It will not project or capture live images--this can only be done on the Jetson.

If running on a Jetson TX1, a precompiled zImage and Image are provided, as well as a precompiled kernel module for uvcvideo in order to interace with the RealSense. The RealSense does integrate with other operating systems, but is not supported by this code. See the librealsense repository for more information there.

An executable to download images to the DLP is also provided, as well as the source code used. This is compiled for both the host and the Jetson (with the suffixes host and jetson to denote the two). Several different border patterns are provided, but are not used in the host demo.




---Setup-----
We will assume python is already installed on your system.

Install the necessary requirements for OpenCV:
sudo apt-get install build-essential
sudo apt-get install cmake git libgtk2.0-dev pkg-config libavcodec-dev libavformat-dev libswscale-dev
sudo apt-get install python-dev python-numpy libtbb2 libtbb-dev libjpeg-dev libpng-dev libtiff-dev libjasper-dev libdc1394-22-dev
sudo apt-get install libopencv-dev python-opencv

I am unaware of how to get the Windows version of OpenCV working, as this project was done entirely under a Linux operating system.

These commands are packaged into the setup.sh script.

---Running----
For the host (non-Jetson), run capture_and_display_host.sh (./capture_and_display_host.sh). This runs the main pipeline with the proper input, and generates the mapping in "output.bmp" and the edges of the scene in "test_lines.bmp". To run the depth-dependent applications, execute "python depth_detect.py depth_transform.bmp 0" for colorized depth map or "python depth_detect.py depth_transform.bmp 1" for privacy mode. The colorized depth map can be found in "depth_colored.bmp" and the privacy zone will be in "privacy.bmp". To run the edge detection by itself, use "python applications.py output.bmp". These will not look correct on any machine as they are the bitmaps designed to be projected back onto the scene using the DLP. It is also assumed that the capture_and_display_host script was run prior to using the application scripts.