8

TGA 图像规范包含以下两个字段:

Field 5.1 (2 bytes) - X-origin of Image:
    These bytes specify the absolute horizontal coordinate for the lower
    left corner of the image as it is positioned on a display device having
    an origin at the lower left of the screen (e.g., the TARGA series).

Field 5.2 (2 bytes) - Y-origin of Image:
    These bytes specify the absolute vertical coordinate for the lower
    left corner of the image as it is positioned on a display device having
    an origin at the lower left of the screen (e.g., the TARGA series).

这对我来说似乎很奇怪。为什么图像在屏幕上的位置包含在图像本身的数据中?我希望图像不关心它们的位置,因为这是渲染引擎的责任。是否与 TGA 图像是为特殊视频卡设计的事实有关?

这是 TGA 规范的链接以供参考:http ://www.dca.fee.unicamp.br/~martino/disciplinas/ea978/tgaffs.pdf

4

1 回答 1

4

经过一番交谈,我们推​​断这些字段用于将大图像分解为许多较小的图像。例如,如果您将图像分割成 256x256 块,则 3Dfx 视频卡在绘制全屏图像时效率最高。这些块在屏幕上的偏移量可以使用这个字段来表示,这将允许渲染器重建原始图像。

请参阅此 Twitter 线程:https ://twitter.com/Donzanoid/status/496248178799550464

于 2014-08-04T22:35:17.613 回答