using (StreamWriter writer = File.AppendText(_logPath))
{ . . . }
using문을 이용하여 변수의 메모리를 활당하면 블럭이 끝나는 시점에서
자동으로 해제를한다.
스트림 변수외에도 이미지변수를 활당할 때 응용하면 프로그램을 정리할때 많은 도움이 된다.
열러가지 변수를 활당할 때 예제코드!
using (IplImage afSrcBinary = new IplImage(src.Size, BitDepth.U8, 1))
using (IplImage afSrcSmooth = new IplImage(src.Size, BitDepth.U8, 3))
{ . . . }
Ps. 크로마키 프로그램의 일부 코드