[trunk] fixed colorspace mapping for raw grayscale images (fixes issue 456)

This commit is contained in:
Matthieu Darbois 2014-12-22 18:39:14 +00:00
parent 59b844347c
commit 6922124c4c
1 changed files with 1 additions and 1 deletions

View File

@ -2381,7 +2381,7 @@ static opj_image_t* rawtoimage_common(const char *filename, opj_cparameters_t *p
numcomps = raw_cp->rawComp;
/* FIXME ADE at this point, tcp_mct has not been properly set in calling function */
if (numcomps == 0) {
if (numcomps == 1) {
color_space = OPJ_CLRSPC_GRAY;
} else if ((numcomps >= 3) && (parameters->tcp_mct == 0)) {
color_space = OPJ_CLRSPC_SYCC;