void UpdateGuiOnNewFrame(Image proccessed)
 {
     //Thread Safety
     if (this.picNormal.InvokeRequired)
     {
         Stream.UpdateGuiOnNewFrameFunction d = new Stream.UpdateGuiOnNewFrameFunction(UpdateGuiOnNewFrame);
         this.Invoke(d, new object[] { proccessed });
     }
     else
     {
         this.picNormal.Image = proccessed;
     }
 }
        void UpdateGuiOnNewFrame(Image original, Image proccessed, Image depth)
        {
            //Thread Safety
            if (this.picNormal.InvokeRequired)
            {
                Stream.UpdateGuiOnNewFrameFunction d = new Stream.UpdateGuiOnNewFrameFunction(UpdateGuiOnNewFrame);
                //fix the depth into black image, AS YOU WANTED TO.
                //Here are the changes I've made (some of them)
                if (depth == null)
                    depth = new Bitmap(640, 480);
                if (original == null)
                    original = new Bitmap(640, 480);
                if (proccessed == null)
                    proccessed = new Bitmap(640, 480);

                this.Invoke(d, new object[] { original, depth, proccessed });
             
            }
            else
            {
                this.picNormal.Image = original;
                    this.picThresh.Image = proccessed;
                    this.picDepth.Image = depth;
            }
        }