~ubuntu-branches/ubuntu/lucid/ffmpeg/lucid-security

« back to all changes in this revision

Viewing changes to libavcodec/pnm.c

  • Committer: Bazaar Package Importer
  • Author(s): Reinhard Tartler
  • Date: 2009-03-13 09:18:28 UTC
  • mfrom: (1.1.8 upstream)
  • Revision ID: james.westby@ubuntu.com-20090313091828-n4ktby5eca487uhv
Tags: 3:0.svn20090303-1ubuntu1+unstripped1
merge from ubuntu.jaunty branch

Show diffs side-by-side

added added

removed removed

Lines of Context:
138
138
                avctx->pix_fmt = PIX_FMT_GRAY16BE;
139
139
                if (s->maxval != 65535)
140
140
                    avctx->pix_fmt = PIX_FMT_GRAY16;
 
141
            } if (avctx->pix_fmt == PIX_FMT_RGB24) {
 
142
                if (s->maxval > 255)
 
143
                    avctx->pix_fmt = PIX_FMT_RGB48BE;
141
144
            } else {
142
 
                av_log(avctx, AV_LOG_ERROR, "16-bit components are only supported for grayscale\n");
 
145
                av_log(avctx, AV_LOG_ERROR, "Unsupported pixel format\n");
143
146
                avctx->pix_fmt = PIX_FMT_NONE;
144
147
                return -1;
145
148
            }