CN107464215B - Image processing method and terminal based on electronic map - Google Patents

Image processing method and terminal based on electronic map Download PDF

Info

Publication number
CN107464215B
CN107464215B CN201710643701.0A CN201710643701A CN107464215B CN 107464215 B CN107464215 B CN 107464215B CN 201710643701 A CN201710643701 A CN 201710643701A CN 107464215 B CN107464215 B CN 107464215B
Authority
CN
China
Prior art keywords
route
segmented
segment
planned route
routes
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.)
Active
Application number
CN201710643701.0A
Other languages
Chinese (zh)
Other versions
CN107464215A (en
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.)
Nubia Technology Co Ltd
Original Assignee
Nubia 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 Nubia Technology Co Ltd filed Critical Nubia Technology Co Ltd
Priority to CN201710643701.0A priority Critical patent/CN107464215B/en
Publication of CN107464215A publication Critical patent/CN107464215A/en
Application granted granted Critical
Publication of CN107464215B publication Critical patent/CN107464215B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR 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
    • G06T3/4038Image mosaicing, e.g. composing plane images from plane sub-images

Landscapes

  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Processing Or Creating Images (AREA)
  • Navigation (AREA)

Abstract

The embodiment of the invention discloses an image processing method and a terminal based on an electronic map, wherein the method comprises the following steps: after a planned route is determined on an electronic map, segmenting the planned route to obtain each segmented route; screenshot is carried out on each obtained subsection route to obtain an image corresponding to each subsection route; sequentially splicing the images corresponding to the segmented routes according to the predetermined sequence of the segmented routes to obtain spliced images; wherein the predetermined sequence of the respective segmented routes is consistent with the sequence of the planned route from the starting point to the end point, or consistent with the sequence of the planned route from the end point to the starting point; therefore, the screenshot is only carried out aiming at the area nearby the planned route, and the actual application requirements are further met.

Description

Image processing method and terminal based on electronic map
Technical Field
The present invention relates to image processing technologies, and in particular, to an image processing method and a terminal based on an electronic map.
Background
At present, when the screenshot is carried out on the image displayed by the terminal, the screenshot is carried out by expanding in a longitudinal direction or a transverse direction; for map application for displaying an electronic map on a terminal, after a planned route is planned, if a screen capture is required to be performed on a region near the planned route, due to the randomness and irregularity of the planned route, when the screen capture is performed according to the existing method, the obtained screen capture region probably contains details which do not need to be obtained, so that the existing method for performing screen capture on the planned route cannot well meet the actual requirements.
Disclosure of Invention
In order to solve the technical problem, embodiments of the present invention provide an image processing method and a terminal based on an electronic map, which can only perform screenshot for a nearby area of a planned route, thereby meeting the requirements of practical applications.
In order to achieve the above purpose, the technical solution of the embodiment of the present invention is realized as follows:
the embodiment of the invention provides an image processing method based on an electronic map, which comprises the following steps:
after the planned route is determined on the electronic map, segmenting the planned route to obtain each segmented route;
screenshot is carried out on each obtained subsection route to obtain an image corresponding to each subsection route;
sequentially splicing the images corresponding to the segmented routes according to the predetermined sequence of the segmented routes to obtain spliced images; wherein the predetermined sequence of the respective segment routes is consistent with the sequence of the planned route from the starting point to the end point, or the sequence of the planned route from the end point to the starting point.
Optionally, after determining the planned route on the electronic map, before segmenting the planned route, the method further includes:
and controlling and adjusting the scale of the electronic map to enable the scale of the electronic map to be larger than a set scale threshold value.
Optionally, the shape of the screenshot area for screenshot the ith segmentation route is parallelogram, circle or ellipse, i is 1 to n, and n represents the number of the obtained segmentation routes.
Optionally, the obtained ith segmentation route is a line segment;
when the shape of the screenshot area is a parallelogram, the ith segmentation route is a midpoint connecting line of any group of opposite sides of the parallelogram or any diagonal line of the parallelogram;
when the shape of the screenshot area is a circle, the ith segmentation route is the central line of the circle;
when the shape of the screenshot area is an ellipse, the ith segmentation route is a long axis or a short axis of the ellipse.
Optionally, the area of the image corresponding to each obtained segment route is smaller than the set area threshold.
An embodiment of the present invention further provides a terminal, where the terminal includes: a memory, a processor and a computer program stored on the memory and executable on the processor, the computer program when executed by the processor implementing the steps of:
after a planned route is determined on an electronic map displayed by a terminal, segmenting the planned route to obtain each segmented route;
screenshot is carried out on each obtained subsection route to obtain an image corresponding to each subsection route;
sequentially splicing the images corresponding to the segmented routes according to the predetermined sequence of the segmented routes to obtain spliced images; wherein the predetermined sequence of the respective segment routes is consistent with the sequence of the planned route from the starting point to the end point, or the sequence of the planned route from the end point to the starting point.
Optionally, the computer program further implements the following steps when executed by the processor:
after the planned route is determined on the electronic map, before the planned route is segmented, the scale of the electronic map is controlled and adjusted to enable the scale of the electronic map to be larger than a set scale threshold value.
Optionally, the shape of the screenshot area for screenshot the ith segmentation route is parallelogram, circle or ellipse, i is 1 to n, and n represents the number of the obtained segmentation routes.
Optionally, the area of the image corresponding to each obtained segment route is smaller than a set area threshold.
Embodiments of the present invention also provide a computer-readable storage medium applied to a terminal capable of displaying an electronic map, the computer-readable storage medium storing an image processing program,
when executed by at least one processor, cause the at least one processor to:
after the planned route is determined on the electronic map, segmenting the planned route to obtain each segmented route;
screenshot is carried out on each obtained subsection route to obtain an image corresponding to each subsection route;
sequentially splicing the images corresponding to the segmented routes according to the predetermined sequence of the segmented routes to obtain spliced images; wherein the predetermined sequence of the respective segment routes is consistent with the sequence of the planned route from the starting point to the end point, or the sequence of the planned route from the end point to the starting point.
According to the terminal of the image processing method based on the electronic map, provided by the embodiment of the invention, after a planned route is determined on the electronic map, the planned route is segmented to obtain each segmented route; screenshot is carried out on each obtained subsection route to obtain an image corresponding to each subsection route; sequentially splicing the images corresponding to the segmented routes according to the predetermined sequence of the segmented routes to obtain spliced images; wherein the predetermined sequence of the respective segmented routes is consistent with the sequence of the planned route from the starting point to the end point, or consistent with the sequence of the planned route from the end point to the starting point; therefore, the screenshot is only carried out aiming at the area nearby the planned route, and the actual application requirements are further met.
Drawings
Fig. 1 is a schematic diagram of a hardware structure of a mobile terminal implementing various embodiments of the present invention;
fig. 2 is a diagram of a communication network system architecture according to an embodiment of the present invention;
FIG. 3 is a flowchart of an electronic map-based image processing method according to an embodiment of the present invention;
FIG. 4 is a schematic diagram of a planned route in an embodiment of the invention;
FIG. 5 is a diagram illustrating a first example of screenshot based on FIG. 4 according to an embodiment of the present invention;
FIG. 6 is a second exemplary diagram of a screenshot based on FIG. 4 according to an embodiment of the present invention;
FIG. 7 is a third exemplary diagram of a screenshot performed on the basis of FIG. 4 according to the embodiment of the present invention;
FIG. 8 is a fourth exemplary diagram of a screenshot performed on the basis of FIG. 4 according to an embodiment of the present invention;
fig. 9 is a schematic structural diagram of a terminal according to an embodiment of the present invention.
Detailed Description
It should be understood that the specific embodiments described herein are merely illustrative of the invention and are not intended to limit the invention.
In the following description, suffixes such as "module", "component", or "unit" used to denote elements are used only for facilitating the explanation of the present invention, and have no specific meaning in itself. Thus, "module", "component" or "unit" may be used mixedly.
The terminal may be implemented in various forms. For example, the terminal described in the present invention may include a mobile terminal such as a mobile phone, a tablet computer, a notebook computer, a palmtop computer, a Personal Digital Assistant (PDA), a Portable Media Player (PMP), a navigation device, a wearable device, a smart band, a pedometer, and the like, and a fixed terminal such as a Digital TV, a desktop computer, and the like.
The following description will be given by way of example of a mobile terminal, and it will be understood by those skilled in the art that the construction according to the embodiment of the present invention can be applied to a fixed type terminal, in addition to elements particularly used for mobile purposes.
Referring to fig. 1, which is a schematic diagram of a hardware structure of a mobile terminal for implementing various embodiments of the present invention, the mobile terminal 100 may include: an a/V (audio/video) input unit 104, a display unit 106, a user input unit 107, an interface unit 108, a memory 109, a processor 110, and a power supply 111. Those skilled in the art will appreciate that the mobile terminal architecture shown in fig. 1 is not intended to be limiting of mobile terminals, which may include more or fewer components than those shown, or some components may be combined, or a different arrangement of components.
The following describes each component of the mobile terminal in detail with reference to fig. 1:
the a/V input unit 104 is used to receive audio or video signals. The a/V input Unit 104 may include a Graphics Processing Unit (GPU) 1041, and the Graphics processor 1041 processes image data of a still picture or video obtained by an image capturing device (such as a camera) in a video capturing mode or an image capturing mode. The processed image frames may be displayed on the display unit 106. The image frames processed by the graphic processor 1041 may be stored in the memory 109 (or other storage medium) or transmitted via the radio frequency unit 101 or the WiFi module 102.
The Display unit 106 may include a Display panel 1061, and the Display panel 1061 may be configured in the form of a liquid Crystal Display (L acquired Crystal Display, L CD), an Organic light-Emitting Diode (O L ED), or the like.
The user input unit 107 may be used to receive input numeric or character information and generate key signal inputs related to user settings and function control of the mobile terminal. Specifically, the user input unit 107 may include a touch panel 1071 and other input devices 1072. The touch panel 1071, also referred to as a touch screen, may collect a touch operation performed by a user on or near the touch panel 1071 (e.g., an operation performed by the user on or near the touch panel 1071 using a finger, a stylus, or any other suitable object or accessory), and drive a corresponding connection device according to a predetermined program. The touch panel 1071 may include two parts of a touch detection device and a touch controller. The touch detection device detects the touch direction of a user, detects a signal brought by touch operation and transmits the signal to the touch controller; the touch controller receives touch information from the touch sensing device, converts the touch information into touch point coordinates, sends the touch point coordinates to the processor 110, and can receive and execute commands sent by the processor 110. In addition, the touch panel 1071 may be implemented in various types, such as a resistive type, a capacitive type, an infrared ray, and a surface acoustic wave. In addition to the touch panel 1071, the user input unit 107 may include other input devices 1072. In particular, other input devices 1072 may include, but are not limited to, one or more of a physical keyboard, function keys (e.g., volume control keys, switch keys, etc.), a trackball, a mouse, a joystick, and the like, and are not limited to these specific examples.
Further, the touch panel 1071 may cover the display panel 1061, and when the touch panel 1071 detects a touch operation thereon or nearby, the touch panel 1071 transmits the touch operation to the processor 110 to determine the type of the touch event, and then the processor 110 provides a corresponding visual output on the display panel 1061 according to the type of the touch event. Although the touch panel 1071 and the display panel 1061 are shown in fig. 1 as two separate components to implement the input and output functions of the mobile terminal, in some embodiments, the touch panel 1071 and the display panel 1061 may be integrated to implement the input and output functions of the mobile terminal, and is not limited herein.
The interface unit 108 serves as an interface through which at least one external device is connected to the mobile terminal 100. For example, the external device may include a wired or wireless headset port, an external power supply (or battery charger) port, a wired or wireless data port, a memory card port, a port for connecting a device having an identification module, an audio input/output (I/O) port, a video I/O port, an earphone port, and the like. The interface unit 108 may be used to receive input (e.g., data information, power, etc.) from external devices and transmit the received input to one or more elements within the mobile terminal 100 or may be used to transmit data between the mobile terminal 100 and external devices.
The memory 109 may be used to store software programs as well as various data. The memory 109 may mainly include a storage program area and a storage data area, wherein the storage program area may store an operating system, an application program required by at least one function (such as a sound playing function, an image playing function, etc.), and the like; the storage data area may store data (such as audio data, a phonebook, etc.) created according to the use of the cellular phone, and the like. Further, the memory 109 may include high speed random access memory, and may also include non-volatile memory, such as at least one magnetic disk storage device, flash memory device, or other volatile solid state storage device.
The processor 110 is a control center of the mobile terminal, connects various parts of the entire mobile terminal using various interfaces and lines, and performs various functions of the mobile terminal and processes data by operating or executing software programs and/or modules stored in the memory 109 and calling data stored in the memory 109, thereby performing overall monitoring of the mobile terminal. Processor 110 may include one or more processing units; preferably, the processor 110 may integrate an application processor, which mainly handles operating systems, user interfaces, application programs, etc., and a modem processor, which mainly handles wireless communications. It will be appreciated that the modem processor described above may not be integrated into the processor 110.
The mobile terminal 100 may further include a power supply 111 (e.g., a battery) for supplying power to various components, and preferably, the power supply 111 may be logically connected to the processor 110 via a power management system, so as to manage charging, discharging, and power consumption management functions via the power management system.
Although not shown in fig. 1, the mobile terminal 100 may further include a bluetooth module or the like, which is not described in detail herein.
In order to facilitate understanding of the embodiments of the present invention, a communication network system on which the mobile terminal of the present invention is based is described below.
Referring to fig. 2, fig. 2 is an architecture diagram of a communication Network system according to an embodiment of the present invention, the communication Network system is L TE system of universal mobile telecommunications technology, and the L TE system includes a UE (User Equipment) 201, an E-UTRAN (Evolved UMTS Terrestrial Radio Access Network) 202, an EPC (Evolved Packet Core) 203, and an IP service 204 of an operator, which are in communication connection in sequence.
Specifically, the UE201 may be the terminal 100 described above, and is not described herein again.
The E-UTRAN202 includes eNodeB2021 and other eNodeBs 2022, among others. Among them, the eNodeB2021 may be connected with other eNodeB2022 through backhaul (e.g., X2 interface), the eNodeB2021 is connected to the EPC203, and the eNodeB2021 may provide the UE201 access to the EPC 203.
The EPC203 may include an MME (Mobility Management Entity) 2031, an HSS (Home Subscriber Server) 2032, other MMEs 2033, an SGW (Serving gateway) 2034, a PGW (PDN gateway) 2035, and a PCRF (Policy and charging functions Entity) 2036, and the like. The MME2031 is a control node that handles signaling between the UE201 and the EPC203, and provides bearer and connection management. HSS2032 is used to provide registers to manage functions such as home location register (not shown) and holds subscriber specific information about service characteristics, data rates, etc. All user data may be sent through SGW2034, PGW2035 may provide IP address assignment for UE201 and other functions, and PCRF2036 is a policy and charging control policy decision point for traffic data flow and IP bearer resources, which selects and provides available policy and charging control decisions for a policy and charging enforcement function (not shown).
The IP services 204 may include the internet, intranets, IMS (IP Multimedia Subsystem), or other IP services, among others.
Although the L TE System is described as an example, it should be understood by those skilled in the art that the present invention is not limited to L TE (L ong Term Evolution ) System, but can be applied to other wireless communication systems, such as GSM (Global System of Mobile communication), CDMA2000(Code Division Multiple Access 2000), WCDMA (Wideband Code Division Multiple Access), TD-SCDMA (Time Division-Synchronous Code Division Multiple Access), and future new network systems, and the like, and the present invention is not limited thereto.
Based on the above mobile terminal hardware structure and communication network system, the present invention provides various embodiments of the method.
First embodiment
The first embodiment of the invention provides an image processing method based on an electronic map, which can be applied to a terminal capable of displaying the electronic map.
Electronic maps, i.e., digital maps, are maps that are stored and referred to digitally using computer technology. The method for storing information in electronic map generally uses vector image storage, and the map scale can be enlarged, reduced or rotated without affecting the display effect.
Here, the above-mentioned terminal may be a mobile terminal or a fixed terminal, and the above-mentioned terminal includes, but is not limited to, a mobile phone, a notebook computer, a camera, a PDA, a PAD, a PMP, a navigation device, and the like. The mobile terminal may be connected to the internet, wherein the connection may be made through a mobile internet network provided by an operator, or through a network connection accessed to a wireless access point.
Here, if the mobile terminal has an operating system, the operating system may be UNIX, L inux, Windows, Android (Android), Windows Phone, or the like.
It should be noted that the type, shape, size, and the like of the display screen on the mobile terminal are not limited, and the display screen on the mobile terminal may be a liquid crystal display screen, for example.
In a first embodiment of the present invention, the display screen is used for providing a human-computer interaction interface for a user; in practical implementation, the processor of the terminal can control the map application to display the electronic map on the display screen.
Fig. 3 is a flowchart of an image processing method based on an electronic map according to an embodiment of the present invention, and as shown in fig. 3, the flowchart may include:
step 301: and after the planned route is determined on the electronic map, segmenting the planned route to obtain each segmented route.
In practical application, the processor of the terminal may determine a planned route according to the input starting point and the input end point, and control the planned route described above to be displayed on the electronic map for the user to view.
Here, the planned route may be regarded as a broken line formed by first sequentially connecting a plurality of line segments, fig. 4 is a schematic diagram of the planned route in the embodiment of the present invention, as shown in fig. 4, a starting point of the planned route is a, an end point of the planned route is B, and in fig. 4, the planned route is formed by 5 line segments, which are respectively denoted as a line segment C, a line segment D, a line segment E, a line segment F, and a line segment G.
It should be noted that, after the planned route is segmented, the length of each segmented route on the electronic map is the length corresponding to the scale of the current electronic map;
for an electronic map, a scale represents the ratio of the length of a line segment on the map to the actual length of a corresponding line segment on the ground, and the calculation formula can be: the ratio of distance on the graph to actual distance; the larger the scale is, the smaller the range represented by the map is, and the more detailed the content represented in the map is, the higher the precision is; the smaller the scale is, the larger the range represented on the map is, the simpler the reflected content is, and the lower the accuracy is; therefore, the electronic map can present more detailed contents by controlling the increase of the scale; on the contrary, the scale is reduced through control, so that the electronic map presents a larger range.
In order to achieve the purpose of presenting more details of the planned route, the scale can be increased to enable the scale of the electronic map to exceed a certain threshold, and thus, the electronic map can present more details of the planned route.
For example, after the planned route is determined on the electronic map, before the planned route is segmented, the control adjusts the scale of the electronic map so that the scale of the electronic map is larger than the set scale threshold.
The scale threshold value here may be preset, and in actual implementation, the scale threshold value preset by the user may be input to the terminal through a user input unit of the terminal.
In practical implementation, after the planned route is segmented, the obtained segmented route may include only one line segment, or may include at least two line segments;
for example, for the planned route shown in fig. 4, in example 1, after the planned route is segmented, 4 segmented routes are obtained, which are respectively denoted as segmented route 1, segmented route 2, segmented route 3, and segmented route 4; the sectional route 1 is composed of a line segment C and a line segment D, the sectional route 2 is a line segment E, the sectional route 3 is a line segment F, and the sectional route 4 is a line segment G.
For the planned route shown in fig. 4, in example 2, the obtained segmented route may include only a part of one line segment shown in fig. 4, for example, line segment 1 in fig. 4 is divided into a first part and a second part, and after the planned route is segmented, 3 segmented routes are obtained, which are respectively denoted as segmented route 5, segmented route 6 and segmented route 7, where segmented route 5 is the first part of line segment C, segmented route 6 is composed of the second part of line segment C and line segment D, and segmented route 7 is composed of line segment E, line segment F and line segment G.
Preferably, each segmented route obtained by segmenting the planned route is a line segment, so that corresponding detailed information near the segmented route is conveniently acquired in subsequent screenshot operation; as for the planned route shown in fig. 4, in example 3, after the planned route is segmented, 5 segmented routes are obtained, which are respectively denoted as segmented route a1, segmented route a2, segmented route A3, segmented route a4 and segmented route a5, segmented route a1 is line C, segmented route a2 is line D, segmented route A3 is line E, segmented route a4 is line F, and segmented route a5 is line G;
for the planned route shown in fig. 4, in example 4, after the planned route is segmented, 7 segment routes are obtained, which are respectively denoted as segment route B1, segment route B2, segment route B3, segment route B4, segment route B5, segment route B6 and segment route B7, where segment route B1 and segment route B2 jointly form segment C, segment route B3 is segment D, segment route B4 is segment E, segment route B5 and segment route B6 jointly form segment F, and segment route B7 is segment G.
Step 302: and performing screenshot on each obtained subsection route to obtain an image corresponding to each subsection route.
Here, the obtained respective segment routes may be written as 1 st segment route to nth segment route, n is a natural number greater than 1, and n represents the number of segment routes; in this way, after the 1 st to nth segment routes are obtained, screenshots are respectively carried out on the 1 st to nth segment routes, and images of the n segment routes are obtained.
Illustratively, after the ith segmentation route is subjected to screenshot, the obtained image corresponding to the ith segmentation route comprises the ith segmentation route, and i is 1 to n.
In an optional example, the area of the image corresponding to each obtained segmented route is smaller than a set area threshold, so that detail information which does not need to be obtained by a user can be avoided being intercepted, and actual requirements are met; in practical implementation, the processor of the terminal may determine the screenshot area of each segment route according to the set area threshold and the length of each segment route.
In actual implementation, the processor of the terminal may obtain the length and the position of each segment route, and control to generate a screenshot area for the corresponding segment route, so as to capture a screenshot based on the generated screenshot area to obtain an image corresponding to the corresponding segment route.
Step 303: sequentially splicing the images corresponding to the segmented routes according to the predetermined sequence of the segmented routes to obtain spliced images; wherein the predetermined sequence of the respective segment routes is consistent with the sequence of the planned route from the starting point to the end point, or the sequence of the planned route from the end point to the starting point.
That is, when the graphs are spliced, the graphs can be sequentially spliced according to the direction from the starting point to the end point of the planned route, and also can be sequentially spliced according to the direction from the end point to the starting point of the planned route, so that a complete image containing the whole planned route can be obtained.
When the screenshot is performed on each segment route, there may be an overlapping portion in the screenshot areas of two adjacent segment routes, that is, there may be an overlapping portion in the images corresponding to the two described adjacent segment routes.
In practical implementation, the processor of the terminal may determine the sequence of each segment route based on the sequence of the planned route from the starting point to the end point, or the sequence of the planned route from the end point to the starting point; and then, sequentially splicing the images corresponding to the segmented routes by a processor of the terminal according to the sequence of the segmented routes.
After the planned route is determined on the electronic map, the planned route is segmented to obtain each segmented route; screenshot is carried out on each obtained subsection route to obtain an image corresponding to each subsection route; sequentially splicing the images corresponding to the segmented routes according to the predetermined sequence of the segmented routes to obtain spliced images; wherein the predetermined sequence of the respective segmented routes is consistent with the sequence of the planned route from the starting point to the end point, or consistent with the sequence of the planned route from the end point to the starting point; therefore, the screenshot is only carried out aiming at the area nearby the planned route, and the actual application requirements are further met.
In addition, according to the first embodiment of the image processing method based on the electronic map, the area of the screenshot area is controlled to ensure that the screenshot is only performed on the area near the planned route, and meanwhile, the scale can be adjusted to enable the finally obtained image to include more detailed information, so that the detailed information near the planned route can be obtained, and the actual requirement can be met.
Second embodiment
In order to further embody the object of the present invention, further illustration is made on the basis of the first embodiment of the present invention.
In a second embodiment of the present invention, a flow of an image processing method based on an electronic map may include:
step 401: this step is the same as the step 301, and is not described herein again.
Step 402: and performing screenshot on each obtained subsection route to obtain an image corresponding to each subsection route.
Here, among the n derived segment routes, the shape of the region that screens the i-th derived segment route may be a parallelogram, a circle, or an ellipse, for example, the shape of the region that screens the i-th derived segment routes is a rectangle.
It should be noted that the shapes of the regions for capturing the obtained arbitrary two segment routes may be the same or different;
for example, fig. 5 is a first exemplary diagram of performing screenshot on the basis of fig. 4 according to the embodiment of the present invention, and as shown in fig. 5, the composition and the labeling manner of the planned route are the same as those of fig. 4, it can be seen that there are 5 segment routes, the 5 segment routes are respectively a line segment C, a line segment D, a line segment E, a line segment F, and a line segment G, a dashed box represents a screenshot area corresponding to each line segment, and screenshot areas corresponding to the line segment C, the line segment D, the line segment E, the line segment F, and the line segment G are rectangles.
Fig. 6 is a second exemplary diagram for performing screenshot on the basis of fig. 4 according to the embodiment of the present invention, and as shown in fig. 6, the composition and the marking manner of the planned route are the same as those of fig. 4, it can be seen that there are 5 segment routes, the 5 segment routes are respectively a line segment C, a line segment D, a line segment E, a line segment F and a line segment G, a dashed box represents a screenshot area corresponding to each line segment, the line segment C, the line segment D, the line segment E, the line segment F and the line segment G, and the corresponding screenshot areas are rectangles.
Fig. 7 is a third exemplary diagram of performing screenshot on the basis of fig. 4 according to the embodiment of the present invention, and as shown in fig. 7, the composition and the marking manner of the planned route are the same as those of fig. 4, it can be seen that there are 5 segment routes, the 5 segment routes are respectively a line segment C, a line segment D, a line segment E, a line segment F and a line segment G, a dashed box represents a screenshot area corresponding to each line segment, and screenshot areas corresponding to the line segment C, the line segment D, the line segment E, the line segment F and the line segment G are all elliptical.
Fig. 8 is a fourth example diagram of performing screenshot on the basis of fig. 4 according to the embodiment of the present invention, and as shown in fig. 8, the composition and the marking manner of the planned route are the same as those in fig. 4, it can be seen that there are 5 segment routes, the 5 segment routes are respectively a line segment C, a line segment D, a line segment E, a line segment F and a line segment G, a dashed box represents a screenshot area corresponding to each line segment, screenshot areas corresponding to the line segment C, the line segment D, the line segment E and the line segment G are all rectangles, and the screenshot area corresponding to the line segment F is an ellipse.
Illustratively, the above-described derived i-th segment route is a line segment;
when the shape of a screenshot area for screenshot on the ith subsection route is a parallelogram, the ith subsection route is a midpoint connecting line of any group of opposite sides of the parallelogram or any one diagonal line of the parallelogram;
when the shape of a screenshot area for screenshot on the obtained ith segmentation route is a circle, the ith segmentation route is the central line of the circle;
when the shape of a screenshot area for screenshot on the ith segmented route is an ellipse, the ith segmented route is the major axis or the minor axis of the ellipse.
After the screenshot mode is adopted, it can be seen that each segmented route is located in the center of the screenshot area, so that the detail information near each segmented route can be divided into the screenshot area, and finally the image spliced by the images can include the detail information near the planned route, so that the actual application requirements are met.
As illustrated in fig. 5 to 8, in fig. 5, the shape of the screenshot area corresponding to each segment route is a rectangle, and each segment route is a midpoint connecting line of a group of opposite sides of the rectangle.
In fig. 6, the shape of the screenshot area corresponding to each segment route is a rectangle, where each segment route is a diagonal line of the corresponding rectangular screenshot area.
In fig. 7, the shape of the screenshot area corresponding to each segment route is an ellipse, where each segment route is the long axis of the corresponding elliptical screenshot area.
In fig. 8, the 1 st segment route, i.e., the segment C, is a diagonal line of the corresponding rectangular screenshot area, the 2 nd segment route, i.e., the segment D, is a midpoint connecting line of a group of opposite sides of the corresponding rectangular screenshot area, the 3 rd segment route, i.e., the segment E, is a diagonal line of the corresponding rectangular screenshot area, the 4 th segment route, i.e., the segment F, is a long axis of the corresponding oval screenshot area, and the 5 th segment route, i.e., the segment G, is a diagonal line of the corresponding rectangular screenshot area.
Third embodiment
Based on the same technical concept of the foregoing embodiments, a third embodiment of the present invention provides a terminal, where the terminal described above may be a mobile terminal or a fixed terminal, and the terminal described above includes, but is not limited to, a mobile phone, a notebook computer, a camera, a PDA, a PAD, a PMP, a navigation device, and so on. The mobile terminal may be connected to the internet, wherein the connection may be made through a mobile internet network provided by an operator, or through a network connection accessed to a wireless access point.
Here, the above-mentioned terminal may be a mobile terminal or a fixed terminal, and the above-mentioned terminal includes, but is not limited to, a mobile phone, a notebook computer, a camera, a PDA, a PAD, a PMP, a navigation device, and the like. The mobile terminal may be connected to the internet, wherein the connection may be made through a mobile internet network provided by an operator, or through a network connection accessed to a wireless access point.
Here, if the mobile terminal has an operating system, the operating system may be UNIX, L inux, Windows, Android (Android), Windows Phone, or the like.
It should be noted that the type, shape, size, and the like of the display screen on the mobile terminal are not limited, and the display screen on the mobile terminal may be a liquid crystal display screen, for example.
In a first embodiment of the present invention, the display screen is used for providing a human-computer interaction interface for a user; in practical implementation, the processor of the terminal can control the map application to display the electronic map on the display screen.
Referring to fig. 9, a terminal 90 according to an embodiment of the present invention is shown, which may include: a memory 901, a processor 902 and a computer program stored on the memory and executable on the processor, which computer program when executed by the processor performs the steps of:
after a planned route is determined on an electronic map displayed by a terminal, segmenting the planned route to obtain each segmented route;
screenshot is carried out on each obtained subsection route to obtain an image corresponding to each subsection route;
sequentially splicing the images corresponding to the segmented routes according to the predetermined sequence of the segmented routes to obtain spliced images; wherein the predetermined sequence of the respective segment routes is consistent with the sequence of the planned route from the starting point to the end point, or the sequence of the planned route from the end point to the starting point.
In practical applications, the Memory 901 may be a volatile Memory (volatile Memory), such as a Random-Access Memory (RAM); or a non-volatile Memory (non-volatile Memory) such as a Read-Only Memory (ROM), a flash Memory (flash Memory), a Hard Disk (HDD), or a Solid-State Drive (SSD); or a combination of the above types of memories and provides instructions and data to the processor 702.
The Processor 902 may be at least one of an Application Specific Integrated Circuit (ASIC), a Digital Signal Processor (DSP), a Digital Signal Processing Device (DSPD), a Programmable logic Device (P L D, Programmable L) a Field Programmable Gate Array (FPGA), a Central Processing Unit (CPU), a controller, a microcontroller, and a microprocessor.
In practical application, the processor of the terminal may determine a planned route according to the input starting point and the input end point, and control the planned route described above to be displayed on the electronic map for the user to view.
Here, the planned route may be regarded as a broken line formed by connecting a plurality of line segments first in sequence, as shown in fig. 4, the starting point of the planned route is a, and the end point of the planned route is B, and in fig. 4, the planned route is formed by 5 line segments, which are respectively denoted as line segment C, line segment D, line segment E, line segment F, and line segment G.
It should be noted that, after the planned route is segmented, the length of each segmented route on the electronic map is the length corresponding to the scale of the current electronic map;
for an electronic map, a scale represents the ratio of the length of a line segment on the map to the actual length of a corresponding line segment on the ground, and the calculation formula can be: the ratio of distance on the graph to actual distance; the larger the scale is, the smaller the range represented by the map is, and the more detailed the content represented in the map is, the higher the precision is; the smaller the scale is, the larger the range represented on the map is, the simpler the reflected content is, and the lower the accuracy is; therefore, the electronic map can present more detailed contents by controlling the increase of the scale; on the contrary, the scale is reduced through control, so that the electronic map presents a larger range.
In order to achieve the purpose of presenting more details of the planned route, the scale can be increased to enable the scale of the electronic map to exceed a certain threshold, and thus, the electronic map can present more details of the planned route.
For example, after the planned route is determined on the electronic map, before the planned route is segmented, the control adjusts the scale of the electronic map so that the scale of the electronic map is larger than the set scale threshold.
The scale threshold value here may be preset, and in actual implementation, the scale threshold value preset by the user may be input to the terminal through a user input unit of the terminal.
In practical implementation, after the planned route is segmented, the obtained segmented route may include only one line segment, or may include at least two line segments;
for example, for the planned route shown in fig. 4, in example 1, after the planned route is segmented, 4 segmented routes are obtained, which are respectively denoted as segmented route 1, segmented route 2, segmented route 3, and segmented route 4; the sectional route 1 is composed of a line segment C and a line segment D, the sectional route 2 is a line segment E, the sectional route 3 is a line segment F, and the sectional route 4 is a line segment G.
For the planned route shown in fig. 4, in example 2, the obtained segmented route may include only a part of one line segment shown in fig. 4, for example, line segment 1 in fig. 4 is divided into a first part and a second part, and after the planned route is segmented, 3 segmented routes are obtained, which are respectively denoted as segmented route 5, segmented route 6 and segmented route 7, where segmented route 5 is the first part of line segment C, segmented route 6 is composed of the second part of line segment C and line segment D, and segmented route 7 is composed of line segment E, line segment F and line segment G.
Preferably, each segmented route obtained by segmenting the planned route is a line segment, so that corresponding detailed information near the segmented route is conveniently acquired in subsequent screenshot operation; as for the planned route shown in fig. 4, in example 3, after the planned route is segmented, 5 segmented routes are obtained, which are respectively denoted as segmented route a1, segmented route a2, segmented route A3, segmented route a4 and segmented route a5, segmented route a1 is line C, segmented route a2 is line D, segmented route A3 is line E, segmented route a4 is line F, and segmented route a5 is line G;
for the planned route shown in fig. 4, in example 4, after the planned route is segmented, 7 segment routes are obtained, which are respectively denoted as segment route B1, segment route B2, segment route B3, segment route B4, segment route B5, segment route B6 and segment route B7, where segment route B1 and segment route B2 jointly form segment C, segment route B3 is segment D, segment route B4 is segment E, segment route B5 and segment route B6 jointly form segment F, and segment route B7 is segment G.
Here, after segmenting the planned route, the obtained respective segmented routes may be recorded as a1 st segmented route to an nth segmented route, n is a natural number greater than 1, and n represents the number of the segmented routes; in this way, after the 1 st to nth segment routes are obtained, screenshots are respectively carried out on the 1 st to nth segment routes, and images of the n segment routes are obtained.
Illustratively, after the ith segmentation route is subjected to screenshot, the obtained image corresponding to the ith segmentation route comprises the ith segmentation route, and i is 1 to n.
In an optional example, the area of the image corresponding to each obtained segmented route is smaller than a set area threshold, so that detail information which does not need to be obtained by a user can be avoided being intercepted, and actual requirements are met; in practical implementation, the processor of the terminal may determine the screenshot area of each segment route according to the set area threshold and the length of each segment route.
In actual implementation, the processor of the terminal may obtain the length and the position of each segment route, and control to generate a screenshot area for the corresponding segment route, so as to capture a screenshot based on the generated screenshot area to obtain an image corresponding to the corresponding segment route.
It can be seen that, when graph splicing is performed, splicing can be performed in sequence according to the direction from the starting point to the end point of the planned route, or splicing can be performed in sequence according to the direction from the end point to the starting point of the planned route, so that a complete image containing the whole planned route can be obtained.
When the screenshot is performed on each segment route, there may be an overlapping portion in the screenshot areas of two adjacent segment routes, that is, there may be an overlapping portion in the images corresponding to the two described adjacent segment routes.
In practical implementation, the processor of the terminal may determine the sequence of each segment route based on the sequence of the planned route from the starting point to the end point, or the sequence of the planned route from the end point to the starting point; and then, sequentially splicing the images corresponding to the segmented routes by a processor of the terminal according to the sequence of the segmented routes.
Optionally, the computer program further implements the following steps when executed by the processor:
after the planned route is determined on the electronic map, before the planned route is segmented, the scale of the electronic map is controlled and adjusted to enable the scale of the electronic map to be larger than a set scale threshold value.
Optionally, the shape of the screenshot area for screenshot the ith segmentation route is parallelogram, circle or ellipse, i is 1 to n, and n represents the number of the obtained segmentation routes.
Fourth embodiment
Based on the same technical concept of the foregoing embodiments, a third embodiment of the present invention provides a computer-readable medium, where a technical solution of the foregoing embodiments essentially or partially contributes to the prior art, or all or part of the technical solution may be embodied in the form of a software product, the computer software product is stored in a computer-readable storage medium, and includes several instructions to enable a computer device (which may be a personal computer, a server, or a network device, etc.) or a processor (processor) to execute all or part of the steps of the method according to this embodiment. And the aforementioned storage medium includes: various media capable of storing program codes, such as a usb disk, a removable hard disk, a Read Only Memory (ROM), a Random Access Memory (RAM), a magnetic disk, or an optical disk.
Specifically, the computer program instructions corresponding to a method for displaying an icon in the present embodiment may be stored on a storage medium such as an optical disc, a hard disc, or a usb disk, and when the computer program instructions corresponding to a method for displaying an icon in the storage medium are read or executed by an electronic device, the method includes the following steps:
after the planned route is determined on the electronic map, segmenting the planned route to obtain each segmented route;
screenshot is carried out on each obtained subsection route to obtain an image corresponding to each subsection route;
sequentially splicing the images corresponding to the segmented routes according to the predetermined sequence of the segmented routes to obtain spliced images; wherein the predetermined sequence of the respective segment routes is consistent with the sequence of the planned route from the starting point to the end point, or the sequence of the planned route from the end point to the starting point.
It should be noted that, in this document, the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or apparatus. Without further limitation, an element defined by the phrase "comprising an … …" does not exclude the presence of other like elements in a process, method, article, or apparatus that comprises the element.
The above-mentioned serial numbers of the embodiments of the present invention are merely for description and do not represent the merits of the embodiments.
Through the above description of the embodiments, those skilled in the art will clearly understand that the method of the above embodiments can be implemented by software plus a necessary general hardware platform, and certainly can also be implemented by hardware, but in many cases, the former is a better implementation manner. Based on such understanding, the technical solutions of the present invention may be embodied in the form of a software product, which is stored in a storage medium (such as ROM/RAM, magnetic disk, optical disk) and includes instructions for enabling a terminal (such as a mobile phone, a computer, a server, an air conditioner, or a network device) to execute the method according to the embodiments of the present invention.
While the present invention has been described with reference to the embodiments shown in the drawings, the present invention is not limited to the embodiments, which are illustrative and not restrictive, and it will be apparent to those skilled in the art that various changes and modifications can be made therein without departing from the spirit and scope of the invention as defined in the appended claims.

Claims (10)

1. An image processing method based on an electronic map, characterized in that the method comprises:
after the planned route is determined on the electronic map, segmenting the planned route to obtain each segmented route;
screenshot is carried out on each obtained subsection route to obtain an image corresponding to each subsection route;
sequentially splicing the images corresponding to the segmented routes according to the predetermined sequence of the segmented routes to obtain spliced images; wherein the predetermined sequence of the respective segment routes is consistent with the sequence of the planned route from the starting point to the end point, or the sequence of the planned route from the end point to the starting point.
2. The method of claim 1, wherein after determining the planned route on the electronic map, prior to segmenting the planned route, the method further comprises:
and controlling and adjusting the scale of the electronic map to enable the scale of the electronic map to be larger than a set scale threshold value.
3. The method according to claim 1, wherein the shape of the screenshot area for capturing the ith segment route is parallelogram, circle or ellipse, i is 1 to n, and n represents the number of the segment routes.
4. A method according to claim 3, wherein the derived i-th piecewise course is a line segment;
when the shape of the screenshot area is a parallelogram, the ith segmentation route is a midpoint connecting line of any group of opposite sides of the parallelogram or any diagonal line of the parallelogram;
when the shape of the screenshot area is a circle, the ith segmentation route is the central line of the circle;
when the shape of the screenshot area is an ellipse, the ith segmentation route is a long axis or a short axis of the ellipse.
5. The method according to any one of claims 1 to 4, wherein the area of the image corresponding to each of the obtained segmented routes is smaller than a set area threshold.
6. A terminal, characterized in that the terminal comprises: a memory, a processor and a computer program stored on the memory and executable on the processor, the computer program when executed by the processor implementing the steps of:
after a planned route is determined on an electronic map displayed by a terminal, segmenting the planned route to obtain each segmented route;
screenshot is carried out on each obtained subsection route to obtain an image corresponding to each subsection route;
sequentially splicing the images corresponding to the segmented routes according to the predetermined sequence of the segmented routes to obtain spliced images; wherein the predetermined sequence of the respective segment routes is consistent with the sequence of the planned route from the starting point to the end point, or the sequence of the planned route from the end point to the starting point.
7. The terminal according to claim 6, wherein the computer program, when executed by the processor, further performs the steps of:
after the planned route is determined on the electronic map, before the planned route is segmented, the scale of the electronic map is controlled and adjusted to enable the scale of the electronic map to be larger than a set scale threshold value.
8. A terminal according to claim 6, characterized in that the shape of the screenshot area for the ith resulting segment route is parallelogram, circular or elliptical, i is 1 to n, and n represents the number of resulting segment routes.
9. A terminal according to any of claims 6 to 8, wherein the area of the image corresponding to each of the derived segment routes is less than a set area threshold.
10. A computer-readable storage medium, for use in a terminal capable of displaying an electronic map, the computer-readable storage medium storing an image processing program,
when executed by at least one processor, cause the at least one processor to:
after the planned route is determined on the electronic map, segmenting the planned route to obtain each segmented route;
screenshot is carried out on each obtained subsection route to obtain an image corresponding to each subsection route;
sequentially splicing the images corresponding to the segmented routes according to the predetermined sequence of the segmented routes to obtain spliced images; wherein the predetermined sequence of the respective segment routes is consistent with the sequence of the planned route from the starting point to the end point, or the sequence of the planned route from the end point to the starting point.
CN201710643701.0A 2017-07-31 2017-07-31 Image processing method and terminal based on electronic map Active CN107464215B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201710643701.0A CN107464215B (en) 2017-07-31 2017-07-31 Image processing method and terminal based on electronic map

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201710643701.0A CN107464215B (en) 2017-07-31 2017-07-31 Image processing method and terminal based on electronic map

Publications (2)

Publication Number Publication Date
CN107464215A CN107464215A (en) 2017-12-12
CN107464215B true CN107464215B (en) 2020-07-28

Family

ID=60547090

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201710643701.0A Active CN107464215B (en) 2017-07-31 2017-07-31 Image processing method and terminal based on electronic map

Country Status (1)

Country Link
CN (1) CN107464215B (en)

Families Citing this family (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108711355B (en) * 2018-03-30 2022-07-01 广州亿航智能技术有限公司 Track map strategy making and using method, device and readable storage medium
CN112492197B (en) * 2020-11-18 2022-01-07 京东科技信息技术有限公司 Image processing method and related equipment
CN112764621B (en) * 2021-01-25 2022-07-15 维沃移动通信有限公司 Screenshot method and device and electronic equipment

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102779008A (en) * 2012-06-26 2012-11-14 奇智软件(北京)有限公司 Screen screenshot method and system
CN102968274A (en) * 2012-11-22 2013-03-13 广东欧珀移动通信有限公司 Free screen capturing method and free screen capturing system in mobile device
CN103514581A (en) * 2013-10-23 2014-01-15 小米科技有限责任公司 Screen picture capturing method, device and terminal equipment
CN104679405A (en) * 2015-02-06 2015-06-03 深圳市金立通信设备有限公司 Terminal
CN104899832A (en) * 2015-06-23 2015-09-09 上海卓易科技股份有限公司 Splicing screenshot method of mobile terminal and splicing screenshot device
CN105444754A (en) * 2015-11-06 2016-03-30 百度在线网络技术(北京)有限公司 Navigation image display method and device

Family Cites Families (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2013003005A (en) * 2011-06-17 2013-01-07 Sanyo Electric Co Ltd Display control apparatus and guide route display method
CN102853842B (en) * 2012-05-15 2013-10-16 董路 Navigation path planning method, apparatus, and system
CN104061938B (en) * 2013-03-21 2017-11-10 高德信息技术有限公司 A kind of air navigation aid, apparatus and system
CN106446284A (en) * 2016-10-28 2017-02-22 努比亚技术有限公司 Map loading device and method

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102779008A (en) * 2012-06-26 2012-11-14 奇智软件(北京)有限公司 Screen screenshot method and system
CN102968274A (en) * 2012-11-22 2013-03-13 广东欧珀移动通信有限公司 Free screen capturing method and free screen capturing system in mobile device
CN103514581A (en) * 2013-10-23 2014-01-15 小米科技有限责任公司 Screen picture capturing method, device and terminal equipment
CN104679405A (en) * 2015-02-06 2015-06-03 深圳市金立通信设备有限公司 Terminal
CN104899832A (en) * 2015-06-23 2015-09-09 上海卓易科技股份有限公司 Splicing screenshot method of mobile terminal and splicing screenshot device
CN105444754A (en) * 2015-11-06 2016-03-30 百度在线网络技术(北京)有限公司 Navigation image display method and device

Also Published As

Publication number Publication date
CN107464215A (en) 2017-12-12

Similar Documents

Publication Publication Date Title
CN107247746B (en) Data sharing method and terminal
EP3206110B1 (en) Method of providing handwriting style correction function and electronic device adapted thereto
CN104852885B (en) Method, device and system for verifying verification code
US20160004425A1 (en) Method of displaying graphic user interface and electronic device implementing same
CN108829476A (en) A kind of message display method, terminal and storage medium
CN107464215B (en) Image processing method and terminal based on electronic map
CN107682525A (en) Screenshot processing method, terminal and computer-readable recording medium
CN107730260B (en) Method, equipment and terminal for realizing two-dimensional code payment
US20150212793A1 (en) Mobile terminal and image processing method thereof
CN107230065B (en) Two-dimensional code display method and device and computer readable storage medium
US9996699B2 (en) Method, electronic device and computer program product for screen shield
CN107918517B (en) Screen rotation response method and device, mobile terminal and storage medium
CN107231469B (en) Terminal application management method, terminal and computer readable storage medium
CN104077077A (en) Method and device for adjusting prompt characters in input method
CN113138857A (en) Memory cleaning method, mobile terminal and storage medium
CN112394863B (en) Picture display method and device, mobile terminal and storage medium
CN107507143A (en) A kind of image restoring method and terminal
US11243668B2 (en) User interactive method and apparatus for controlling presentation of multimedia data on terminals
CN109948368B (en) Privacy authority control method, device and computer readable storage medium
CN108900696B (en) Data processing method, terminal and computer readable storage medium
CN107391151B (en) Application evaluation method, device and computer-readable storage medium
CN108108054B (en) Method, apparatus and computer-readable storage medium for predicting user sliding operation
CN115840736A (en) File sorting method, intelligent terminal and computer readable storage medium
CN107357572A (en) A kind of method, terminal and computer-readable recording medium for carrying out icon and showing
CN109543172B (en) Editing object regulation and control method, equipment and computer readable storage medium

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant