Image processing method and device

An image processing device and image processing technology, applied in the field of image processing, to achieve the effects of enriching user experience, concise and clear steps, and improving image processing efficiency

Active Publication Date: 2020-12-29
HANGZHOU HIKROBOT TECH CO LTD
View PDF11 Cites 2 Cited by
  • Summary
  • Abstract
  • Description
  • Claims
  • Application Information

AI Technical Summary

Problems solved by technology

[0005] In view of this, the present invention provides an image processing method and device to solve the problem of how to quickly and appropriately display images on the terminal

Method used

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
View more

Image

Smart Image Click on the blue labels to locate them in the text.
Viewing Examples
Smart Image
  • Image processing method and device
  • Image processing method and device
  • Image processing method and device

Examples

Experimental program
Comparison scheme
Effect test

Embodiment 1

[0041] The present invention provides a kind of image processing method, be applied to front-end development (front-end development is to create the process that Web or app front-end interface is presented to the user, through HTML (HyperText Markup Language, hypertext markup language), CSS (Cascading Style Sheets, cascading style Table) and JavaScript and various technologies, frameworks, and solutions derived from it to realize the user interface interaction of Internet products), such as figure 1 As shown, the method includes:

[0042] S101: Obtain the first aspect ratio of the display area in the front-end interface container and the second aspect ratio of the target image to be displayed, where the display area is configured and displays a canvas;

[0043] The display area can be part or all of the container. For example, the width of the display area may be the width of the container or the difference between the width of the container and the preset gap; the height of ...

Embodiment 2

[0104] Such as figure 2 As shown, the image processing method of the present invention includes:

[0105] S201: Acquire the first aspect ratio of the display area and the second aspect ratio of the target image to be displayed;

[0106] S202: Compare the size of the first aspect ratio and the second aspect ratio;

[0107] S203: If the first aspect ratio is greater than the second aspect ratio, keep the second aspect ratio unchanged, and adjust the height of the target image to be equal to the height of the display area;

[0108] Suppose the width and height of the display area are w1, h1, ratio1=w1 / h1, the width and height of the target image are w2, h2, ratio2=w2 / h2, then the adjusted h2'=h1, w2'=h1*ratio2.

[0109] S204: If the first aspect ratio is smaller than the second aspect ratio, keep the second aspect ratio unchanged, and adjust the width of the target image to be equal to the width of the display area;

[0110] Suppose the width and height of the display area ar...

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to view more

PUM

No PUM Login to view more

Abstract

The invention provides an image processing method and device, and the method comprises the steps: obtaining a first aspect ratio of a display region in a front-end interface container and a second aspect ratio of a to-be-displayed target image, wherein the display region configurse and displays a canvas; comparing the first aspect ratio with the second aspect ratio; if the first aspect ratio is greater than the second aspect ratio, configuring the height of the canvas to be equal to the height of the display area and the width of the canvas to be equal to the product of the height of the display area and the second aspect ratio; if the first aspect ratio is smaller than the second aspect ratio, configuring the width of the canvas to be equal to the width of the display area and the heightof the canvas to be equal to the quotient of the width of the display area and the second aspect ratio; and filling the configured canvas with the target image. According to the invention, the targetimage can be rapidly and adaptively displayed according to different sizes of the display areas, and the image processing efficiency is improved.

Description

technical field [0001] The present invention relates to the technical field of image processing, in particular to an image processing method and device. Background technique [0002] With the rapid development of the network, there are more and more Internet applications. People can browse all kinds of information through browsers or apps, including text, tables, images, etc. In terms of conveying information, images are the most intuitive and clear way, so the display quality of images directly affects user experience. [0003] For the images to be displayed, some websites have image designers to process the images in each display area in a targeted manner for different screen sizes, so that the displayed images can achieve the best effect. However, due to the diversification of screen terminal sizes, this processing The efficiency of the method is very low, and it is difficult to meet the processing requirements of a large number of images. [0004] Therefore, how to di...

Claims

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to view more

Application Information

Patent Timeline
no application Login to view more
IPC IPC(8): G06F9/451G06T3/40
CPCG06F9/451G06T3/40
Inventor 黄丽娟
Owner HANGZHOU HIKROBOT TECH CO LTD
Who we serve
  • R&D Engineer
  • R&D Manager
  • IP Professional
Why Eureka
  • Industry Leading Data Capabilities
  • Powerful AI technology
  • Patent DNA Extraction
Social media
Try Eureka
PatSnap group products