为什么Chrome和Internet Explorer完全不同地显示此图像?

In a rather curious case of confused identify, a photo of a piece of fruit changes itself based on what browser it is displayed it. What’s the secret behind the optical illusion? Is it a pear, an apple, or both?

在一个令人困惑的标识混淆的情况下,一块水果的照片会根据显示它的浏览器而改变。 错觉背后的秘密是什么? 它是梨,苹果还是两者?

Today’s Question & Answer session comes to us courtesy of SuperUser—a subdivision of Stack Exchange, a community-driven grouping of Q&A web sites.

今天的“问答”环节由SuperUser提供,它是Stack Exchange的一个分支,该社区是由社区驱动的Q&A网站分组。

问题 (The Question)

SuperUser reader Ethree writes:

超级用户读者Ethree写道:

Check this image out:

检出此图像:

On Chrome and Firefox it will show as a pear. Now, try to save it and look at it saved on your desktop. Also, try viewing in safari or IE. It will display as an apple!

在Chrome和Firefox上,它将显示为梨。 现在,尝试将其保存并查看保存在桌面上的内容。 另外,请尝试在Safari或IE中查看。 它将显示为苹果!

Try clicking the image and moving it around, you will notice the apple appears.

尝试单击图像并四处移动,您会发现苹果出现了。

I guess my question will be, “why does this happen?”

我想我的问题是,“为什么会这样?”

Why indeed? We saw it as a pear in Chrome and, sure enough, when we saved it to our downloads folder it displayed as an apple.

为什么会这样呢? 我们在Chrome浏览器中将其视为梨子,可以肯定的是,将其保存到下载文件夹后,它显示为苹果。

答案 (The Answer)

SuperUser contributor Matthew offers insight into the optical illusion:

超级用户贡献者Matthew提供了对错觉的见解:

The “white” pixels in the apple picture contain the picture of a pear, stored at a much higher intensity, i.e. very bright.

苹果图片中的“白色”像素包含梨的图片,以更高的强度存储,即非常明亮。

The “black” pixels in the pear picture contain the picture of an apple, stored at a fairly normal intensity, but scaled down to near black with the gamma correction.

梨图片中的“黑色”像素包含苹果的图片,以相当正常的强度存储,但通过伽玛校正将其缩小到接近黑色。

The image contains a gAMA chunk specifying a file gamma value of 0.02. When displayed without gamma correction, the viewer sees an apple with “white” pixels interspersed, which are actually the pear at its original (high) intensity.

该图像包含一个gAMA块,该块指定文件的伽马值为0.02。 在未进行伽玛校正的情况下显示时,观看者会看到一个散布着“白色”像素的苹果,实际上是原始(高)强度的梨。

When displayed with gamma correction, the viewer sees a colour-corrected pear with “black” pixels which are actually the apple rendered at a much lower gamma value.

当使用伽玛校正显示时,观看者会看到带有“黑色”像素的经过颜色校正的梨,实际上是苹果以较低的伽玛值渲染的梨。

Browsers which display the pear are showing the image using the gamma information provided in it, while browsers which display the apple are not using this gamma information.

显示梨的浏览器使用其中提供的伽玛信息显示图像,而显示苹果的浏览器不使用该伽玛信息。

In other words, Chrome is respecting the gamma correction value and Internet Explorer is not.

换句话说,Chrome会遵守伽玛校正值,而Internet Explorer则不会。



Have something to add to the explanation? Sound off in the the comments. Want to read more answers from other tech-savvy Stack Exchange users? Check out the full discussion thread here.

有什么补充说明吗? 在评论中听起来不对。 是否想从其他精通Stack Exchange的用户那里获得更多答案? 在此处查看完整的讨论线程

翻译自: https://www.howtogeek.com/149223/why-do-chrome-and-internet-explorer-display-this-image-completely-differently/

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值