K
K
kos_dev2017-07-01 22:34:01
JavaScript
kos_dev, 2017-07-01 22:34:01

How to preserve CSS image background quality?

Hello, I have such a problem:
I download a picture, set it as a background for a page in the browser background-size: cover, but the quality is terribly lost.
Tell me how to properly set the background for the elements. Here's the example I'm trying to achieve: dinero.ru/#shop-slide
Many thanks in advance to everyone.

Answer the question

In order to leave comments, you need to log in

4 answer(s)
D
Dima, 2018-12-07
Dolgoter @SpiderPigAndCat

Nobody will answer you. Everyone sees the chaos and closes the issue. should be placed in sandboxes.
You can pass the contents of the block in different ways. If you need to pass within the page, then jquery. if on another page then use localstorage to store the number

M
Maxim Timofeev, 2018-12-07
@webinar

It is not necessary to transfer, it is necessary to read and add to post before submitting the form

S
Sanes, 2017-07-01
@Sanes

In the example of a FullHD image. Read more about media queries.

A
Adikjoro, 2017-07-02
@Adikjoro

It is necessary to understand the very concept of the word "image quality". It is determined by the number of pixels in the image.
A pixel is the unit of which an image is made up. The total number of image pixels is indicated by: the number of pixels in width and height, for example, 1280 by 720, that is, by the formula for finding the area S = a*b. Accordingly, the higher these values, the higher the image quality. Image quality is commonly referred to as image resolution.
Also, screens have their own resolutions. If the resolution of the image is less than the resolution of the screen, when the image is scaled to full screen, there is only an increase in the size of the pixels, from here they become noticeable, which is called loss of image quality.
You just need to download images with FullHD(1920x1080) resolution, which is the most common screen resolution these days.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question