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
- Summary
- Abstract
- Description
- Claims
- Application Information
AI Technical Summary
Problems solved by technology
Method used
Image
Examples
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...
PUM
Abstract
Description
Claims
Application Information
- R&D Engineer
- R&D Manager
- IP Professional
- Industry Leading Data Capabilities
- Powerful AI technology
- Patent DNA Extraction
Browse by: Latest US Patents, China's latest patents, Technical Efficacy Thesaurus, Application Domain, Technology Topic, Popular Technical Reports.
© 2024 PatSnap. All rights reserved.Legal|Privacy policy|Modern Slavery Act Transparency Statement|Sitemap|About US| Contact US: help@patsnap.com