PDF的BitsPerComponent如何转换为图像的每像素位数? [英] How does PDF's BitsPerComponent translate to Bits Per Pixel for images?

查看:826
本文介绍了PDF的BitsPerComponent如何转换为图像的每像素位数?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我的目标是将PDF转换为图像(特别是在TIFF中).

My goal is to convert a PDF into an image (specifically in TIFF).

有一个名为 BitsPerComponent

There is a PDF property called BitsPerComponent

然后根据页面上的描述

此属性的值可以为1、2、4、8或16.PDF规范不支持其他值.

This property can take the value 1, 2, 4, 8 or 16. Other values are not supported in the PDF Specification

是不是意味着 1、2、4、8或16 转换为图像中每个像素的位数?

Does that mean, 1, 2, 4, 8 or 16 translates to bits per pixel in images?

推荐答案

每个颜色分量听起来更像位,其中颜色分量是(Alpha)/红色/绿色/蓝色或灰色之一.因此,取每个分量的位数,然后乘以每个像素的分量,得出每个像素的位数.例如,如果您要说的是RGB图像,则有3个分量.每个组件8位的RGB将是每个像素图像8 * 3 = 24位.如果是灰度的,例如一个组件,每个组件8位将是每个像素8位.

Sounds more like bits per color component, where color component is one of either (Alpha)/Red/Green/Blue or Grey. So take the bits per component and multiply by the components per pixel to get bits per pixel. For example, if you're talking an RGB image you have 3 components. An RGB at 8 bit per component would be a 8 * 3 = 24bit per pixel image. If it was greyscale, e.g. one component, an 8 bit per component would be 8 bit per pixel.

这篇关于PDF的BitsPerComponent如何转换为图像的每像素位数?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆