Matlab imfilter uint8 overflow
조회 수: 1 (최근 30일)
이전 댓글 표시
Hello,
I created a gaussian filter. Then I divide every element by the smallest element so my gaussian filter is in integer. When i convolve an image with it, I get 255 for everything. How do I fix this ? I want to convolve using integer values not decimals. Thanks.
댓글 수: 0
답변 (1개)
Walter Roberson
2016년 4월 9일
double() the data before convolving.
댓글 수: 5
Walter Roberson
2016년 4월 10일
imagesc(yourimage)
to display it automatically scaled according to the data it contains. This will not be the same as either of Guillaume's suggestions (which would normally be valid) because your filters are producing values larger than 255.
참고 항목
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!