Leading Zeros
1 개요
이미지의 값을 Binary로 표현하여 앞부터 연속적인 '0' 비트의 수를 반환하는 알고리즘입니다.
2 알고리즘 상세 설명
이미지의 값을 모두 Binary로 표현한 후 MSB(Most Significant Bit)부터 연속적인 '0' 비트의 수를 구합니다. 이는 Floating Point 및 Signed의 경우도 포함이 됩니다.
Source Value(Binary) | Destination Value |
---|---|
![]() |
![]() |
Fig. Source and Destination values of Leading Zeros
3 예제 코드
CFLImage fliSourceImage;
CFLImage fliDestinationImage;
COperationLeadingZeros leadingZeros;
leadingZeros.SetSourceImage(fliSourceImage);
leadingZeros.SetDestinationImage(fliDestinationImage);
leadingZeros.Execute();