WO2021169827A1 - 图像裁剪方法、装置、设备及存储介质 - Google Patents

图像裁剪方法、装置、设备及存储介质 Download PDF

Info

Publication number
WO2021169827A1
WO2021169827A1 PCT/CN2021/076687 CN2021076687W WO2021169827A1 WO 2021169827 A1 WO2021169827 A1 WO 2021169827A1 CN 2021076687 W CN2021076687 W CN 2021076687W WO 2021169827 A1 WO2021169827 A1 WO 2021169827A1
Authority
WO
WIPO (PCT)
Prior art keywords
cropping
image
frame
area
size
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Ceased
Application number
PCT/CN2021/076687
Other languages
English (en)
French (fr)
Chinese (zh)
Inventor
李林兴
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Beijing ByteDance Network Technology Co Ltd
Original Assignee
Beijing ByteDance Network Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Beijing ByteDance Network Technology Co Ltd filed Critical Beijing ByteDance Network Technology Co Ltd
Priority to JP2022549256A priority Critical patent/JP7513731B2/ja
Priority to KR1020227027005A priority patent/KR102949430B1/ko
Priority to EP21761230.8A priority patent/EP4113438B1/en
Priority to AU2021225277A priority patent/AU2021225277B2/en
Publication of WO2021169827A1 publication Critical patent/WO2021169827A1/zh
Priority to US17/877,711 priority patent/US12008684B2/en
Anticipated expiration legal-status Critical
Priority to US18/662,656 priority patent/US20240296598A1/en
Ceased legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING OR CALCULATING; COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T7/00Image analysis
    • G06T7/10Segmentation; Edge detection
    • G06T7/12Edge-based segmentation
    • GPHYSICS
    • G06COMPUTING OR CALCULATING; COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T11/00Two-dimensional [2D] image generation
    • GPHYSICS
    • G06COMPUTING OR CALCULATING; COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/01Input arrangements or combined input and output arrangements for interaction between user and computer
    • G06F3/048Interaction techniques based on graphical user interfaces [GUI]
    • G06F3/0484Interaction techniques based on graphical user interfaces [GUI] for the control of specific functions or operations, e.g. selecting or manipulating an object, an image or a displayed text element, setting a parameter value or selecting a range
    • G06F3/04845Interaction techniques based on graphical user interfaces [GUI] for the control of specific functions or operations, e.g. selecting or manipulating an object, an image or a displayed text element, setting a parameter value or selecting a range for image manipulation, e.g. dragging, rotation, expansion or change of colour
    • GPHYSICS
    • G06COMPUTING OR CALCULATING; COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/01Input arrangements or combined input and output arrangements for interaction between user and computer
    • G06F3/048Interaction techniques based on graphical user interfaces [GUI]
    • G06F3/0487Interaction techniques based on graphical user interfaces [GUI] using specific features provided by the input device, e.g. functions controlled by the rotation of a mouse with dual sensing arrangements, or of the nature of the input device, e.g. tap gestures based on pressure sensed by a digitiser
    • G06F3/0488Interaction techniques based on graphical user interfaces [GUI] using specific features provided by the input device, e.g. functions controlled by the rotation of a mouse with dual sensing arrangements, or of the nature of the input device, e.g. tap gestures based on pressure sensed by a digitiser using a touch-screen or digitiser, e.g. input of commands through traced gestures
    • GPHYSICS
    • G06COMPUTING OR CALCULATING; COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T11/00Two-dimensional [2D] image generation
    • G06T11/60Creating or editing images; Combining images with text
    • GPHYSICS
    • G06COMPUTING OR CALCULATING; COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T3/00Geometric image transformations in the plane of the image
    • G06T3/40Scaling of whole images or parts thereof, e.g. expanding or contracting
    • GPHYSICS
    • G06COMPUTING OR CALCULATING; COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T7/00Image analysis
    • G06T7/30Determination of transform parameters for the alignment of images, i.e. image registration
    • GPHYSICS
    • G06COMPUTING OR CALCULATING; COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T2200/00Indexing scheme for image data processing or generation, in general
    • G06T2200/24Indexing scheme for image data processing or generation, in general involving graphical user interfaces [GUIs]
    • GPHYSICS
    • G06COMPUTING OR CALCULATING; COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T2207/00Indexing scheme for image analysis or image enhancement
    • G06T2207/20Special algorithmic details
    • G06T2207/20112Image segmentation details
    • G06T2207/20132Image cropping
    • GPHYSICS
    • G06COMPUTING OR CALCULATING; COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T2207/00Indexing scheme for image analysis or image enhancement
    • G06T2207/20Special algorithmic details
    • G06T2207/20212Image combination
    • G06T2207/20224Image subtraction
    • GPHYSICS
    • G06COMPUTING OR CALCULATING; COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T2210/00Indexing scheme for image generation or computer graphics
    • G06T2210/22Cropping

Definitions

  • the embodiments of the present application relate to the field of image processing technologies, and in particular, to an image cropping method, device, device, and storage medium.
  • the image cropping function is the basic function of most mobile terminal retouching software.
  • FIG. 1A after the image cropping function is triggered, the target image 102 and the cropping frame 103 are superimposed and displayed on the image display area 101 of the display screen 100 of the mobile terminal.
  • the retouching software of the mobile terminal adjusts the size of the cropping frame 103 in response to the user's drag event on the border of the cropping frame 103.
  • a cropped image 104 is displayed in the image display area 101.
  • the cropped image 104 is within the crop frame 103 at the end of the drag event. 102 part of the target image.
  • the above operations on the crop frame are also called hand-following operations.
  • the cropping frame 103 When the border of the cropping frame 103 is dragged to reach the edge of the image display area 101, the cropping is over. If the cropping effect expected by the user is not achieved, the user needs to drag the border of the cropping frame 103 in the same way again, and repeat it several times. Achieve the desired cutting effect. As the size of the cropped image approaches the size of the target image, the draggable range of the cropping frame 103 becomes smaller and smaller, and the operation difficulty increases.
  • the embodiments of the present application provide an image cropping method, device, equipment, and storage medium, so as to achieve the purpose of reducing the difficulty of the cropping operation and improving the efficiency of the cropping operation.
  • an image cropping method including:
  • the image in the current cropping area of the cropping frame is displayed at the second target position of the image display area according to the current size ratio of the image in the cropping area of the cropping frame.
  • the image cropping method when the border of the cropping frame reaches the first target position of the image display area, for example, reaches the boundary of the image display area, if the cropping frame is not released, that is, the drag event of the cropping frame continues. Then the image cropping process can still continue, that is, in this case, the size of the image in the crop area of the crop frame can be adjusted.
  • the application that implements the method provided by the embodiment of this application will continue to adjust the size of the image to achieve
  • the purpose of continuing cropping can prevent the user from frequently dragging the cropping frame in the same way in order to achieve the desired effect, reduce the difficulty of image cropping operations, and improve the efficiency of image cropping.
  • the size of the image in the cropping area of the cropping frame is adjusted until the size of the cropping frame The drag event ends or the border of the crop box reaches the border of the target image.
  • the image in the crop area of the crop frame is a part of the target image.
  • image cropping is to retain the picture that the user needs by cropping.
  • the border of the cropping frame reaches the boundary of the target image, the picture that the user needs may have appeared, so there is no need to continue to adjust the image. size of. Therefore, “the border of the cropping frame reaches the boundary of the target image” is preset as the cut-off condition for image size adjustment. When this cut-off condition is met, image cropping is automatically stopped to improve the quality and effect of image cropping.
  • the first target position of the image display area may be any of the following positions: the border of the image display area, the position of the image display area where the border of the cropping frame reaches the set minimum size.
  • adjusting the size of the image in the cropping area of the cropping frame refers to reducing the size of the image in the cropping area of the cropping frame; when the border of the cropping frame reaches the boundary of the image display area, when the drag event of the cropping frame starts When the border of the cropping frame coincides with the boundary of the target image, and the drag event of the cropping frame continues, adjusting the size of the image in the cropping area of the cropping frame specifically refers to zooming in on the cropping area of the cropping frame.
  • adjusting the size of the image in the cropping area of the cropping frame specifically refers to enlarging the cropping of the cropping frame The size of the image in the area.
  • the size of the image in the crop area of the crop frame is reduced, so that the proportion of the image in the crop area of the crop frame in the target image increases.
  • the cropping area of the cropping frame can be continuously adjusted
  • the current size ratio of the image in the cropping area of the cropping frame is determined according to the current display size.
  • the effect of image cropping can be previewed in real time, which helps to improve the efficiency of image cropping.
  • the size parameter of the image in the crop area of the crop frame can also be adjusted.
  • the current size ratio of the image in the crop area of the crop frame is determined according to the size parameter at the end of the drag event of the crop frame.
  • the image cropping effect cannot be previewed in real time during the image cropping process, since the size parameters of the image are recorded, the image cropping result can be accurately displayed after the drag event ends.
  • the image size adjustment speed may be determined according to the parameters of the drag event of the crop frame, and the size of the image in the crop area of the crop frame can be adjusted according to the image adjustment speed.
  • the inventor found through analyzing the user's usage habits that certain drag habits of the user when dragging the cropping frame reflect his expectation for the speed of image size adjustment. These drag habits will be reflected in the parameters of the drag event. Therefore, the image adjustment speed is determined according to the parameters of the drag event, and the drag operation can be controlled to meet or be close to the user's expectation of the image size adjustment speed.
  • the parameters of the drag event of the cropping frame may include the drag distance, and the larger the drag distance, the greater the image size adjustment speed.
  • the inventor found through analyzing the user’s usage habits that when the user drags the cropping frame, the greater the drag amplitude, that is, the greater the drag distance of the drag event, which represents the image size desired by the user. The faster the adjustment speed. Therefore, determining the image size adjustment speed according to the drag distance meets the user's expectation.
  • the method provided in the embodiments of this application can also adjust the display position of the target image when the drag event of the cropping frame continues, so that the center of the target image is always aligned with the center of the cropping frame.
  • the center of the cropping area coincides, or the center of the target image is approached to the center of the cropping area of the cropping frame according to the specified path.
  • the border of the cropping frame needs to be adjusted multiple times in multiple directions. If the display position of the target image is adjusted in the above manner, it is possible to avoid missing the image that the user expects to retain during the image cropping process, and the desired effect can be achieved through a small number of adjustments in a few directions, and the cropping efficiency can be improved.
  • an image cropping device including:
  • An image adjustment module for adjusting the size of the image in the crop area of the crop frame when the border of the crop frame reaches the first target position of the image display area and the drag event of the crop frame continues;
  • the image display module is used to display the current cropping area of the cropping frame at the second target position of the image display area according to the current size ratio of the image in the cropping area of the cropping frame when the drag event of the cropping frame ends. Image.
  • the image cropping device provided by the embodiment of the present application, when the border of the cropping frame reaches the first target position of the image display area, for example, when the border of the image display area is reached, if the cropping frame is not released, that is, the drag event of the cropping frame continues. Then the image cropping process can still continue, that is, in this case, the size of the image in the crop area of the crop frame can be adjusted.
  • the application of the device provided by the embodiment of the present application will continue to adjust the size of the image to achieve
  • the purpose of continuing cropping can prevent the user from frequently dragging the cropping frame in the same way in order to achieve the desired effect, reduce the difficulty of image cropping operations, and improve the efficiency of image cropping.
  • the image adjustment module adjusts the size of the image in the cropping area of the cropping frame when the border of the cropping frame reaches the first target position of the image display area and the drag event of the cropping frame continues until the The drag event of the cropping box ends or the border of the cropping box reaches the boundary of the target image.
  • the image in the crop area of the crop frame is a part of the target image.
  • image cropping is to retain the picture that the user needs by cropping.
  • the border of the cropping frame reaches the boundary of the target image, the picture that the user needs may have appeared, so there is no need to continue to adjust the image. size of. Therefore, pre-set "the border of the cropping frame reaches the boundary of the target image" as the cut-off condition for image size adjustment.
  • this cut-off condition is met, image cropping is automatically stopped to improve the quality and effect of image cropping.
  • the first target position of the image display area may be any of the following positions: the border of the image display area, and the position of the image display area where the border of the cropping frame reaches the set minimum size.
  • the device provided by the embodiment of the present application can still continue to perform image cropping when the border of the cropping frame reaches the boundary of the image display area; in addition, when the border of the cropping frame reaches the set minimum size, the image can still be continued. Cropped.
  • adjusting the size of the image in the cropping area of the cropping frame refers to reducing the size of the image in the cropping area of the cropping frame; when the border of the cropping frame reaches the boundary of the image display area, when the drag event of the cropping frame starts When the border of the cropping frame coincides with the boundary of the target image, and the drag event of the cropping frame continues, adjusting the size of the image in the cropping area of the cropping frame specifically refers to zooming in on the cropping area of the cropping frame.
  • adjusting the size of the image in the cropping area of the cropping frame specifically refers to enlarging the cropping of the cropping frame The size of the image in the area.
  • the image adjustment module can continuously adjust the size of the cropping frame.
  • the display size of the image in the crop area correspondingly, the current size ratio of the image in the crop area of the crop frame is determined according to the current display size.
  • the image adjustment module can also adjust the size parameters of the image in the crop area of the crop frame.
  • the current size ratio of the image in the crop area of the crop frame is based on the size parameter at the end of the drag event of the crop frame. definite.
  • the image cropping effect cannot be previewed in real time during the image cropping process, since the size parameters of the image are recorded, the image cropping result can be accurately displayed after the drag event ends.
  • the image size adjustment speed can be determined according to the parameters of the drag event of the crop frame, and the size of the image in the crop area of the crop frame can be adjusted according to the image adjustment speed.
  • the inventor found through analyzing the user's usage habits that certain drag habits of the user when dragging the cropping frame reflect his expectations for the speed of image size adjustment. These drag habits will be reflected in the parameters of the drag event. Therefore, the image adjustment speed is determined according to the parameters of the drag event, and the drag operation can be controlled to meet or be close to the user's expectation of the image size adjustment speed.
  • the parameters of the drag event of the cropping frame may include the drag distance, and the larger the drag distance, the greater the image size adjustment speed.
  • the inventor found through analyzing the user’s usage habits that when the user drags the cropping frame, the greater the drag amplitude, that is, the greater the drag distance of the drag event, which represents the image size desired by the user. The faster the adjustment speed. Therefore, determining the image size adjustment speed according to the drag distance meets the user's expectation.
  • the image adjustment module can also adjust the display position of the target image when the drag event of the cropping frame continues, so that the center of the target image is always the same as the center of the cropping area of the cropping frame. To coincide, or to make the center of the target image approach the center of the cropping area of the cropping frame along a specified path.
  • the border of the cropping frame needs to be adjusted multiple times in multiple directions. If the display position of the target image is adjusted in the above manner, it is possible to avoid missing the image that the user expects to retain during the image cropping process, and the desired effect can be achieved through a small number of adjustments in a few directions, and the cropping efficiency can be improved.
  • an embodiment of the present application also provides a mobile terminal, including a processor and a memory;
  • the memory is used to store programs for executing the methods described in the method embodiments of the first aspect; the processor is configured to execute the programs stored in the memory.
  • the border of the cropping frame reaches the first target position of the image display area, for example, the border of the image display area is reached. If the cropping frame is not released, that is, the drag event of the cropping frame continues, then The image cropping process can still continue, that is, in this case, the size of the image in the crop area of the crop frame can be adjusted. Therefore, with the mobile terminal provided by the embodiment of the present application, when the user drags the cropping frame to the border of the image display area, as long as the cropping frame is not released, the program executed by the terminal processor provided by the embodiment of the present application will continue to adjust the image. The size of, to achieve the purpose of continuous cropping, which can avoid the user from frequently dragging the cropping frame in the same way in order to achieve the desired effect, reducing the difficulty of image cropping operation, and improving the efficiency of image cropping.
  • an embodiment of the present application also provides a computer-readable storage medium that stores a program for executing the method described in each embodiment of the first aspect.
  • the program stored in the computer-readable storage medium provided by the embodiment of the application reaches the first target position of the image display area when the border of the cropping frame reaches the first target position of the image display area, for example, reaches the border of the image display area. If the cropping frame is not released, the cropping frame If the drag event continues, the image cropping process can still continue, that is, in this case, the size of the image in the cropping area of the cropping frame can be adjusted. Therefore, using the program saved in the computer-readable storage medium provided by the embodiment of the present application, when the user drags the cropping frame to the border of the image display area, as long as the cropping frame is not released, the program will continue to adjust the size of the image to continue cropping. The purpose of this can prevent users from frequently dragging the cropping frame in the same way in order to achieve the desired effect, reduce the difficulty of image cropping operations, and improve the efficiency of image cropping.
  • the embodiments of the present application also provide an image cropping method, device, equipment, and storage medium, so as to reduce the complexity of cropping operations.
  • an embodiment of the present application provides an image cropping method, including:
  • the image in the current cropping area of the cropping frame is displayed at the target position of the image display area according to the current size ratio of the image in the cropping area of the cropping frame.
  • the border of the cropping frame needs to be adjusted multiple times in multiple directions. If the display position of the target image is adjusted according to the method provided by the fifth aspect of the embodiment of the present application, it is possible to avoid missing the image that the user expects to retain during the image cropping process, and the desired effect can be achieved through a small number of adjustments in a few directions. Cutting efficiency, reducing the complexity of cutting operations.
  • an image cropping device including:
  • the image adjustment module when a drag event of the cropping frame is detected, during the drag event of the cropping frame, adjust the display position of the target image so that the center of the target image always coincides with the center of the cropping area of the cropping frame, or Make the center of the target image approach the center of the crop area of the crop frame according to the specified path;
  • the image display module when the drag event of the crop frame ends, displays the image in the current crop area of the crop frame at the target position of the image display area according to the current size ratio of the image in the crop frame of the crop frame.
  • the border of the cropping frame needs to be adjusted multiple times in multiple directions. If the device provided by the sixth aspect of the embodiments of the present application is used to adjust the display position of the target image, it is possible to avoid missing the image that the user expects to retain during the image cropping process, and the desired effect can be achieved through a small number of adjustments in a few directions. Cutting efficiency, reducing the complexity of cutting operations.
  • an embodiment of the present application provides a mobile terminal, including a processor and a memory;
  • the memory is used to store programs for executing the methods described in the method embodiments of the fifth aspect; the processor is configured to execute the programs stored in the memory.
  • the border of the cropping frame needs to be adjusted multiple times in multiple directions. If the mobile terminal provided in the seventh aspect of the embodiments of the present application is used to adjust the display position of the target image, it is possible to avoid missing the screen that the user expects to retain during the image cropping process, and the desired effect can be achieved through a few adjustments in a few directions. Improve cutting efficiency and reduce the complexity of cutting operations.
  • an embodiment of the present application also provides a computer-readable storage medium that stores a program for executing the method described in each embodiment of the fifth aspect.
  • the border of the cropping frame needs to be adjusted multiple times in multiple directions. If the program stored in the computer-readable storage medium provided in the eighth aspect of the embodiments of the present application is used to adjust the display position of the target image, it is possible to avoid missing the screen that the user expects to retain during the image cropping process, and pass a few times in a few directions. The adjustment can achieve the desired effect, improve the cutting efficiency, and reduce the complexity of the cutting operation.
  • Figure 1A is an interface display diagram of the image cropping function of the mobile terminal retouching software
  • Figure 1B is another interface display diagram of the image cropping function of the mobile terminal retouching software
  • Figure 1C is another interface display diagram of the image cropping function of the mobile terminal retouching software
  • FIG. 1D is a schematic diagram of the drag direction of inward drag provided by an embodiment of the application.
  • FIG. 1E is a schematic diagram of the drag direction of the outward drag provided by an embodiment of the application.
  • FIG. 1F is a schematic diagram of each drag direction of inward drag provided by an embodiment of the application.
  • FIG. 1G is a schematic diagram of each dragging direction of the outward drag provided by an embodiment of the application.
  • FIG. 2 is a flowchart of an image cropping method provided by an embodiment of the application
  • FIG. 3A is a schematic diagram of a cutting state provided by an embodiment of this application.
  • FIG. 3B is a schematic diagram of another cutting state provided by an embodiment of this application.
  • FIG. 4A is a schematic diagram of a first cutting state according to another embodiment of the present application.
  • FIG. 4B is a schematic diagram of a second cutting state provided by another embodiment of the present application.
  • Fig. 5 is a block diagram of an image cropping device provided by an embodiment of the application.
  • Fig. 6 is a schematic structural diagram of a mobile terminal provided by an embodiment of the application.
  • FIG. 7 is a flowchart of an image cropping method provided by another embodiment of this application.
  • FIG. 8 is a flowchart of an image cropping method provided by another embodiment of this application.
  • the image display area also known as the operable area, is the maximum cropping area of the crop frame and also the maximum display area of the target image. For example, if the size of the image display area is N ⁇ M, the maximum size of the cropping frame is N ⁇ M. If the size of the target image is N ⁇ M’, and M’ is greater than M, then when the target image is displayed in the image display area, the size of the target image will be compressed to N’ ⁇ M, and N’ is less than N.
  • N, M, N', and M' are positive integers and represent the number of pixels.
  • Crop frame the crop frame is a drag control displayed in the image display area superimposed on the target image to be cropped.
  • the area enclosed by the border of the cropping frame is called the cropping area.
  • the border of the cropping box will respond to the drag event to produce corresponding deformation.
  • the embodiments of this application do not limit the shape of the frame of the cropping frame.
  • a rectangular cropping frame will be used as an example to illustrate the embodiments of this application.
  • other shapes of cropping frames such as circular shapes, can also be used. , Ellipse, triangle, polygon, irregular shape, etc.
  • the frame can be divided into four side areas and four corner areas. If you drag one of the side areas, according to the current specific scene, you can respond as follows: the opposite side area of the dragged side area is fixed, the dragged side area is translated along the dragging direction, and the dragged side area The two adjacent edge areas of the dragged edge area extend/contract along the dragging direction (depending on the scene and design, these two edge areas can also be extended/shrinked while facing or back translation, or adjacent One of the side regions of the dragged side region is moving closer to or away from the opposite side region while extending/shrinking); the side region of the dragged side region translates in the opposite direction of the dragging direction, and the dragged side region moves along the direction opposite to the dragging direction.
  • the dragging direction is shifted, and the two edge areas adjacent to the dragged edge area extend/shrink along the dragging direction (depending on the scene and design, these two edge areas can also face or face each other while extending/shrinking Backward translation, or one of the adjacent side areas is moving close to or away from the opposite side area while extending/shrinking); the whole cropping frame is translated along the dragging direction, but the size of the cropping frame remains unchanged. If you drag one of the corner areas, according to the current specific scene, you can have the following response: the diagonal area of the dragged corner area is fixed, and the dragged corner area is translated along the dragging direction and driven The adjacent edge area translates and extends/contracts.
  • the translation of the edge area drives the adjacent edge area to extend/shrink; the diagonal area of the dragged corner area translates in the opposite direction of the drag area, driving the adjacent edge Area translation and extension/contraction, the dragged corner area translates along the dragging direction, and drives the adjacent edge area to translate and extend/shrink; the entire cropping frame translates along the dragging direction, but the size of the cropping frame remains unchanged.
  • Drag direction In a rough division method, the drag direction can be divided into inward drag and outward drag.
  • the arrow direction shown in Figure 1D is the inward drag, as shown in Figure 1E.
  • the direction is to drag outward.
  • for inward dragging it can be abstracted as the eight dragging directions shown in FIG. 1F
  • for outward dragging it can be abstracted as the eight dragging directions shown in FIG. 1G.
  • the drag path that can detect the drag event that extends away from the clipping area will be dragged outwards, otherwise it will be dragged inwards.
  • the dragging direction can also be defined as required, and other methods can also be adopted to determine the dragging direction, which is not limited in the embodiment of the present application.
  • an embodiment of the present application provides an image cropping method, including:
  • Step 110 When the border of the cropping frame reaches the first target position of the image display area, and the drag event of the cropping frame continues, adjust the size of the image in the cropping area of the cropping frame.
  • the drag event of the cropping frame refers to the drag event acting on the border of the cropping frame.
  • the cropping frame and the target image to be cropped are superimposed and displayed in the image display area, and the image in the cropping area of the cropping frame is the part of the target image in the cropping area.
  • the embodiment of the present application does not define the judgment condition of "the drag event of the cropping frame continues". In actual applications, it can be determined according to the usage scenario and product design requirements. Taking a mobile terminal as an example, after the user drags the cropping frame, as long as the cropping frame is not released and the user's finger is always within the touch area of the mobile terminal, it is judged as "the drag event of the cropping frame continues"; or, the user drags After holding the cropping frame, as long as the cropping frame is not released and the user's finger is always in the image display area, it is judged as "the drag event of the cropping frame continues". Once the user's finger leaves the image display area, it is judged as the "cropping frame" The drag event ends”.
  • the embodiments of the present application do not limit the implementation of the above-mentioned situation.
  • existing implementation means can be used to determine the above-mentioned situation. For example, pre-store the coordinates of the first target position, or determine the rules of the first target position, determine the position coordinates of the border of the cropping frame in real time, and judge the position coordinates of the border and the coordinates of the first target position in real time, or judge in real time Whether the position coordinates of the frame conform to the description of the rule for the first target position, it is determined that the frame of the cropping frame reaches the first target position of the image display area.
  • Step 120 When the drag event of the cropping frame ends, according to the current size ratio of the image in the cropping area of the cropping frame, display the image in the current cropping area of the cropping frame at the second target position of the image display area.
  • the end of the drag event of the cropping frame means that the cropping frame is released.
  • the second target position may be a predetermined fixed position, or a position determined according to a predetermined rule. Regardless of whether it is a predetermined fixed position or a predetermined rule, the embodiment of the present application does not limit its specific implementation, and in actual application, it is set as required.
  • the current size ratio of the image in the crop area of the crop frame refers to the adjusted size ratio of the image when the drag event ends.
  • displaying the image according to the current size ratio of the image in the cropping area of the cropping frame refers to displaying the image according to the current size ratio, which is enlarged, reduced or the ratio is unchanged.
  • the current cropping area of the cropping frame refers to the cropping area of the cropping frame corresponding to the end of the above-mentioned drag event.
  • the image cropping method when the border of the cropping frame reaches the first target position of the image display area, for example, reaches the boundary of the image display area, if the cropping frame is not released, that is, the drag event of the cropping frame continues. Then the image cropping process can still continue, that is, in this case, the size of the image in the crop area of the crop frame can be adjusted.
  • the application that implements the method provided by the embodiment of this application will continue to adjust the size of the image to achieve
  • the purpose of continuing cropping can prevent the user from frequently dragging the cropping frame in the same way in order to achieve the desired effect, reduce the difficulty of image cropping operations, and improve the efficiency of image cropping.
  • the size of the image in the cropping area of the cropping frame is adjusted until the size of the cropping frame The drag event ends or the border of the crop box reaches the border of the target image.
  • the image in the crop area of the crop frame is a part of the target image.
  • the border of the cropping frame reaches the boundary of the target image, which can mean that a part of the border of the cropping frame (such as a certain side area or a certain corner area) reaches a part of the border of the target image (such as a certain edge or a certain edge on the border of the target image).
  • Angle it can also mean that the border of the cropping frame coincides with the border of the target image.
  • the embodiments of the present application do not limit this, and in actual applications, it can be defined according to requirements.
  • the boundary of the target image can refer to the boundary under the display size of the target image before cropping (such as N' ⁇ M), or it can refer to the original size of the target image (such as N ⁇ M'). boundary.
  • the embodiments of the present application do not limit this, and in actual applications, it can be defined according to requirements.
  • image cropping The purpose of image cropping is to retain the picture required by the user by cropping.
  • the border of the cropping frame reaches the boundary of the target image, the picture required by the user may already appear, so there is no need to continue to adjust the size of the image. Therefore, “the border of the cropping frame reaches the boundary of the target image” is preset as the cut-off condition for image size adjustment. When this cut-off condition is met, image cropping is automatically stopped to improve the quality and effect of image cropping.
  • cut-off condition may not be set for the image size adjustment during the dragging process, and other cut-off conditions may also be set according to the requirements, which is not limited in the embodiment of the application.
  • the first target position of the image display area may be any of the following positions: the border of the image display area, the position of the image display area where the border of the cropping frame reaches the set minimum size.
  • that the border of the cropping frame reaches the set minimum size means that any part of the border reaches the minimum size, for example, the length of a certain side area reaches the minimum size of its length.
  • that the border of the cropping frame reaches the set minimum size means that the crop area surrounded by the border of the cropping frame reaches the set minimum size.
  • the specific value of the minimum size is preset.
  • the first target location may also be another location, which is not limited in the embodiment of the present application. In actual applications, it is defined according to actual scenarios and/or product design requirements.
  • adjusting the image size can be different.
  • the border of the cropping frame reaches the border of the image display area, the border of the cropping frame does not coincide with the border of the target image when the drag event of the cropping frame starts, and the drag event of the cropping frame continues
  • adjusting the size of the image in the crop area of the crop frame refers to reducing the size of the image in the crop area of the crop frame.
  • the border of the cropping frame When the border of the cropping frame reaches the boundary of the image display area, the border of the cropping frame coincides with the boundary of the target image when the drag event of the cropping frame starts, and the drag event of the cropping frame continues, adjust the crop
  • the size of the image in the cropping area of the frame specifically refers to the size of the image in the cropping area of the cropping frame; when the border of the cropping frame reaches the set minimum size and the drag event of the cropping frame continues, Adjusting the size of the image in the cropping area of the cropping frame specifically refers to enlarging the size of the image in the cropping area of the cropping frame.
  • the image in the crop area of the crop frame is a part of the target image
  • the overall size of the target image is constantly shrinking.
  • the part outside the cropping area will gradually appear in the cropping area of the cropping frame. Therefore, in an implementation manner of reducing the image size, by reducing the size of the image in the crop area of the crop frame, the proportion of the image displayed in the crop area of the crop frame in the target image increases. More specifically, the display size of the image in the crop area of the crop frame can be continuously reduced, so that the proportion of the image displayed in the crop area of the crop frame in the target image continues to increase.
  • This implementation manner can show the cropping effect to the user during the image reduction process, which helps to improve the image cropping efficiency and improve the user experience.
  • image size reduction there can also be other implementations to achieve image size reduction.
  • the display size of the image in the cropping area of the cropping frame is continuously reduced, but the image content is always kept unchanged, that is, the proportion of the image in the cropping area of the cropping frame in the target image remains unchanged.
  • the image in the crop area in the crop box is not displayed according to the size parameter
  • the size is adjusted, and when the preset trigger condition is met, the image in the cropping area in the cropping frame is reduced according to the most recently adjusted size parameter, so that the proportion of the image displayed in the cropping area of the cropping frame in the target image increases.
  • the embodiment of the present application does not limit the specific implementation logic of image size adjustment. In actual applications, it can be determined according to usage scenarios and product design requirements.
  • the border of the cropping frame reaches the border of the image display area, which may mean that a part of the border of the crop frame (such as a certain side area or a certain corner area) reaches a part of the border of the image display area (such as on the border of the image display area).
  • a certain side or a certain corner of it can also mean that the border of the cropping frame coincides with the border of the image display area.
  • the embodiments of the present application do not limit this, and in actual applications, it can be defined according to requirements.
  • the border size of the cropping frame can also be adjusted, which is not limited in the embodiment of the present application.
  • the border size adjustment logic of the cropping frame is determined according to the use scenario and product design requirements.
  • the cropping area of the cropping frame can be continuously adjusted
  • the current size ratio of the image in the cropping area of the cropping frame is determined according to the current display size.
  • the effect of image cropping can be previewed in real time, which helps to improve the efficiency of image cropping.
  • the size parameter of the image in the crop area of the crop frame can also be adjusted.
  • the current size ratio of the image in the crop area of the crop frame is determined according to the size parameter at the end of the drag event of the crop frame.
  • the image cropping effect cannot be previewed in real time during the image cropping process, since the size parameters of the image are recorded, the image cropping result can be accurately displayed after the drag event ends.
  • the display size of the image refers to the size of the image displayed in the image display area, and the display size of the image is continuously adjusted, that is, the adjustment result of the image size is previewed in real time.
  • the image size parameter refers to the parameter stored in the memory, which determines the display size of the image. Adjust the image size parameter, that is, you do not need to preview the image size adjustment result in real time, and only adjust the size parameter in the memory. When the adjustment result needs to be displayed, the image is displayed according to the last adjusted size parameter.
  • the image size adjustment speed may be determined according to the parameters of the drag event of the crop frame, and the size of the image in the crop area of the crop frame can be adjusted according to the image adjustment speed.
  • the inventor found through analyzing the user's usage habits that certain drag habits of the user when dragging the cropping frame reflect his expectation for the speed of image size adjustment. These drag habits will be reflected in the parameters of the drag event. Therefore, the image adjustment speed is determined according to the parameters of the drag event, and the drag operation can be controlled to meet or be close to the user's expectation of the image size adjustment speed.
  • the parameters of the drag event of the cropping frame may include the drag distance, and the larger the drag distance, the greater the image size adjustment speed.
  • the parameters of the drag event of the cropping frame may also include touch pressure, number of touch points, and so on.
  • the embodiment of the present application does not limit the specific control logic of the image size adjustment speed. In actual applications, it can be determined according to the usage scenario and product design requirements. Taking the drag distance as an example, the image adjustment speed can be determined in real time. In each determination period, the image adjustment speed is determined according to the linear distance of the drag in the determination period. There is a predetermined functional relationship between the drag distance and the image adjustment speed. If the drag distance is 0, the image drag speed is a fixed value, and the customization can be a predetermined value or a value determined in real time for the last time.
  • the inventor found through analyzing the user’s usage habits that when the user drags the cropping frame, the greater the drag amplitude, that is, the greater the drag distance of the drag event, which represents the image size desired by the user. The faster the adjustment speed. Therefore, determining the image size adjustment speed according to the drag distance meets the user's expectation.
  • the method provided in the embodiments of this application can also adjust the display position of the target image when the drag event of the cropping frame continues, so that the center of the target image is always aligned with the center of the cropping frame.
  • the center of the cropping area coincides, or the center of the target image is approached to the center of the cropping area of the cropping frame according to the specified path.
  • the drag event continues, but the border of the crop box reaches the image
  • the display position of the image is adjusted according to other adjustment logic or the display position of the target image is no longer adjusted. It is also possible to adjust the display position of the image according to the above adjustment logic during the entire duration of the drag event.
  • the embodiment of the present application does not limit the specific realization means for adjusting the display position of the target image, and can be realized by using existing technical means.
  • the coordinate value of the center point of the cropping area of the cropping frame can be obtained in real time, and the coordinate value can be assigned to the center point of the target image. After adjusting the coordinate value of the center point of the target image to its display position.
  • the designated path may be predetermined or calculated according to predetermined rules.
  • the target image can also be moved according to the image adjustment speed determined above.
  • the border of the cropping frame needs to be adjusted multiple times in multiple directions. If the display position of the target image is adjusted according to the above method, it is possible to avoid missing the image that the user expects to keep during the image cropping process. The expected effect can be achieved through a small number of adjustments in a few directions, and the cropping efficiency can be improved.
  • the target image 102 and the cropping frame 103 are superimposed and displayed on the image display area 101 of the display screen 100 of the mobile terminal.
  • the border of the cropping frame 103 coincides with the border of the target image 102.
  • the image cropping ratio is not limited, which means that the border ratio of the cropping frame can be changed arbitrarily within the image display area.
  • the first drag method of cropping frame based on the first image cropping mode drag the cropping frame inward.
  • the width of the cropping frame is adjusted according to the dragging distance
  • the length of the cropping frame is adjusted according to the dragging distance. If the dragged border area is a corner area, adjust the length and width of the cropping frame in proportion to the drag distance.
  • the size of the cropping frame will be changed.
  • the display size and display position of the target image may not be adjusted, or the display size of the target image may not be adjusted, but adjusted
  • the display position of the target image and the adjustment method refer to the description of the above-mentioned embodiment.
  • the size of the cropping frame does not continue to change. At this time, if the drag event continues, then enlarge the size of the image in the crop box to continue image cropping.
  • the size of the target image can also be enlarged as a whole to achieve an enlarged cropping frame. The purpose of the image size in.
  • the center of the image in the cropping frame is always kept at the center of the cropping frame.
  • the image boundary corresponding to the drag event is fixed and the image is enlarged.
  • the basis for performing the zooming operation on the image is that the drag event always continues, and the dragging direction is inward dragging.
  • the image is enlarged at a constant speed. If the user's finger keeps dragging the cropping frame and the drag position changes, then the real-time image adjustment speed is calculated according to the real-time drag distance, and the image is enlarged in real time according to the real-time determined image adjustment speed.
  • the initial state is shown in Figure 1C.
  • the dragged frame area is the long-side area
  • the width of the cropping frame is adjusted according to the drag distance
  • the length of the cropping frame is adjusted according to the dragging distance. If the dragged border area is a corner area, adjust the length and width of the cropping frame in proportion to the drag distance.
  • the size of the cropping frame will be changed.
  • the display size and display position of the target image may not be adjusted, or the display size of the target image may not be adjusted, but adjusted
  • the display position of the target image and the adjustment method refer to the description of the above-mentioned embodiment.
  • the size of the cropping frame does not continue to change. At this time, if the drag event continues, then reduce the size of the image in the crop box to continue image cropping.
  • the size of the target image can be reduced as a whole to achieve the purpose of reducing the size of the image in the cropping frame until the border of the cropping frame coincides with the boundary of the target image.
  • the right border of the cropping frame 103 coincides with the right border of the target image, but the left border of the cropping frame 103 If it does not coincide with the left border of the target image, if the drag event continues, the target image will continue to be reduced until the left border of the cropping frame 103 coincides with the left border of the target image.
  • the border size of the cropping frame can be adjusted according to a preset rule until it coincides with the border of the target image.
  • This application does not limit the preset rules. In actual applications, it is determined according to the usage scenarios and product design requirements.
  • the left border of the image in the cropping frame is always kept to coincide with the left border of the cropping frame.
  • the image boundary corresponding to the drag event is fixed and the image is reduced.
  • the center of the target image is always kept at the center of the crop frame, and for example, the target image The center of is continuously close to the center of the cropping frame.
  • the basis for performing the shrinking operation on the image is that the drag event always continues, and the dragging direction is outward drag.
  • the image is reduced at a constant speed. If the user's finger keeps dragging the cropping frame and the drag position changes, the real-time image adjustment speed is calculated according to the real-time drag distance, and the image is reduced in real time according to the real-time determined image adjustment speed.
  • the user drags the cropping frame outwards.
  • the initial state is shown in Figure 1A.
  • the left and right borders of the cropping frame have reached the left and right borders of the image display interface.
  • specifying the image cropping ratio means that the frame ratio of the cropping frame remains unchanged in the image display area, and the image is scaled according to the specified ratio.
  • the cropping implementation process corresponding to each cropping frame drag mode in this image cropping mode can refer to the corresponding process under the first image cropping mode, which will not be repeated here. The only difference is that the image is always maintained during the zooming process.
  • the specified ratio is the specified ratio.
  • an embodiment of the present application provides an image cropping device, as shown in FIG. 5, including:
  • the image adjustment module 501 is configured to adjust the size of the image in the crop area of the crop frame when the border of the crop frame reaches the first target position of the image display area and the drag event of the crop frame continues;
  • the image display module 502 is configured to display the current cropping area of the cropping frame at the second target position of the image display area according to the current size ratio of the image in the cropping area of the cropping frame when the drag event of the cropping frame is ended. Inside the image.
  • the image cropping device provided by the embodiment of the present application, when the border of the cropping frame reaches the first target position of the image display area, for example, when the border of the image display area is reached, if the cropping frame is not released, that is, the drag event of the cropping frame continues. Then the image cropping process can still continue, that is, in this case, the size of the image in the crop area of the crop frame can be adjusted.
  • the application of the device provided by the embodiment of the present application will continue to adjust the size of the image to achieve
  • the purpose of continuing cropping can prevent the user from frequently dragging the cropping frame in the same way in order to achieve the desired effect, reduce the difficulty of image cropping operations, and improve the efficiency of image cropping.
  • the image adjustment module adjusts the size of the image in the cropping area of the cropping frame when the border of the cropping frame reaches the first target position of the image display area and the drag event of the cropping frame continues until the The drag event of the cropping box ends or the border of the cropping box reaches the boundary of the target image.
  • the image in the crop area of the crop frame is a part of the target image.
  • image cropping is to retain the picture that the user needs by cropping.
  • the border of the cropping frame reaches the boundary of the target image, the picture that the user needs may have appeared, so there is no need to continue to adjust the image. size of. Therefore, “the border of the cropping frame reaches the boundary of the target image” is preset as the cut-off condition for image size adjustment. When this cut-off condition is met, image cropping is automatically stopped to improve the quality and effect of image cropping.
  • the first target position of the image display area may be any of the following positions: the border of the image display area, and the position of the image display area where the border of the cropping frame reaches the set minimum size.
  • the device provided by the embodiment of the present application can still continue to perform image cropping when the border of the cropping frame reaches the boundary of the image display area; in addition, when the border of the cropping frame reaches the set minimum size, the image can still be continued. Cropped.
  • adjusting the size of the image in the cropping area of the cropping frame refers to reducing the size of the image in the cropping area of the cropping frame; when the border of the cropping frame reaches the boundary of the image display area, when the drag event of the cropping frame starts When the border of the cropping frame coincides with the boundary of the target image, and the drag event of the cropping frame continues, adjusting the size of the image in the cropping area of the cropping frame specifically refers to zooming in on the cropping area of the cropping frame.
  • adjusting the size of the image in the cropping area of the cropping frame specifically refers to enlarging the cropping of the cropping frame The size of the image in the area.
  • the image adjustment module can continuously adjust the size of the cropping frame.
  • the display size of the image in the crop area correspondingly, the current size ratio of the image in the crop area of the crop frame is determined according to the current display size.
  • the image adjustment module can also adjust the size parameters of the image in the crop area of the crop frame.
  • the current size ratio of the image in the crop area of the crop frame is based on the size parameter at the end of the drag event of the crop frame. definite.
  • the image cropping effect cannot be previewed in real time during the image cropping process, since the size parameters of the image are recorded, the image cropping result can be accurately displayed after the drag event ends.
  • the image size adjustment speed can be determined according to the parameters of the drag event of the crop frame, and the size of the image in the crop area of the crop frame can be adjusted according to the image adjustment speed.
  • the inventor found through analyzing the user's usage habits that certain drag habits of the user when dragging the cropping frame reflect his expectation for the speed of image size adjustment. These drag habits will be reflected in the parameters of the drag event. Therefore, the image adjustment speed is determined according to the parameters of the drag event, and the drag operation can be controlled to meet or be close to the user's expectation of the image size adjustment speed.
  • the parameters of the drag event of the cropping frame may include the drag distance, and the larger the drag distance, the greater the image size adjustment speed.
  • the inventor found through analyzing the user’s usage habits that when the user drags the cropping frame, the greater the drag amplitude, that is, the greater the drag distance of the drag event, which represents the image size desired by the user. The faster the adjustment speed. Therefore, determining the image size adjustment speed according to the drag distance meets the user's expectation.
  • the image adjustment module can also adjust the display position of the image in the crop area of the crop frame when the drag event of the crop frame continues, so that the center of the target image is always aligned with the crop.
  • the center of the cropping area of the frame coincides, or the center of the target image is approached to the center of the cropping area of the cropping frame according to a specified path.
  • the border of the cropping frame needs to be adjusted multiple times in multiple directions. If the display position of the target image is adjusted in the above manner, it is possible to avoid missing the image that the user expects to retain during the image cropping process, and the desired effect can be achieved through a small number of adjustments in a few directions, and the cropping efficiency can be improved.
  • an embodiment of the present application also provides a mobile terminal, as shown in FIG. 6, including a processor and a memory;
  • the memory is used to store programs for executing the methods described in the foregoing method embodiments; the processor is configured to execute the programs stored in the memory.
  • the border of the cropping frame reaches the first target position of the image display area, for example, the border of the image display area is reached. If the cropping frame is not released, that is, the drag event of the cropping frame continues, then The image cropping process can still continue, that is, in this case, the size of the image in the crop area of the crop frame can be adjusted. Therefore, with the mobile terminal provided by the embodiment of the present application, when the user drags the cropping frame to the border of the image display area, as long as the cropping frame is not released, the program executed by the terminal processor provided by the embodiment of the present application will continue to adjust the image. The size of, to achieve the purpose of continuous cropping, which can avoid the user from frequently dragging the cropping frame in the same way in order to achieve the desired effect, reducing the difficulty of image cropping operation, and improving the efficiency of image cropping.
  • the mobile terminal provided by the embodiment of the present application further includes input devices (such as touch screens, cameras, microphones, etc.), output devices (such as display screens, speakers, etc.), communication modules, and power supply modules.
  • input devices such as touch screens, cameras, microphones, etc.
  • output devices such as display screens, speakers, etc.
  • communication modules such as communication modules, and power supply modules.
  • the memory, input device, output device, communication module, and power module are connected to the processor through a serial port, a bus, or a USB interface.
  • the processor is the CPU (central processing unit); for a dual-processor mobile terminal, the processor includes a main processor and a slave processor, and the main processor executes application programs to implement the embodiments of the present invention
  • the provided method if it needs to communicate with the outside world, is implemented by the slave processor control communication module; for mobile terminals that include GPU (graphics processing unit) and CPU, the processor refers to the GPU and the CPU, which is coordinated by the GPU and the CPU. Or the CPU alone implements the method provided in the embodiment of this application.
  • an embodiment of the present application also provides a computer-readable storage medium storing a program for executing the method described in each of the foregoing embodiments.
  • the program stored in the computer-readable storage medium provided by the embodiment of the application reaches the first target position of the image display area when the border of the cropping frame reaches the first target position of the image display area, for example, reaches the border of the image display area. If the cropping frame is not released, the cropping frame If the drag event continues, the image cropping process can still continue, that is, in this case, the size of the image in the cropping area of the cropping frame can be adjusted. Therefore, using the program saved in the computer-readable storage medium provided by the embodiment of the present application, when the user drags the cropping frame to the border of the image display area, as long as the cropping frame is not released, the program will continue to adjust the size of the image to continue cropping. The purpose of this can prevent users from frequently dragging the cropping frame in the same way in order to achieve the desired effect, reduce the difficulty of image cropping operations, and improve the efficiency of image cropping.
  • an embodiment of the present application provides an image cropping method, including:
  • Step 710 When a drag event of the crop frame is detected, during the drag event of the crop frame, adjust the display position of the target image so that the center of the target image always coincides with the center of the crop area of the crop frame;
  • Step 720 When the drag event of the cropping frame ends, display the image in the current cropping area of the cropping frame at the target position of the image display area according to the current size ratio of the image in the cropping area of the cropping frame.
  • an embodiment of the present application provides an image cropping method, including:
  • Step 810 When a drag event of the crop frame is detected, during the drag event of the crop frame, adjust the display position of the target image so that the center of the target image approaches the center of the crop area of the crop frame according to the specified path.
  • Step 820 When the drag event of the cropping frame ends, the image in the current cropping area of the cropping frame is displayed at the target position of the image display area according to the current size ratio of the image in the cropping area of the cropping frame.
  • the border of the cropping frame needs to be adjusted multiple times in multiple directions. If the display position of the target image is adjusted according to the method provided by the fifth aspect of the embodiment of the present application, it is possible to avoid missing the image that the user expects to retain during the image cropping process, and the desired effect can be achieved through a small number of adjustments in a few directions. Cutting efficiency, reducing the complexity of cutting operations.
  • an embodiment of the present application provides an image cropping device, including:
  • the image adjustment module when the drag event of the cropping frame is detected, adjusts the display position of the image in the cropping area of the cropping frame during the drag event of the cropping frame, so that the center of the target image is always aligned with the center of the cropping frame.
  • the center of the cropped area coincides;
  • the image display module when the drag event of the cropping frame ends, displays the image in the current cropping area of the cropping frame at the target position of the image display area according to the current size ratio of the image in the cropping area of the cropping frame.
  • an embodiment of the present application provides an image cropping device, including:
  • the image adjustment module when a drag event of the cropping frame is detected, adjusts the display position of the image in the crop area of the cropping frame during the drag event of the cropping frame, so that the center of the target image is cropped according to the specified path The center of the cropped area of the frame is close;
  • the image display module when the drag event of the crop frame ends, displays the image in the current crop area of the crop frame at the target position of the image display area according to the current size ratio of the image in the crop frame of the crop frame.
  • the border of the cropping frame needs to be adjusted multiple times in multiple directions. If the device provided by the sixth aspect of the embodiments of the present application is used to adjust the display position of the target image, it is possible to avoid missing the image that the user expects to retain during the image cropping process, and the desired effect can be achieved through a small number of adjustments in a few directions. Cutting efficiency, reducing the complexity of cutting operations.
  • an embodiment of the present application provides a mobile terminal including a processor and a memory
  • the memory is used to store a program for executing the method shown in FIG. 7 or FIG. 8; the processor is configured to execute the program stored in the memory.
  • the border of the cropping frame needs to be adjusted multiple times in multiple directions. If the mobile terminal provided in the seventh aspect of the embodiments of the present application is used to adjust the display position of the target image, it is possible to avoid missing the screen that the user expects to retain during the image cropping process, and the desired effect can be achieved through a few adjustments in a few directions. Improve cutting efficiency and reduce the complexity of cutting operations.
  • an embodiment of the present application also provides a computer-readable storage medium storing a program for executing the method shown in FIG. 7 or FIG. 8.
  • the border of the cropping frame needs to be adjusted multiple times in multiple directions. If the program stored in the computer-readable storage medium provided in the eighth aspect of the embodiments of the present application is used to adjust the display position of the target image, it is possible to avoid missing the screen that the user expects to retain during the image cropping process, and pass a few times in a few directions. The adjustment can achieve the desired effect, improve the cutting efficiency, and reduce the complexity of the cutting operation.
  • These computer program instructions can also be stored in a computer-readable memory that can guide a computer or other programmable data processing equipment to work in a specific manner, so that the instructions stored in the computer-readable memory produce an article of manufacture including the instruction device.
  • the device implements the functions specified in one process or multiple processes in the flowchart and/or one block or multiple blocks in the block diagram.
  • These computer program instructions can also be loaded on a computer or other programmable data processing equipment, so that a series of operation steps are executed on the computer or other programmable equipment to produce computer-implemented processing, so as to execute on the computer or other programmable equipment.
  • the instructions provide steps for implementing the functions specified in one process or multiple processes in the flowchart and/or one block or multiple blocks in the block diagram.

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • Computer Vision & Pattern Recognition (AREA)
  • Human Computer Interaction (AREA)
  • User Interface Of Digital Computer (AREA)
  • Controls And Circuits For Display Device (AREA)
  • Image Processing (AREA)
  • Packaging Of Special Articles (AREA)
  • Studio Devices (AREA)
PCT/CN2021/076687 2020-02-24 2021-02-18 图像裁剪方法、装置、设备及存储介质 Ceased WO2021169827A1 (zh)

Priority Applications (6)

Application Number Priority Date Filing Date Title
JP2022549256A JP7513731B2 (ja) 2020-02-24 2021-02-18 画像カッティング方法、装置、設備及び記憶媒体
KR1020227027005A KR102949430B1 (ko) 2020-02-24 2021-02-18 화상 커팅 방법, 장치, 설비 및 기억 매체
EP21761230.8A EP4113438B1 (en) 2020-02-24 2021-02-18 IMAGE CROPING METHOD AND APPARATUS, AS WELL AS STORAGE DEVICE AND MEDIA
AU2021225277A AU2021225277B2 (en) 2020-02-24 2021-02-18 Image cropping method and apparatus, and device and storage medium
US17/877,711 US12008684B2 (en) 2020-02-24 2022-07-29 Image cropping method and apparatus, and device and storage medium
US18/662,656 US20240296598A1 (en) 2020-02-24 2024-05-13 Image cropping method and apparatus, and device and storage medium

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN202010113486.5 2020-02-24
CN202010113486.5A CN111275726B (zh) 2020-02-24 2020-02-24 图像裁剪方法、装置、设备及存储介质

Related Child Applications (1)

Application Number Title Priority Date Filing Date
US17/877,711 Continuation US12008684B2 (en) 2020-02-24 2022-07-29 Image cropping method and apparatus, and device and storage medium

Publications (1)

Publication Number Publication Date
WO2021169827A1 true WO2021169827A1 (zh) 2021-09-02

Family

ID=71003670

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2021/076687 Ceased WO2021169827A1 (zh) 2020-02-24 2021-02-18 图像裁剪方法、装置、设备及存储介质

Country Status (7)

Country Link
US (2) US12008684B2 (https=)
EP (1) EP4113438B1 (https=)
JP (1) JP7513731B2 (https=)
KR (1) KR102949430B1 (https=)
CN (1) CN111275726B (https=)
AU (1) AU2021225277B2 (https=)
WO (1) WO2021169827A1 (https=)

Families Citing this family (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111275726B (zh) 2020-02-24 2021-02-05 北京字节跳动网络技术有限公司 图像裁剪方法、装置、设备及存储介质
CN112541919B (zh) * 2020-12-29 2024-09-17 申建常 一种图片分割处理方法及处理系统
CN114004845A (zh) * 2021-10-28 2022-02-01 网易(杭州)网络有限公司 一种图片编辑方法、电子设备和存储介质
CN116095249B (zh) * 2022-05-30 2023-10-20 荣耀终端有限公司 视频处理方法及电子设备
CN115567737B (zh) * 2022-09-21 2023-05-16 飞狐信息技术(天津)有限公司 一种裁取后图片替换方法及装置

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104991725A (zh) * 2015-07-28 2015-10-21 北京金山安全软件有限公司 一种图片裁剪的方法和系统
CN105205780A (zh) * 2015-10-19 2015-12-30 新华瑞德(北京)网络科技有限公司 图片裁剪方法和装置
US10101891B1 (en) * 2015-03-27 2018-10-16 Google Llc Computer-assisted image cropping
CN111275726A (zh) * 2020-02-24 2020-06-12 北京字节跳动网络技术有限公司 图像裁剪方法、装置、设备及存储介质

Family Cites Families (19)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2004163735A (ja) * 2002-11-14 2004-06-10 Canon Inc 画像処理装置及び方法、並びに画像処理プログラム及び記憶媒体
US7743348B2 (en) * 2004-06-30 2010-06-22 Microsoft Corporation Using physical objects to adjust attributes of an interactive display application
JP2006262287A (ja) * 2005-03-18 2006-09-28 Konica Minolta Photo Imaging Inc 画像処理装置、プログラム及び記録媒体
US8774767B2 (en) * 2007-07-19 2014-07-08 Samsung Electronics Co., Ltd. Method and apparatus for providing phonebook using image in a portable terminal
US20120054190A1 (en) * 2010-08-27 2012-03-01 Aiv Technology Llc Electronic family tree generation and display system
US9389774B2 (en) * 2010-12-01 2016-07-12 Sony Corporation Display processing apparatus for performing image magnification based on face detection
CN102646258B (zh) * 2011-02-21 2016-01-06 腾讯科技(深圳)有限公司 图像裁剪方法及系统
US20130009997A1 (en) * 2011-07-05 2013-01-10 Research In Motion Limited Pinch-to-zoom video apparatus and associated method
US9158455B2 (en) * 2011-07-12 2015-10-13 Apple Inc. Multifunctional environment for image cropping
US20130198610A1 (en) * 2012-01-20 2013-08-01 Vistaprint Limited Defining external website content sources
JP2014007653A (ja) * 2012-06-26 2014-01-16 Jvc Kenwood Corp 撮像装置、撮像方法、撮像システム及びプログラム
JP6116167B2 (ja) * 2012-09-14 2017-04-19 キヤノン株式会社 画像処理装置、画像処理方法、およびプログラム
CN104463780A (zh) * 2014-12-23 2015-03-25 深圳供电局有限公司 一种移动终端上图片裁剪的方法及装置
CN105989572B (zh) * 2015-02-10 2020-04-24 腾讯科技(深圳)有限公司 图片处理方法及装置
JP6432449B2 (ja) * 2015-06-02 2018-12-05 コニカミノルタ株式会社 情報処理装置、情報処理プログラム、及び情報処理方法
US10353569B2 (en) * 2015-06-24 2019-07-16 Htc Corporation Crop frame adjusting method, image processing device, and non-transitory computer readable storage medium
US9917957B1 (en) * 2016-11-17 2018-03-13 Xerox Corporation Cropping image within image preview
CN109447072A (zh) * 2018-11-08 2019-03-08 北京金山安全软件有限公司 一种缩略图裁剪方法、装置、电子设备及可读存储介质
CN110706150A (zh) * 2019-07-12 2020-01-17 北京达佳互联信息技术有限公司 图像处理方法、装置、电子设备及存储介质

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US10101891B1 (en) * 2015-03-27 2018-10-16 Google Llc Computer-assisted image cropping
CN104991725A (zh) * 2015-07-28 2015-10-21 北京金山安全软件有限公司 一种图片裁剪的方法和系统
CN105205780A (zh) * 2015-10-19 2015-12-30 新华瑞德(北京)网络科技有限公司 图片裁剪方法和装置
CN111275726A (zh) * 2020-02-24 2020-06-12 北京字节跳动网络技术有限公司 图像裁剪方法、装置、设备及存储介质

Non-Patent Citations (2)

* Cited by examiner, † Cited by third party
Title
ANONYMOUS: "iPhone tricks teach you to hide private photos instantly", IT DIGITAL SCROLL IN NEWS, SOHU NEWS [ONLINE], 9 June 2013 (2013-06-09), XP055840998, Retrieved from the Internet <URL:http://roll.sohu.com/20130609/n378466995.shtml> *
See also references of EP4113438A4 *

Also Published As

Publication number Publication date
US20240296598A1 (en) 2024-09-05
AU2021225277B2 (en) 2024-04-18
KR20220123113A (ko) 2022-09-05
EP4113438A4 (en) 2023-08-23
EP4113438B1 (en) 2025-12-31
EP4113438A1 (en) 2023-01-04
KR102949430B1 (ko) 2026-04-06
JP7513731B2 (ja) 2024-07-09
US12008684B2 (en) 2024-06-11
EP4113438C0 (en) 2025-12-31
AU2021225277A1 (en) 2022-09-08
JP2023513382A (ja) 2023-03-30
US20220366617A1 (en) 2022-11-17
CN111275726A (zh) 2020-06-12
CN111275726B (zh) 2021-02-05

Similar Documents

Publication Publication Date Title
WO2021169827A1 (zh) 图像裁剪方法、装置、设备及存储介质
US20180011818A1 (en) Webpage Update Method And Apparatus
CN107977934B (zh) 图像处理方法及装置
CN108304132B (zh) 图形显示方法、装置、设备及存储介质
JP2023513382A5 (https=)
WO2017088605A1 (zh) 图片编辑中的图片显示控制方法及装置
WO2023207145A1 (zh) 截屏方法、装置、电子设备及计算机可读介质
CN109753333B (zh) 一种界面布局方法、装置、设备及介质
JP2015523649A (ja) 画像表示処理方法、画像表示処理装置、プログラム、及び記録媒体
US20180152622A1 (en) Mobile terminal-based photographing method and mobile terminal
CN104134186A (zh) 图像处理装置、图像处理方法和程序
CN111638849A (zh) 截图方法、装置及电子设备
CN110209325A (zh) 一种3d场景显示控制方法、系统及设备
CN105654531A (zh) 一种图像轮廓的绘制方法及装置
JP7466689B2 (ja) 画像表示方法、装置、機器及び記憶媒体
TWI501139B (zh) 影像裁剪方法以及其可攜式電子裝置
WO2025241628A1 (zh) 图像与视频处理方法、设备、存储介质及程序产品
CN111448534B (zh) 终端设备及其图形用户界面以及图形用户界面的控制方法
CN115665347B (zh) 视频裁剪方法、装置、电子设备及存储介质
WO2020052374A1 (zh) 一种截图方法和装置
CN110647263A (zh) 一种移动终端桌面图标移动方法、装置、介质和设备
CN112396669B (zh) 图片处理方法、装置及电子设备
CN113592983A (zh) 一种图像处理方法、装置及计算机可读存储介质
US12148117B2 (en) Control method and device for displaying 3D images
CN107895388A (zh) 图形的颜色填充方法、装置、计算机设备及存储介质

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 21761230

Country of ref document: EP

Kind code of ref document: A1

ENP Entry into the national phase

Ref document number: 20227027005

Country of ref document: KR

Kind code of ref document: A

ENP Entry into the national phase

Ref document number: 2022549256

Country of ref document: JP

Kind code of ref document: A

ENP Entry into the national phase

Ref document number: 2021225277

Country of ref document: AU

Date of ref document: 20210218

Kind code of ref document: A

NENP Non-entry into the national phase

Ref country code: DE

ENP Entry into the national phase

Ref document number: 2021761230

Country of ref document: EP

Effective date: 20220926

WWG Wipo information: grant in national office

Ref document number: 2021761230

Country of ref document: EP