You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
19 lines
663 B
19 lines
663 B
6 years ago
|
function x = imagedequant(q, w1, w2, w3)
|
||
|
%imagedequant dequantizes the pixel values of a tri-chromatic image
|
||
|
% Usage x = imagedequant(q, w1, w2, w3), where:
|
||
|
% Inputs
|
||
|
% - q is the input image who's values are going to be dequantized
|
||
|
% - w1 is the quantization step size for the first channel (red)
|
||
|
% - w2 is the quantization step size for the second channel (green)
|
||
|
% - w3 is the quantization step size for the third channel (blue)
|
||
|
%
|
||
|
% Output
|
||
|
% - x is the image with the dequantized values
|
||
|
|
||
|
x = struct;
|
||
|
x.red = mydequant(q.red, w1);
|
||
|
x.green = mydequant(q.green, w2);
|
||
|
x.blue = mydequant(q.blue, w3);
|
||
|
end
|
||
|
|