图像在不同的屏幕分辨率下显示不同

时间:2016-09-12 09:03:55

标签: html css mobile

Image as seen in 1366x760 screen

Image as seen in 1920x1080 screen

对我来说问题是在不同的浏览器设置中看到相同的图像。第一张图片下方的部分出现在1080p分辨率屏幕中,我没有看到减轻这种情况的方法。知道怎么做吗?

这是.css文件

/* Home Style */

TF-家{

background: url(../images/OdysseyTitleImage.jpg);
background-size: cover;
background-position: center;
background-attachment: fixed;
background-repeat: no-repeat;
color: #cfcfcf;

}

tf-home .overlay {

background: -moz-linear-gradient(top,  rgba(0,0,0,0.8) 0%, rgba(0,0,0,0.73) 17%, rgba(0,0,0,0.66) 35%, rgba(0,0,0,0.55) 62%, rgba(0,0,0,0.4) 100%); /* FF3.6+ */
background: -webkit-gradient(linear, left top, left bottom, color-stop(0%,rgba(0,0,0,0.8)), color-stop(17%,rgba(0,0,0,0.73)), color-stop(35%,rgba(0,0,0,0.66)), color-stop(62%,rgba(0,0,0,0.55)), color-stop(100%,rgba(0,0,0,0.4))); /* Chrome,Safari4+ */
background: -webkit-linear-gradient(top,  rgba(0,0,0,0.8) 0%,rgba(0,0,0,0.73) 17%,rgba(0,0,0,0.66) 35%,rgba(0,0,0,0.55) 62%,rgba(0,0,0,0.4) 100%); /* Chrome10+,Safari5.1+ */
background: -o-linear-gradient(top,  rgba(0,0,0,0.8) 0%,rgba(0,0,0,0.73) 17%,rgba(0,0,0,0.66) 35%,rgba(0,0,0,0.55) 62%,rgba(0,0,0,0.4) 100%); /* Opera 11.10+ */
background: -ms-linear-gradient(top,  rgba(0,0,0,0.8) 0%,rgba(0,0,0,0.73) 17%,rgba(0,0,0,0.66) 35%,rgba(0,0,0,0.55) 62%,rgba(0,0,0,0.4) 100%); /* IE10+ */
background: linear-gradient(to bottom,  rgba(0,0,0,0.8) 0%,rgba(0,0,0,0.73) 17%,rgba(0,0,0,0.66) 35%,rgba(0,0,0,0.55) 62%,rgba(0,0,0,0.4) 100%); /* W3C */
filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='#cc000000', endColorstr='#66000000',GradientType=0 ); /* IE6-9 */
height: 750px;
background-attachment: fixed;

}

这是相关的HTML代码

<div id="tf-home" class="text-center">
    <div class="overlay">
        <div class="content">
            <div><a href="https://www.youtube.com/watch?v=HRlP0t41wCw" class="btn tf-btn btn-default popup-video">Watch the trailer</a></div>
            <a href="#tf-game" class="fa fa-angle-down page-scroll"></a>
        </div>
    </div>
</div>
<div id="tf-game">
    <div class="overlay">
        <div class="container content-game">
            <div class="section-title">
                <h1 class="text-center">GAME FEATURES</h1><br/><br/>
                <p class="lead">
                    <span class="fa fa-dot-circle-o"></span> An immersive environment for <strong>exploration</strong> with a mystery-adventure story and <strong>science-based puzzles.</strong>
                </p>
                <p class="lead">
                    <span class="fa fa-dot-circle-o"></span> Plenty of <strong>scientific models</strong> within the game environment for investigation and conducting your own experiments.
                </p>
                <p class="lead">
                    <span class="fa fa-dot-circle-o"></span> A <strong>journal</strong> that reads like a mystery novel, while providing insight into the history of astronomy and mechanics from the ancient Greeks to Newton, and clues for solving the puzzles.
                </p>
            </div>
        </div>
    </div>
</div>

0 个答案:

没有答案