Method and apparatus for adsorbing straight line/line segment, method and apparatus for constructing polygon
First Claim
1. A method for performing a frame detection operation in an image for image recognition, comprising:
- providing, by a device comprising a processor and a screen, the image on which the frame detection operation is to be performed;
detecting, by the device, a line segment in the image;
displaying, by the device, a target frame enclosed by preset straight line/line segment of the image on the screen;
dragging, by the device, the straight line/line segment when detecting that a user performs a dragging operation on the screen to further define the target frame, the dragging operation indicating a first part of the straight line/line segment is selected and moved, andwhen a second part of the straight line/line segment is within a preset distance from the detected line segment in the image, superposing the preset straight line/line segment with the detected line segment on the screen to finalize the target frame for image recognition on the target frame.
1 Assignment
0 Petitions
Accused Products
Abstract
The present invention discloses a method for adsorbing a straight line/line segment in an image, including: presetting a straight line/line segment, dragging the straight line/line segment by selecting a first part of the line segment, and when a second part of the straight line/line segment is dragged to the vicinity of a line segment in an image, setting the preset line segment to be superposed with the line segment, the vicinity referring to that a minimum distance between the second part of the straight line/line segment and the line segment meets a preset rule. In the present invention, by means of the foregoing technical solution, a user can be conveniently assisted, according to a line segment that exists in an image, to define a polygon frame, so that subsequent image processing can be conveniently performed.
-
Citations
13 Claims
-
1. A method for performing a frame detection operation in an image for image recognition, comprising:
-
providing, by a device comprising a processor and a screen, the image on which the frame detection operation is to be performed; detecting, by the device, a line segment in the image; displaying, by the device, a target frame enclosed by preset straight line/line segment of the image on the screen; dragging, by the device, the straight line/line segment when detecting that a user performs a dragging operation on the screen to further define the target frame, the dragging operation indicating a first part of the straight line/line segment is selected and moved, and when a second part of the straight line/line segment is within a preset distance from the detected line segment in the image, superposing the preset straight line/line segment with the detected line segment on the screen to finalize the target frame for image recognition on the target frame. - View Dependent Claims (2, 3, 4, 13)
-
-
5. A method for performing a frame detection operation in an image, comprising:
-
providing, by a device comprising a processor and a screen, the image on which the frame detection operation is to be performed; detecting, by the device, a line segment in the image; displaying, by the device, a target frame enclosed by preset straight line/line segment of the image on the screen; dragging, by the device, the straight line/line segment by selecting a first part of the straight line/line segment when detecting that a user performs a dragging operation on the screen to further define the target frame, the dragging operation indicating the first part of the straight line/line segment, and when dragging ends, a second part of the straight line/line segment is within a preset distance from a corresponding second part of the detected line segment in the image, superposing the preset straight line/line segment with the detected line segment on the screen to finalize the target frame for image recognition on the target frame. - View Dependent Claims (6, 7, 8)
-
-
9. An apparatus for performing a frame detection operation in an image, comprising:
-
a processor and a screen, wherein the processor is configured to provide the image on which the frame detection operation is to be performed; detect a line segment in the image; instruct the screen to display a target frame enclosed by preset straight line/line segment of the image on the screen; drag the straight line/line segment when detecting that a user performs a dragging operation on the screen to further define the target frame, the dragging operation indicating a first part of the straight line/line segment is selected and moved, and when a second part of the straight line/line segment is within a preset distance from the detected line segment in the image, superpose the preset straight line/line segment with the detected line segment on the screen to finalize the target frame for image recognition on the target frame. - View Dependent Claims (10, 11, 12)
-
Specification