gpt4 book ai didi

html - 双三次插值图像重采样

转载 作者:太空宇宙 更新时间:2023-11-04 16:31:25 25 4
gpt4 key购买 nike

我的网站上有一个 900 像素宽的 Logo 标题图片,它适合一个容器,该容器可以将其缩小以适合标题栏;原因是为适应标题栏而创建的图像在高分辨率移动设备上看起来很糟糕。

我发现我的图像在 chrome 中看起来非常好,但在 IE10 中它看起来令人震惊。你自己看; www.cmvisual.com

我已经尝试使用 -ms-interpolation-mode:bicubic 代码来尝试解决这个问题,但它似乎不起作用(快速浏览 ms 网站说它已过时?)。

这是我的代码:

    <html>
<head>
<title>Chris MacDonald Visualisation</title>
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<link href = "css/bootstrap.min.css" rel = "stylesheet">
<link href = "css/styles.css" rel = "stylesheet">
<style>
img.highqual { -ms-interpolation-mode:bicubic; }
img.nearestn { -ms-interpolation-mode:nearest-neighbour; }
</style>
</head>
<body>

<div class = "navbar navbar-inverse navbar-static-top" Role = "Navigation">
<div class = "container">

<div class = "navbar-inside pull-left">
<a href = "index.html">
<img class = "logo1" src = "img/motif.png" class = "highqual">
</a>
</div>

我是否遗漏了什么,有人对如何补救有任何建议吗?我考虑过可能包括标签以在不同设备上显示不同版本的图像,但这似乎很耗时,而且是一种廉价的解决方法?

非常感谢任何花时间提供帮助的人。

最佳答案

我在 IE10 图像下采样方面也遇到了一些问题,正如您所指出的,IE10 不再支持专有的 css 样式(而且自 IE9 以来)。有一些与 js 相关的修复,例如 this ,但是,对于您的具体情况,我建议使用 svg Logo (如果您不需要支持 IE8),而不是 png。您可以在这方面找到很好的信息 here .

关于html - 双三次插值图像重采样,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/21548098/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com