我正在使用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: []
答案 0 :(得分:3)
你看过PDF spec了吗?它定义了它们的用法以及它们可以使用的键(如/ ActualText)。
答案 1 :(得分:1)
这些是与元数据相关的运算符,除非与可选内容一起使用,否则它们对渲染没有影响。如果它们的参数对您的应用程序有任何逻辑含义,您可以解释它们,否则您可以忽略它们。