#!/bin/bash
if [ "$1" == "--help" ] ; then
	cat <<EOF
Apply a special filter chain and mark polyps with contrast agent in use.
EOF
	exit
fi
HOST="$1"
PORT="$1"
HOST=${HOST%:*}
PORT=${PORT#*:}
COOKIEFILE="$0"
COOKIEFILE="${COOKIEFILE%/scripts/*}/config/cookie"
COOKIE=`cat $COOKIEFILE`
ANSWER=$(colotux_confirm 200 100 " Warning: This script may 
take a few minutes to run.
--------------------------
         Proceed?")
if [ "$ANSWER" != "1" ] ; then
	exit
fi
netcat -w 1 $HOST $PORT >/dev/null <<EOF
COOKIE $COOKIE
disp 16
gcenter 400
gwidth 800
saveori
nlgs 0 1 48
nlgs 1 1 32
nlgs 2 1 24
mixori 0.5 
nlgs 1 2 24
nlgs 2 2 18
nlgs 0 2 12
mixori 0.25
nlgs 2 4 12
nlgs 0 4 9
nlgs 1 4 6 
destroyori
disp 0
EOF
