Building programming skeleton for background image subtraction