2

我正在使用 PDFBox lib 来呈现 PDF 的内容。有一些限制(不支持 Type1 字体,不支持 CMYK 图像,不支持运算符 MP、PD、BMC、BDC 和 EMC)。

MP、PD、BMC、BDC、EMC这几个算子应该怎么理解?

更新:

operator: BDC args: [COSName{EmbeddedDocument}, COSName{MC1}]
operator: BDC args: [COSName{Document}, COSName{MC2}]
operator: gs args: [COSName{GS9}]
operator: cs args: [COSName{Pattern}]
operator: scn args: [COSName{P1}]
operator: re args: [COSInt{66}, COSFloat{570.302}, COSFloat{432.5}, COSFloat{23.278}]
operator: f args: [] // fill path
operator: k args: [COSInt{0}, COSInt{0}, COSInt{0}, COSInt{1}] // black color
operator: m args: [COSFloat{92.458}, COSFloat{559.601}] // move 
operator: l args: [COSFloat{93.769}, COSFloat{559.601}]
operator: l args: [COSFloat{94.699}, COSFloat{562.331}]
    ....
    ....
operator: l args: [COSFloat{88.003}, COSFloat{582.385}]
operator: l args: [COSFloat{92.467}, COSFloat{576.433}]
operator: l args: [COSFloat{88.196}, COSFloat{571.038}]
operator: f* args: []
operator: gs args: [COSName{GS10}]
operator: w args: [COSFloat{0.216}]
operator: M args: [COSFloat{2.613}]
operator: m args: [COSFloat{88.196}, COSFloat{571.038}]
operator: l args: [COSFloat{92.659}, COSFloat{571.038}] // add line to path
operator: l args: [COSFloat{94.624}, COSFloat{574.24}]
operator: l args: [COSFloat{96.545}, COSFloat{571.038}]
operator: l args: [COSFloat{102.076}, COSFloat{571.038}]
operator: l args: [COSFloat{97.507}, COSFloat{577.119}]
operator: l args: [COSFloat{101.649}, COSFloat{582.385}]
operator: l args: [COSFloat{97.186}, COSFloat{582.385}]
operator: l args: [COSFloat{95.328}, COSFloat{579.462}]
operator: l args: [COSFloat{93.513}, COSFloat{582.385}]
operator: l args: [COSFloat{88.003}, COSFloat{582.385}]
operator: l args: [COSFloat{92.467}, COSFloat{576.433}]
operator: l args: [COSFloat{88.196}, COSFloat{571.038}]
operator: h args: []
operator: S args: [] // stroke
operator: EMC args: []
operator: EMC args: []
4

2 回答 2

3

你看过PDF规范吗?它定义了它们的用法以及它们可以使用的键(如 /ActualText)。

于 2012-04-17T11:58:43.993 回答
1

这些是与元数据相关的运算符,它们对渲染没有影响,除非它们与可选内容一起使用。如果它们的参数对您的应用程序具有任何逻辑意义,您可以解释它们,否则您可以忽略它们。

于 2012-04-19T08:59:30.997 回答