CN113763495A - Distance measuring method, device, equipment and storage medium - Google Patents

Distance measuring method, device, equipment and storage medium Download PDF

Info

Publication number
CN113763495A
CN113763495A CN202010523504.7A CN202010523504A CN113763495A CN 113763495 A CN113763495 A CN 113763495A CN 202010523504 A CN202010523504 A CN 202010523504A CN 113763495 A CN113763495 A CN 113763495A
Authority
CN
China
Prior art keywords
equipment
model diagram
distance
rendered
size data
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.)
Pending
Application number
CN202010523504.7A
Other languages
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 Jingdong Century Trading Co Ltd
Beijing Wodong Tianjun Information Technology Co Ltd
Original Assignee
Beijing Jingdong Century Trading Co Ltd
Beijing Wodong Tianjun Information 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 Jingdong Century Trading Co Ltd, Beijing Wodong Tianjun Information Technology Co Ltd filed Critical Beijing Jingdong Century Trading Co Ltd
Priority to CN202010523504.7A priority Critical patent/CN113763495A/en
Publication of CN113763495A publication Critical patent/CN113763495A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T11/002D [Two Dimensional] image generation

Landscapes

  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Telephone Function (AREA)

Abstract

The embodiment of the invention discloses a distance measuring method, a device, equipment and a storage medium, wherein the method comprises the following steps: acquiring a device identifier of the mobile terminal device, and uploading the device identifier to a server; receiving equipment size data and an equipment model diagram which are inquired by a server and correspond to equipment identifications, rendering the equipment model diagram in a current interface, and establishing a mapping relation between the rendered equipment model diagram and the equipment size data; receiving a starting position and an end position which act on the rendered device model graph at least once, determining an actual distance between the starting position and the end position according to the mapping relation, and determining a required distance according to at least one actual distance. The required distance can be obtained based on the mapping relation between the device model diagram and the device size data by rendering the device model diagram of the mobile terminal device for ranging on the interface and inputting the start/end point position corresponding to the start/end point position actually measured on the device model diagram.

Description

Distance measuring method, device, equipment and storage medium
Technical Field
The embodiment of the invention relates to the technical field of computers, in particular to a distance measuring method, a distance measuring device, distance measuring equipment and a storage medium.
Background
The conventional ranging method comprises the following steps: the distance measurement is performed using a standard measuring tool (e.g., a ruler), or the distance between both ends of the target is measured using a camera of a terminal device in which the ranging application is installed.
In the process of implementing the invention, the inventor finds that at least the following technical problems exist in the prior art: users often cannot carry standard measuring tools, so that the distance measurement is inconvenient; the distance between two ends of a target is measured by using the camera, the terminal equipment is required to be provided with various related sensors, the universal applicability is not available, and in the process of moving the terminal equipment to enable a target point in an image collected by the camera to move from one end of the distance measurement to the other end, measurement failure is easily caused by human factors (such as movement deviation), and measurement needs to be carried out repeatedly.
Disclosure of Invention
Embodiments of the present invention provide a distance measurement method, apparatus, device, and storage medium, which can implement distance measurement using an interface with a measurement function, and have a simple and convenient measurement process and general applicability.
In a first aspect, an embodiment of the present invention provides a distance measurement method, including:
acquiring an equipment identifier of mobile terminal equipment, and uploading the equipment identifier to a server so that the server queries equipment size data and an equipment model diagram corresponding to the equipment identifier;
receiving the equipment size data and the equipment model diagram, rendering the equipment model diagram in a current interface, and establishing a mapping relation between the rendered equipment model diagram and the equipment size data;
receiving a starting point position and an end point position which act on the rendered device model diagram for at least one time, determining an actual distance between the starting point position and the end point position according to the mapping relation, and determining a required distance according to at least one actual distance.
In a second aspect, an embodiment of the present invention provides a distance measuring apparatus, including:
the device comprises an identifier uploading module, a storage module and a processing module, wherein the identifier uploading module is used for acquiring a device identifier of the mobile terminal device and uploading the device identifier to a server so that the server queries device size data and a device model diagram corresponding to the device identifier;
the interface rendering module is used for receiving the equipment size data and the equipment model diagram, rendering the equipment model diagram in a current interface, and establishing a mapping relation between the rendered equipment model diagram and the equipment size data;
and the distance determining module is used for receiving a starting point position and an end point position acted on the rendered equipment model graph at least once, determining an actual distance between the starting point position and the end point position according to the mapping relation, and determining a required distance according to at least one actual distance.
In a third aspect, an embodiment of the present invention provides a terminal device, including:
one or more processors;
a memory for storing one or more programs;
when executed by the one or more processors, cause the one or more processors to implement a distance measurement method as in any embodiment of the invention.
In a fourth aspect, an embodiment of the present invention provides a computer-readable storage medium, on which a computer program is stored, which when executed by a processor, implements a distance measurement method according to any embodiment of the present invention.
According to the distance measuring method, the distance measuring device, the distance measuring equipment and the storage medium, the current equipment acquires the equipment identifier of the mobile terminal equipment for distance measurement and uploads the equipment identifier to the server, so that the server inquires equipment size data and an equipment model diagram corresponding to the equipment identifier; the current equipment receives equipment size data and an equipment model diagram which are inquired by a server and correspond to the equipment identification, renders the equipment model diagram in a current interface, and establishes a mapping relation between the rendered equipment model diagram and the equipment size data; the current device receives a starting position and an end position which act on the rendered device model diagram at least once, determines an actual distance between the starting position and the end position according to the mapping relation, and can determine a required distance according to the actual distance. The method comprises the steps of rendering an equipment model diagram of the mobile terminal equipment for ranging on an interface, inputting a starting/ending point position corresponding to the starting/ending point position actually measured at least once on the rendered equipment model diagram, obtaining the distance between at least one actually measured starting/ending point position based on the mapping relation between the equipment model diagram and equipment size data, and obtaining the size of a required distance according to at least one actual distance.
Drawings
In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, a brief description will be given below of the drawings required for the embodiments or the technical solutions in the prior art, and it is obvious that the drawings in the following description are some embodiments of the present invention, and for those skilled in the art, other drawings can be obtained according to these drawings without creative efforts.
Fig. 1 is a flowchart illustrating a distance measuring method according to an embodiment of the present invention;
fig. 2 is a flowchart illustrating a distance measuring method according to a second embodiment of the present invention;
fig. 3 shows a flowchart of a distance measuring method according to a third embodiment of the present invention;
fig. 4 is a schematic interface diagram in a distance measurement method according to a third embodiment of the present invention;
fig. 5 is a schematic structural diagram of a distance measuring device according to a fourth embodiment of the present invention;
fig. 6 shows a schematic diagram of a hardware structure of a terminal device according to a fifth embodiment of the present invention.
Detailed Description
In order to make the objects, technical solutions and advantages of the present invention clearer, the technical solutions of the present invention will be clearly and completely described through embodiments with reference to the accompanying drawings in the embodiments of the present invention, and it is obvious that the described embodiments are some, but not all, embodiments of the present invention. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present invention. In the following embodiments, optional features and examples are provided in each embodiment, and various features described in the embodiments may be combined to form a plurality of alternatives, and each numbered embodiment should not be regarded as only one technical solution.
Example one
Fig. 1 is a flowchart illustrating a distance measuring method according to an embodiment of the present invention, where the distance measuring method according to the embodiment of the present invention is applicable to a case of measuring a distance, for example, a case of measuring a required distance before purchasing a commodity by using a shopping application. The method may be performed by a distance measuring device implemented in software and/or hardware, preferably configured in an electronic device, such as a mobile phone. As shown in fig. 1, the distance measuring method provided in the embodiment of the present invention includes the following steps:
s110, acquiring the equipment identifier of the mobile terminal equipment, and uploading the equipment identifier to a server so that the server can inquire equipment size data and an equipment model diagram corresponding to the equipment identifier.
In the embodiment of the invention, the mobile terminal equipment is mobile phone, notebook or tablet computer and other terminal equipment which is widely used for life and work of users and is convenient to move. When a user needs to measure the distance and finds standard measuring tools such as a ruler and the like at hand, the distance can be measured by replacing the ruler with mobile terminal equipment such as a mobile phone or a tablet personal computer and the like. Before distance measurement is performed, the device identifier of the mobile terminal device serving as the ruler may be uploaded to a server supporting the distance measurement service provided in this embodiment, so that the server performs fast retrieval and query through locally cached data, or queries device information corresponding to the device identifier through the internet or other manners, where the device information includes, but is not limited to, device size data, a device model diagram, or a device default screen saver cover diagram.
In this embodiment, the device identifier may be, for example, a device name, a device model, or the like, which is used to determine a unique device shape; the device dimension data is the overall dimension of the device, such as the actual dimension data of the device, such as the length, width and thickness of the device; the equipment model diagram is an appearance diagram of the equipment, the equipment model diagram can be a two-dimensional or three-dimensional model diagram, the measurement requirement can be met by selecting the two-dimensional model diagram as the measured distance is one-dimensional data, and the equipment model diagram is more beneficial to the operations of transmission, storage, rendering and the like. The default screen saver cover map of the equipment can improve the rendering effect of the equipment model map when the equipment model map is rendered on the current interface, and the distance measurement experience of a user can be improved.
Optionally, obtaining the device identifier of the mobile terminal device includes: responding to the selection operation of the items in the drop-down box control in the current interface, and taking the selected items as the equipment identification of the mobile terminal equipment; or, the device identifier of the current mobile terminal device is obtained by calling the system native program of the current mobile terminal device.
In this embodiment, the mobile terminal device may be a current mobile terminal device running the program code corresponding to the distance measuring method, and may be another mobile terminal device not installed or running the program code corresponding to the distance measuring method. For example, a user has two mobile terminal devices, namely a mobile phone and a tablet computer, and currently uses the tablet computer to operate a program code corresponding to the distance measurement method, but the mobile phone may be used to replace a ruler for distance measurement, and the tablet computer may also be used to replace the ruler for distance measurement.
When the user selects to use the non-current mobile terminal device to replace the ruler for distance measurement, the user can click an entry in a pull-down box control rendered in the current interface to perform an entry selection operation, wherein each entry in the pull-down box control is the device identifier of each mobile terminal device. And the current mobile terminal equipment responds to the selection operation of the item, and takes the item selected by the user as the equipment identification of the mobile terminal equipment. In addition, if the device identifier that the user wants to select does not exist in the entry, an "other" entry may be set in the drop-down box control, so that the user may pop up a text box control by clicking the "other" entry, and the user may manually input the device identifier of the mobile terminal device in the text box control.
In addition, the current mobile terminal device may default to the user selecting a distance measurement with the current mobile terminal device instead of a ruler before the user selects an entry from the drop-down box control. At this time, the current mobile terminal device may call a system native program (native program) on the bottom layer to obtain the device identifier of the current mobile terminal device, and then may automatically select a corresponding entry in the drop-down box control according to the obtained device identifier to display, so as to automatically achieve device identifier acquisition and improve ranging efficiency.
And S120, receiving the equipment size data and the equipment model diagram, rendering the equipment model diagram in the current interface, and establishing a mapping relation between the rendered equipment model diagram and the equipment size data.
In the embodiment of the invention, after inquiring the equipment size data and the equipment model diagram corresponding to the equipment identifier, the server can feed back the current equipment corresponding to the program code of the running distance measuring method through the corresponding data issuing interface. The current device may store the received device size data for subsequent ranging, and may render the received device model map in the current interface so that the user may see the simulated model map of the mobile terminal device in place of the ruler.
The device model map can be rendered at a preset position of a current interface of the current device, such as a central position of the interface. The image size of the rendered device model image may be different from the original size of the received device model image, and a mapping relation can be established between the image size of the rendered device model image and the device size data, so that a foundation is laid for subsequent ranging.
Illustratively, the rendered device model map is a front two-dimensional model map of a mobile phone, the rendered mobile phone is 1700 pixels long, and the real mobile phone in the device size data is 15cm long, then a corresponding relationship between the 1700 pixels and 15cm can be established, that is, each pixel can correspond to an actual distance of 15/1700 cm.
Optionally, rendering the device model map in the current interface includes: acquiring the screen size of the current equipment, and determining the scaling of the equipment model diagram according to the screen size and the picture size of the equipment model diagram; determining layout parameters of the picture display control according to the picture size and the scaling; rendering the picture display control in the current interface according to the layout parameters of the picture display control, and importing the equipment model picture which is scaled according to the scaling into the picture display control for displaying.
The device model graph can be subjected to size adaptive rendering according to the screen size of the current device, and the situation that the rendering of the device model graph is too large or too small and is not beneficial to a user to input the starting point position and the ending point position is avoided. The current equipment can also call a native program to obtain the screen size; further, the optimal scaling of the device model map can be determined according to the preset area proportion of the device model map expected to be rendered occupying the current screen and the picture size of the device model map; according to the scaling, the picture size of the device model graph during rendering can be determined, and the picture size during rendering can be used as the size of the height and the width of the picture display control; if the equipment model graph is expected to be rendered at the central position of the current interface, the position coordinates of the central point of the picture display control can be determined, the height, the width and the position coordinates of the central point of the picture display control can be used as layout parameters of the picture display control, the picture display control is generated on the current interface according to the layout parameters, and meanwhile, the scaled equipment model graph can be led into the generated picture display control to be rendered to obtain an equipment model graph, so that the equipment model graph is displayed on the current interface.
S130, receiving a starting point position and an end point position which act on the rendered device model diagram for at least one time, determining an actual distance between the starting point position and the end point position according to the mapping relation, and determining a required distance according to at least one actual distance.
In the embodiment of the present invention, after measuring a required distance using a real mobile terminal device, a user may input a start position and an end position in a device model map corresponding to a measurement start point and a measurement end point in a real measurement process from a device model map rendered by a current device, for example, sequentially click the start position and the end position in the rendered device model map. After the user inputs the start point position and the end point position, the current device may identify the start point position and the end point position input by the user in the current interface (for example, identify the start point position and the end point position input by the user with a circle dot), and may perform operations such as deleting or moving the start point position and the end point position according to an editing instruction input by the user.
When a user uses a real mobile terminal device to measure a required distance, the required distance may be smaller than or equal to the device size data of the mobile terminal device, and may also be larger than the device size data of the mobile terminal device. When the required distance is smaller than or equal to the device size data of the mobile terminal device, the required distance is measured once by using the mobile terminal device, at this time, the user can input the starting point position and the end point position once on the rendered device model diagram, and the current device can take the received actual distance between the starting point position and the end point position input this time as the required distance. When the required distance is greater than the device size data of the mobile terminal device, the required distance can be obtained only by measuring the required distance twice by using the mobile terminal device, at this time, a user can input a starting point position and an end point position on the rendered device model diagram for multiple times, the current device can respectively determine the actual distance between the starting point position and the end point position input each time, and the sum of at least one determined actual distance can be used as the required distance.
The current device can determine the actual distance between the starting point position and the end point position on the device model diagram according to the mapping relation between the device model diagram rendered in the current interface and the device size data when the user inputs the instructions of the starting point position and the end point position each time. The current device can also determine the required distance according to each actual distance when the user inputs the starting position and the end position, and can also import the determined required distance into a rendered text box control used for displaying the required distance in the interface so that the user can know the numerical value of the measured required distance.
The method comprises the steps of rendering an equipment model diagram with the same appearance as that of mobile terminal equipment used for distance measurement on an interface of the current equipment, inputting a start/end point position corresponding to an actually measured start/end point position on the rendered equipment model diagram, and obtaining the distance between the actually measured start/end point positions based on the mapping relation between the equipment model diagram and equipment size data, so that the required distance measurement is realized by utilizing the interface with the measurement function.
Optionally, after receiving the device size data and the device model map, the method further includes: storing the equipment size data and the equipment model diagram, and establishing a corresponding relation between the equipment identification and the equipment size data and the equipment model diagram;
correspondingly, after acquiring the new device identifier, the method further includes: judging whether the corresponding relation has equipment size data and an equipment model diagram corresponding to the new equipment identification; if so, reading the equipment size data and the equipment model diagram corresponding to the new equipment identification; rendering the read equipment model diagram in a current interface, and establishing a mapping relation between the rendered equipment model diagram and the read equipment size data; and if not, uploading the new equipment identifier to the server.
In this embodiment, after receiving the device size data and the device model map fed back by the server, the current device may store the device size data and the device model map in a local storage space, and establish a correspondence between the device identifier and the device size data and the device model map. For example, the current device may establish an identification-data model library in which the device identification, the device size data, and the device model map may be recorded, and may establish correspondence between the device identification and the device size data and the device model map.
If the current equipment is used for ranging again, after the equipment identifier is obtained, whether the equipment size data and the equipment model diagram corresponding to the equipment identifier exist in the established corresponding relation can be judged. If the device size data and the device model diagram exist, the corresponding device size data and the device model diagram can be read from the local storage space very quickly, and the read device model diagram is rendered in the current interface, so that the rendering efficiency of the device model diagram is improved, and better experience is provided for a user; and establishing a mapping relation between the rendered device model diagram and the read device size data for subsequent distance measurement. If the device size data does not exist, the device identifier can be sent to the server, so that the server inquires device size data and a device model diagram corresponding to the device identifier; and after receiving the device size data and the device model diagram fed back by the server, the received device size data and the received device model diagram can be stored again, and the corresponding relation between the device identifier and the device size data and the device model diagram is established, so that the locally stored corresponding relation is enriched.
For example, the received device size data, the device model map and the device identifier may be added to the identifier-data model library, and a corresponding relationship between the device identifier and the device size data and the device model map is established to update the identifier-data model library, which is beneficial for the current mobile terminal device to locally obtain the device size data and the device model map.
According to the distance measuring method provided by the embodiment of the invention, the current equipment acquires the equipment identifier of the mobile terminal equipment for distance measurement and uploads the equipment identifier to the server so that the server inquires equipment size data and an equipment model diagram corresponding to the equipment identifier; the current equipment receives equipment size data and an equipment model diagram which are inquired by a server and correspond to the equipment identification, renders the equipment model diagram in a current interface, and establishes a mapping relation between the rendered equipment model diagram and the equipment size data; the current device receives a starting position and an end position which act on the rendered device model diagram at least once, determines an actual distance between the starting position and the end position according to the mapping relation, and can determine a required distance according to the actual distance. The method comprises the steps of rendering an equipment model diagram of the mobile terminal equipment for ranging on an interface, inputting a starting/ending point position corresponding to the starting/ending point position actually measured at least once on the rendered equipment model diagram, obtaining the distance between at least one actually measured starting/ending point position based on the mapping relation between the equipment model diagram and equipment size data, and obtaining the size of a required distance according to at least one actual distance.
Example two
On the basis of the embodiment, the interface rendering and distance measuring steps are optimized, the distance measuring range can be expanded, and the user experience is improved. The present embodiment is the same inventive concept as the distance measuring method proposed in the above embodiments, and reference may be made to the above embodiments for technical details that are not described in detail in the present embodiment.
Fig. 2 shows a flowchart of a distance measuring method according to a second embodiment of the present invention. Referring to fig. 2, a distance measuring method provided in an embodiment of the present invention includes:
s210, acquiring the equipment identifier of the mobile terminal equipment, and uploading the equipment identifier to a server so that the server queries equipment size data and an equipment model diagram corresponding to the equipment identifier.
S220, receiving the equipment size data and the equipment model diagram, rendering the equipment model diagram in the current interface, and establishing a mapping relation between the rendered equipment model diagram and the equipment size data.
And S230, responding to the received measurement dimension, determining first dimension data corresponding to the measurement dimension in the device dimension data, and rendering the slider control corresponding to the measurement dimension in the rendered device model diagram in the current interface.
In this embodiment, the current device may receive user input of the measurement dimension to determine the measurement edge for measurement in the mobile terminal device. In addition, if the current device does not receive the measurement dimension input by the user, a default dimension (for example, a long edge in the model map) in the device model map may also be used as the measurement dimension.
After determining the measurement edge dimension for measurement, the current device may extract, from the device size data, size data of a measurement edge corresponding to the measurement dimension in the real mobile terminal device, that is, first size data corresponding to the measurement dimension. The rendering of the slider control corresponding to the measurement dimension may specifically be rendering the slider control outside the measurement edge corresponding to the measurement dimension in the device model map. Moreover, a corresponding relationship can be established between the pixel position of each pixel point of the slide rail in the slider control and the pixel position of the pixel point of the measurement edge in the device model diagram, for example, the length of the measurement edge in the device model diagram is 1700 pixels, and the length of the slide rail is 850 pixels, so that a corresponding relationship can be established between one pixel point of the slide rail and two pixel points of the measurement edge in the device model diagram, and when the slide rail slides for one pixel position, the corresponding measurement position input on the measurement edge in the device model diagram moves for two pixel positions.
And S240, responding to the received first coefficient, and calculating the product of the first coefficient and the first size data to obtain a first distance.
In this embodiment, when the measurement edge of the real mobile terminal device is used to measure the required distance, and the required distance is greater than the length of the measurement edge, the value of the required distance may be determined in a form of adding several times of the measurement edge to the starting position to the ending position on the remaining measurement edges, and the first coefficient may represent a positive integer multiple of the size data of the measurement edge in the real mobile terminal device. The multiple length of the measuring edge of the real mobile terminal equipment in the required distance, namely the first distance, can be obtained by calculating the product of the first coefficient and the first size value. In addition, when the required distance is less than or equal to the length of the measurement edge, the first coefficient may also have a value of zero.
By receiving the first coefficient, the operation that a user inputs the starting position and the end position on the rendered equipment model graph for many times is avoided, the measurement operation steps are simplified, and the distance measurement efficiency and the user experience are improved.
And S250, responding to the sliding operation of the slider in the slider control, and determining a sliding starting point and a sliding end point.
In this embodiment, the remaining distance in the required distance, which is not the multiple length of the measurement edge of the real mobile terminal device, may be correspondingly represented by the range from the sliding start point to the sliding end point of the slider in the slider control. Due to the fact that the corresponding relation is established between the position of the sliding block and the position on the measurement dimension in the rendered device model graph, the current device can determine the starting point position and the end point position acting on the rendered device model graph according to the sliding starting point and the sliding end point.
For example, if the remaining distance in the real measurement is a range in the middle of the measurement edge in the real mobile terminal device, in response to the sliding operation of the slider in the slider control, the sliding start point and the sliding end point may be determined by taking the slider position input by the user clicking the slide rail for the first time as the sliding start point, taking the slider position input by the user clicking the slide rail for the second time as the sliding end point, or taking the slider position where the user presses the slider from the sliding start point until the user stops pressing the slider as the sliding end point.
For another example, if the remaining distance during the actual measurement is a range measured from the corresponding end of the initial end of the slider while the measurement is performed in the actual mobile terminal device, determining the sliding start point and the sliding end point may be, in response to the sliding operation of the slider in the slider control, using the initial end of the slider in the slider control as the sliding start point, and using the slider position input by the user clicking the slide rail as the sliding end point, or using the slider position where the user presses the slider from the sliding start point until the user stops pressing the slider as the sliding end point.
And S260, determining the actual distance from the sliding starting point to the sliding end point according to the corresponding relation between the position of the sliding block and the position on the measurement dimension in the rendered equipment model diagram and the mapping relation.
The corresponding relation between the position of the slider and the position on the measurement dimension in the rendered equipment model graph can be regarded as the pixel position of the pixel point on the slide rail where the slider is located, and the corresponding relation between the pixel position of the pixel point on the measurement edge in the equipment model graph, and the number of the pixel points on the measurement edge in the rendered equipment model graph corresponding to the sliding starting point to the sliding ending point can be determined according to the corresponding relation. Further, according to the mapping relationship between the rendered device model diagram and the device size data, the value of the actual remaining distance corresponding to the number of the pixel points on the measuring side in the rendered device model diagram, namely the actual distance, can be determined.
And S270, taking the sum of the first distance and the actual distance as a required distance.
In the embodiment of the invention, the value of the required distance can be determined by the way of adding the value of the multiple length of the measuring edge and the value of the starting position to the end position on the rest measuring edge when the required distance is greater than the length of the measuring edge by summing the first distance and the actual distance, thereby simplifying the measuring operation steps and improving the distance measuring efficiency and the user experience.
Optionally, rendering a slider control corresponding to a measurement dimension in the rendered device model diagram in the current interface, including: determining a side length parameter and a position parameter corresponding to a measurement dimension in a picture display control introduced by a rendered equipment model diagram; translating the position parameter by a preset value along a direction perpendicular to the measurement dimension and far away from the rendered equipment model diagram to obtain a target position parameter; and taking the side length parameter and the target position parameter as layout parameters of the slider control, and rendering the slider control in the current interface according to the layout parameters of the slider control.
In this embodiment, the side length parameter and the position parameter corresponding to the measurement dimension in the picture display control imported from the rendered device model map may be regarded as the pixel length of the measurement side corresponding to the measurement dimension in the rendered device model map and the pixel position coordinates of the end points on either side of the measurement side.
The position parameter is translated by a preset value along a direction perpendicular to the measurement dimension and away from the rendered device model diagram, so that the pixel position coordinates of the end points on any side of the slide rail in the slider control outside the measurement edge, that is, the target position parameter, can be obtained, wherein the preset value can be set according to the screen size of the current device, for example, can be set to 100 pixels or 150 pixels, and is not specifically limited herein.
The side length parameter of the measured edge is used as the side length parameter of the slide rail in the slide block control, and the slide block control with the same length as the measured edge in the equipment model drawing can be rendered outside the measured edge according to the pixel position coordinates of the end points on any side of the slide rail in the slide block control. By rendering the slider control with the same length as that in the equipment model diagram, the input sliding starting point and sliding end point can be completely corresponding to the starting point position and the end point position on the measuring edge in the equipment model diagram, and the measuring precision is improved to a certain extent.
On the basis of the embodiment, the current equipment can determine the measuring edge used for measuring in the mobile terminal equipment according to the measuring dimension input by the user, and can input a first coefficient used for expressing the multiple of the measuring edge; the outer side of the measuring edge can be rendered with a corresponding slide block control, and the starting point position and the end point position of the remaining distance except the distance of the measuring edge length multiple can be input through the slide block; and finally, the measured actual distance is the actual distance which is greater than the length of the measuring edge by multiplying the first size data of the measuring edge by a first coefficient and adding the distance between the sliding starting point and the sliding ending point of the sliding block.
In one embodiment, the rendered slider control may preferably be as long as the measurement edge, so that the exact correspondence between the input sliding start and end points and the start and end points on the measurement edge in the device model map improves the measurement accuracy to some extent. In addition, the embodiment of the present invention and the distance measuring method proposed by the above embodiment belong to the same inventive concept, and technical details that are not described in detail in the embodiment can be referred to the above embodiment, and the embodiment has the same beneficial effects as the above embodiment.
EXAMPLE III
On the basis of the embodiment, the distance measurement is optimized when the method is applied to a shopping application scene, the required distance can be measured before shopping, commodities with proper sizes can be automatically recommended according to the measured actual distance, and the user experience is further improved. The present embodiment is the same inventive concept as the distance measuring method proposed in the above embodiments, and reference may be made to the above embodiments for technical details that are not described in detail in the present embodiment.
Fig. 3 shows a flowchart of a distance measuring method according to a third embodiment of the present invention. Referring to fig. 3, a distance measuring method provided in an embodiment of the present invention includes:
s310, responding to the measurement instruction, switching the shopping interface to the measurement interface, and taking the measurement interface as the current interface.
When a user purchases commodities on line by using the traditional shopping application, the shopping application can render a shopping interface according to commodity detail data issued by the server so that the user can know various parameters such as the size, the color or the structure of the commodities. Although the interface presents the size of the commodity, the user cannot know whether the size of the commodity is matched with the required distance, the size of the purchased commodity is not proper easily, the situation that the commodity needs to be returned after receiving the commodity is found, the commodity returning not only increases the purchase cost such as freight charge or damage payment, but also prolongs the time for receiving the required commodity. In addition, when the goods are sold in a limited amount/limited time, the required size cannot be changed, and the shopping experience is greatly influenced.
In this embodiment, in the process of shopping by using the shopping application, when browsing a shopping interface corresponding to a certain commodity, a user may trigger a measurement instruction on the shopping interface. After the current device receives the measurement instruction, the shopping interface can be switched to the measurement interface, and the measurement of the required distance is realized by rendering a device model diagram and other controls for measurement on the measurement interface.
For example, a user may enter a shopping interface for a particular item by clicking on an introduction cover for the item, where the shopping interface may include at least one item introduction map, item title introduction, shipping address, item parameters, selection, and a ranging function. When the user clicks the 'selection' list item, shopping interfaces such as the shopping types, the sizes and the quantities of commodities and the like can be popped up. Before entering the shopping interface to select the size, the user can click the list item of the distance measuring function to trigger a measuring instruction, so that the current equipment is switched to the measuring interface from the shopping interface.
S320, acquiring the equipment identifier of the mobile terminal equipment, and uploading the equipment identifier to the server so that the server can inquire the equipment size data and the equipment model diagram corresponding to the equipment identifier.
S330, receiving the equipment size data and the equipment model diagram, rendering the equipment model diagram in the current interface, and establishing a mapping relation between the rendered equipment model diagram and the equipment size data.
S340, receiving a starting point position and an end point position which act on the rendered device model diagram for at least one time, determining an actual distance between the starting point position and the end point position according to the mapping relation, and determining a required distance according to at least one actual distance.
Wherein, before receiving a start position and an end position acting on the rendered device model map, the method further comprises: responding to the received measurement dimension, determining first dimension data corresponding to the measurement dimension in the equipment dimension data, and rendering a slider control corresponding to the measurement dimension in the rendered equipment model diagram in the current interface;
correspondingly, receiving at least one starting position and one ending position acting on the rendered device model map, determining an actual distance between the starting position and the ending position according to the mapping relation, and determining a required distance according to the at least one actual distance, comprising: in response to the received first coefficient, calculating a product of the first coefficient and the first size data to obtain a first distance; determining a sliding starting point and a sliding end point in response to the sliding operation of a slider in the slider control; determining the actual distance between the sliding starting point and the sliding end point according to the corresponding relation between the position of the sliding block and the position on the measurement dimension in the rendered equipment model diagram and the mapping relation; the sum of the first distance and the actual distance is taken as the required distance.
And S350, obtaining the matched commodity size according to the required distance and the commodity size in the shopping interface.
In the embodiment of the present invention, the current device may obtain each size of the product from the shopping interface, or obtain each size of the product from a product detail interface after the shopping interface is pulled down, or obtain each size of the product from a shopping interface skipped from the shopping interface, and a manner of obtaining each size of the product is not specifically limited herein. And the size of each commodity is set in the shopping interface in advance by the store to which the commodity belongs.
The current mobile terminal equipment selects different matched commodity sizes according to different commodities. For example, when selecting a commodity such as shoes and clothes, the closest commodity size can be searched from the commodity sizes greater than or equal to the required distance (e.g., the actual foot length, the actual shoulder width, and the like) as the commodity size matching the required distance; when selecting goods such as ornaments and furniture placed in a certain space, the closest size of the goods can be searched from the sizes of the goods smaller than or equal to the required distance (for example, the actual space size), and the size of the goods matched with the required distance is not exhaustive. Furthermore, the current device can import the matched commodity size into the rendered text box control for displaying the recommended commodity size in the interface, so as to recommend the commodity with the most appropriate size to the user, and improve the shopping experience of the user.
In addition, when the required distance is user physical sign data (such as foot length data), the current device can also store the corresponding relation between the user and the user physical sign data, so that when a user purchases similar products again, the user can directly match a proper commodity size from the commodity sizes, and the shopping experience of the user is further improved.
Fig. 4 shows a schematic interface diagram in a distance measurement method according to a third embodiment of the present invention.
The user may trigger an instruction to measure foot length on the shopping interface before purchasing shoes using the shopping-like application. The current mobile terminal device can be switched to an interface for measuring the foot length from the shopping interface, and the interface for measuring the foot length is taken as the current interface, as shown in fig. 4. In fig. 4, the current mobile terminal device may call a bottom-layer system native program (native program) to obtain a device identifier of the current mobile terminal device, and then may automatically select a corresponding entry in the drop-down box control 401 according to the obtained device identifier to display, so as to automatically achieve device identifier obtaining.
After receiving the device size data and the device model map corresponding to the device identifier fed back by the server, the current mobile terminal device may render the device model map 402 in the current interface and establish a mapping relationship between the rendered device model map 402 and the device size data. In addition, the current mobile terminal device can also respond to the received measurement dimension (mobile phone length), determine first dimension data corresponding to the measurement dimension in the device dimension data, and render the slider control 403 corresponding to the measurement dimension in the rendered device model diagram in the current interface.
The current mobile terminal device responds to a first coefficient input in a drop-down box control 404 by a user, and calculates a product of the first coefficient and first size data to obtain a first distance; determining a sliding starting point and a sliding end point in response to the sliding operation of a slider in the slider control; determining the actual distance between the sliding starting point and the sliding end point according to the corresponding relation between the position of the sliding block and the position on the measurement dimension in the rendered equipment model diagram and the mapping relation, and importing the actual distance into the text box control 405 for displaying; the sum of the first distance and the actual distance is used as a required distance, and the required distance can be imported into the textbox control 406 to be displayed, so that the foot length of the user can be measured.
On the basis of the embodiment, when a user purchases commodities through a shopping application, the shopping interface can be switched to the measurement interface when a measurement instruction is triggered, an equipment model diagram of the mobile terminal equipment for distance measurement is rendered on the measurement interface, starting/ending positions corresponding to the actually measured starting/ending positions are input on the rendered equipment model diagram, the distance between the actually measured starting/ending positions can be obtained based on the mapping relation between the equipment model diagram and equipment size data, the required distance can be measured before shopping, the commodities with proper sizes can be automatically recommended according to the measured actual distance, and user experience is further improved. In addition, the embodiment of the present invention and the distance measuring method proposed by the above embodiment belong to the same inventive concept, and technical details that are not described in detail in the embodiment can be referred to the above embodiment, and the embodiment has the same beneficial effects as the above embodiment.
Example four
Fig. 5 is a schematic structural diagram of a distance measuring device according to a fourth embodiment of the present invention, which is applicable to a case of measuring a distance, for example, a case of measuring a required distance before a shopping application is used to purchase a commodity. The distance measuring device provided by the invention can realize the distance measuring method provided by the embodiment.
As shown in fig. 5, the distance measuring apparatus according to the embodiment of the present invention includes:
the identifier uploading module 510 is configured to obtain an equipment identifier of the mobile terminal device, and upload the equipment identifier to the server, so that the server queries equipment size data and an equipment model map corresponding to the equipment identifier;
an interface rendering module 520, configured to receive the device size data and the device model map, render the device model map in the current interface, and establish a mapping relationship between the rendered device model map and the device size data;
a distance determining module 530, configured to receive a start position and an end position acting on the rendered device model map at least once, determine an actual distance between the start position and the end position according to the mapping relationship, and determine a required distance according to at least one actual distance.
Optionally, the interface rendering module is further configured to:
before receiving a starting position and an end position acting on the rendered device model diagram, responding to the received measurement dimension, determining first size data corresponding to the measurement dimension in the device size data, and rendering a slider control corresponding to the measurement dimension in the rendered device model diagram in a current interface;
accordingly, the distance determination module is further configured to:
in response to the received first coefficient, calculating a product of the first coefficient and the first size data to obtain a first distance; determining a sliding starting point and a sliding end point in response to the sliding operation of a slider in the slider control; determining the actual distance between the sliding starting point and the sliding end point according to the corresponding relation between the position of the sliding block and the position on the measurement dimension in the rendered equipment model diagram and the mapping relation; the sum of the first distance and the actual distance is taken as the required distance.
Further, the interface rendering module is specifically configured to:
determining a side length parameter and a position parameter corresponding to a measurement dimension in a picture display control introduced by a rendered equipment model diagram; translating the position parameter by a preset value along a direction perpendicular to the measurement dimension and far away from the rendered equipment model diagram to obtain a target position parameter; and taking the side length parameter and the target position parameter as layout parameters of the slider control, and rendering the slider control in the current interface according to the layout parameters of the slider control.
Optionally, the identifier uploading module is specifically configured to:
responding to the selection operation of the items in the drop-down box control in the current interface, and taking the selected items as the equipment identification of the mobile terminal equipment; or, the device identifier of the current mobile terminal device is obtained by calling the system native program of the current mobile terminal device.
Optionally, the interface rendering module is specifically configured to:
acquiring the screen size of the current equipment, and determining the scaling of the equipment model diagram according to the screen size and the picture size of the equipment model diagram; determining layout parameters of the picture display control according to the picture size and the scaling; rendering the picture display control in the current interface according to the layout parameters of the picture display control, and importing the equipment model picture which is scaled according to the scaling into the picture display control for displaying.
Optionally, the distance measuring device further includes:
the storage module is used for storing the equipment size data and the equipment model diagram after receiving the equipment size data and the equipment model diagram and establishing a corresponding relation between the equipment identification and the equipment size data and the equipment model diagram;
correspondingly, the identifier uploading module is further configured to:
after acquiring the new equipment identifier, judging whether equipment size data and an equipment model diagram corresponding to the new equipment identifier exist in the corresponding relation; if so, reading the equipment size data and the equipment model diagram corresponding to the new equipment identification; rendering the read equipment model diagram in a current interface, and establishing a mapping relation between the rendered equipment model diagram and the read equipment size data; and if not, uploading the new equipment identifier to the server.
Alternatively, the distance measuring device may be integrated into a shopping-like application;
correspondingly, the distance measuring device further comprises:
the interface switching module is used for responding to a measurement instruction before acquiring the equipment identifier of the mobile terminal equipment, switching the shopping interface to the measurement interface and taking the measurement interface as the current interface;
correspondingly, the distance measuring device further comprises:
and the commodity matching module is used for obtaining the matched commodity size according to the required distance and the commodity size in the shopping interface after the required distance is determined according to at least one actual distance.
The distance measuring device provided by the embodiment of the invention belongs to the same inventive concept as the distance measuring method provided by the embodiment, technical details which are not described in detail in the embodiment of the invention can be referred to the embodiment, and the embodiment of the invention has the same beneficial effects as the embodiment.
EXAMPLE five
Fig. 6 shows a schematic diagram of a hardware structure of a terminal device according to a fifth embodiment of the present invention. The terminal device in the embodiments of the present invention may include, but is not limited to, a mobile terminal such as a mobile phone, a notebook computer, a digital broadcast receiver, a PDA (personal digital assistant), a PAD (tablet computer), a PMP (portable multimedia player), a vehicle terminal (e.g., a car navigation terminal), and the like, and a fixed terminal such as a digital TV, a desktop computer, and the like. The terminal device shown in fig. 6 is only an example, and should not bring any limitation to the functions and the scope of use of the embodiments of the present invention.
As shown in fig. 6, the terminal device 600 may include a processing means (e.g., a central processing unit, a graphic processor, etc.) 601, which may perform various appropriate actions and processes according to a program stored in a Read-Only Memory (ROM) 602 or a program loaded from a storage means 608 into a Random Access Memory (RAM) 603. In the RAM603, various programs and data necessary for the operation of the terminal apparatus 600 are also stored. The processing device 601, the ROM 602, and the RAM603 are connected to each other via a bus 604. An input/output (I/O) interface 605 is also connected to bus 604.
Generally, the following devices may be connected to the I/O interface 605: input devices 606 including, for example, a touch screen, touch pad, keyboard, mouse, camera, microphone, accelerometer, gyroscope, etc.; output devices 607 including, for example, a Liquid Crystal Display (LCD), a speaker, a vibrator, and the like; storage 608 including, for example, tape, hard disk, etc.; and a communication device 609. The communication means 609 may allow the terminal device 600 to perform wireless or wired communication with other devices to exchange data. While fig. 6 illustrates a terminal apparatus 600 having various means, it is to be understood that not all illustrated means are required to be implemented or provided. More or fewer devices may alternatively be implemented or provided.
In particular, according to an embodiment of the present invention, the processes described above with reference to the flowcharts may be implemented as computer software programs. For example, embodiments of the invention include a computer program product comprising a computer program embodied on a computer-readable medium, the computer program comprising program code for performing the method illustrated in the flow chart. In such an embodiment, the computer program may be downloaded and installed from a network via the communication means 609, or may be installed from the storage means 608, or may be installed from the ROM 602. The computer program, when executed by the processing means 601, performs the above-described functions defined in the method of an embodiment of the invention.
The terminal provided by the embodiment of the present invention and the distance measuring method provided by the above embodiment belong to the same inventive concept, and technical details that are not described in detail in the embodiment of the present invention can be referred to the above embodiment, and the embodiment of the present invention has the same beneficial effects as the above embodiment.
EXAMPLE six
An embodiment of the present invention provides a computer-readable storage medium, on which a computer program is stored, which, when executed by a processor, implements the distance measurement method provided by the above-described embodiment.
It should be noted that the computer readable storage medium mentioned above in the embodiments of the present invention may be a computer readable signal medium or a computer readable storage medium or any combination of the two. A computer readable storage medium may be, for example, but not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any combination of the foregoing. More specific examples of the computer readable storage medium may include, but are not limited to: an electrical connection having one or more wires, a portable computer diskette, a hard disk, a Random Access Memory (RAM), a Read-Only Memory (ROM), an Erasable Programmable Read-Only Memory (EPROM) or FLASH Memory (FLASH), an optical fiber, a portable compact disc Read-Only Memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing. In embodiments of the invention, a computer readable storage medium may be any tangible medium that can contain, or store a program for use by or in connection with an instruction execution system, apparatus, or device. In yet another embodiment of the invention, a computer readable signal medium may comprise a propagated data signal with computer readable program code embodied therein, for example, in baseband or as part of a carrier wave. Such a propagated data signal may take many forms, including, but not limited to, electro-magnetic, optical, or any suitable combination thereof. A computer readable signal medium may also be any computer readable medium that is not a computer readable storage medium and that can communicate, propagate, or transport a program for use by or in connection with an instruction execution system, apparatus, or device. Program code embodied on a computer readable medium may be transmitted using any appropriate medium, including but not limited to: electrical wires, optical cables, RF (radio frequency), etc., or any suitable combination of the foregoing.
In some embodiments, the clients, servers may communicate using any currently known or future developed network Protocol, such as HTTP (HyperText Transfer Protocol), and may interconnect with any form or medium of digital data communication (e.g., a communications network). Examples of communication networks include a local area network ("LAN"), a wide area network ("WAN"), the Internet (e.g., the Internet), and peer-to-peer networks (e.g., ad hoc peer-to-peer networks), as well as any currently known or future developed network.
The computer-readable storage medium may be included in the terminal device or may be separately present without being incorporated in the terminal device.
The terminal device stores one or more programs, and when the one or more programs are executed by the terminal device, the terminal device is enabled to:
acquiring an equipment identifier of the mobile terminal equipment, and uploading the equipment identifier to a server so that the server inquires equipment size data and an equipment model diagram corresponding to the equipment identifier; receiving equipment size data and an equipment model diagram, rendering the equipment model diagram in a current interface, and establishing a mapping relation between the rendered equipment model diagram and the equipment size data; receiving a starting position and an end position which act on the rendered device model graph at least once, determining an actual distance between the starting position and the end position according to the mapping relation, and determining a required distance according to at least one actual distance.
Alternatively, the computer readable medium carries one or more programs which, when executed by the terminal device, cause the terminal device to:
acquiring an equipment identifier of the mobile terminal equipment, and uploading the equipment identifier to a server so that the server inquires equipment size data and an equipment model diagram corresponding to the equipment identifier; receiving equipment size data and an equipment model diagram, rendering the equipment model diagram in a current interface, and establishing a mapping relation between the rendered equipment model diagram and the equipment size data; receiving a starting position and an end position which act on the rendered device model graph at least once, determining an actual distance between the starting position and the end position according to the mapping relation, and determining a required distance according to at least one actual distance.
Computer program code for carrying out operations for aspects of the present invention may be written in any combination of one or more programming languages, including an object oriented programming language such as Java, Smalltalk, C + + or the like and conventional procedural programming languages, such as the "C" programming language or similar programming languages. The program code may execute entirely on the user's computer, partly on the user's computer, as a stand-alone software package, partly on the user's computer and partly on a remote computer or entirely on the remote computer or server. In the case of a remote computer, the remote computer may be connected to the user's computer through any type of network, including a Local Area Network (LAN) or a Wide Area Network (WAN), or the connection may be made to an external computer (for example, through the Internet using an Internet service provider).
The flowchart and block diagrams in the figures illustrate the architecture, functionality, and operation of possible implementations of systems, methods and computer program products according to various embodiments of the present invention. In this regard, each block in the flowchart or block diagrams may represent a module, segment, or portion of code, which comprises one or more executable instructions for implementing the specified logical function(s). It should also be noted that, in some alternative implementations, the functions noted in the block may occur out of the order noted in the figures. For example, two blocks shown in succession may, in fact, be executed substantially concurrently, or the blocks may sometimes be executed in the reverse order, depending upon the functionality involved. It will also be noted that each block of the block diagrams and/or flowchart illustration, and combinations of blocks in the block diagrams and/or flowchart illustration, can be implemented by special purpose hardware-based systems which perform the specified functions or acts, or combinations of special purpose hardware and computer instructions.
The units described in the embodiments of the present invention may be implemented by software or hardware. Where the name of an element does not in some cases constitute a limitation on the element itself.
The functions described herein above may be performed, at least in part, by one or more hardware logic components. For example, without limitation, exemplary types of hardware logic components that may be used include: field Programmable Gate Arrays (FPGAs), Application Specific Integrated Circuits (ASICs), Application Specific Standard Products (ASSPs), systems on a chip (SOCs), Complex Programmable Logic Devices (CPLDs), and the like.
It is to be noted that the foregoing is only illustrative of the preferred embodiments of the present invention and the technical principles employed. It will be understood by those skilled in the art that the present invention is not limited to the particular embodiments illustrated herein, but is capable of various obvious changes, rearrangements and substitutions as will now become apparent to those skilled in the art without departing from the scope of the invention. Therefore, although the present invention has been described in greater detail by the above embodiments, the present invention is not limited to the above embodiments, and may include other equivalent embodiments without departing from the spirit of the present invention, and the scope of the present invention is determined by the scope of the appended claims.

Claims (10)

1. A distance measuring method, characterized by comprising:
acquiring an equipment identifier of mobile terminal equipment, and uploading the equipment identifier to a server so that the server queries equipment size data and an equipment model diagram corresponding to the equipment identifier;
receiving the equipment size data and the equipment model diagram, rendering the equipment model diagram in a current interface, and establishing a mapping relation between the rendered equipment model diagram and the equipment size data;
receiving a starting point position and an end point position which act on the rendered device model diagram for at least one time, determining an actual distance between the starting point position and the end point position according to the mapping relation, and determining a required distance according to at least one actual distance.
2. The method of claim 1, further comprising, prior to receiving a start position and an end position acting on the rendered device model map:
in response to the received measurement dimension, determining first size data corresponding to the measurement dimension in the device size data, and rendering a slider control corresponding to the measurement dimension in the rendered device model map in a current interface;
correspondingly, the receiving a start position and an end position acting on the rendered device model map at least once, determining an actual distance between the start position and the end position according to the mapping relationship, and determining a required distance according to at least one actual distance includes:
in response to the received first coefficient, calculating a product of the first coefficient and the first size data, resulting in a first distance;
responding to the sliding operation of a slider in the slider control, and determining a sliding starting point and a sliding end point;
determining an actual distance between the sliding starting point and the sliding end point according to a corresponding relation between the position of the sliding block and the position on the measurement dimension in the rendered equipment model diagram and the mapping relation;
and taking the sum of the first distance and the actual distance as a required distance.
3. The method of claim 2, wherein rendering a slider control corresponding to the measured dimension in the rendered device model map in a current interface comprises:
determining a side length parameter and a position parameter corresponding to the measurement dimension in a picture display control introduced by a rendered device model diagram;
translating the position parameter by a preset value along a direction perpendicular to the measurement dimension and far away from the rendered equipment model diagram to obtain a target position parameter;
and taking the side length parameter and the target position parameter as layout parameters of a slider control, and rendering the slider control in a current interface according to the layout parameters of the slider control.
4. The method according to claim 1, wherein the obtaining of the device identifier of the mobile terminal device comprises:
responding to the selection operation of the items in the drop-down box control in the current interface, and taking the selected items as the equipment identification of the mobile terminal equipment; alternatively, the first and second electrodes may be,
and acquiring the equipment identifier of the current mobile terminal equipment by calling the system native program of the current mobile terminal equipment.
5. The method of claim 1, wherein the rendering the device model map in a current interface comprises:
acquiring the screen size of the current equipment, and determining the scaling of the equipment model diagram according to the screen size and the picture size of the equipment model diagram;
determining layout parameters of a picture display control according to the picture size and the scaling;
rendering the picture display control in a current interface according to the layout parameters of the picture display control, and importing the equipment model picture which is scaled according to the scaling into the picture display control for displaying.
6. The method of claim 1, further comprising, after said receiving said device dimension data and said device model map:
storing the equipment size data and the equipment model diagram, and establishing a corresponding relation between the equipment identification and the equipment size data and the equipment model diagram;
correspondingly, after acquiring the new device identifier, the method further includes:
judging whether the corresponding relation has equipment size data and an equipment model diagram corresponding to the new equipment identification;
if so, reading the equipment size data and the equipment model diagram corresponding to the new equipment identification; rendering the read equipment model diagram in a current interface, and establishing a mapping relation between the rendered equipment model diagram and the read equipment size data;
and if not, uploading the new equipment identifier to the server.
7. The method of any one of claims 1-6, applied to a shopping-like application;
correspondingly, before the obtaining of the device identifier of the mobile terminal device, the method further includes:
responding to a measurement instruction, switching to a measurement interface from a shopping interface, and taking the measurement interface as a current interface;
correspondingly, after the determining the required distance according to the at least one actual distance, the method further includes:
and obtaining the matched commodity size according to the required distance and the commodity size in the shopping interface.
8. A distance measuring device, comprising:
the device comprises an identifier uploading module, a storage module and a processing module, wherein the identifier uploading module is used for acquiring a device identifier of the mobile terminal device and uploading the device identifier to a server so that the server queries device size data and a device model diagram corresponding to the device identifier;
the interface rendering module is used for receiving the equipment size data and the equipment model diagram, rendering the equipment model diagram in a current interface, and establishing a mapping relation between the rendered equipment model diagram and the equipment size data;
and the distance determining module is used for receiving a starting point position and an end point position acted on the rendered equipment model graph at least once, determining an actual distance between the starting point position and the end point position according to the mapping relation, and determining a required distance according to at least one actual distance.
9. A terminal device, characterized in that the terminal comprises:
one or more processors;
a memory for storing one or more programs;
when executed by the one or more processors, cause the one or more processors to implement the distance measurement method of any of claims 1-7.
10. A computer-readable storage medium, on which a computer program is stored which, when being executed by a processor, carries out the distance measuring method according to any one of claims 1 to 7.
CN202010523504.7A 2020-06-10 2020-06-10 Distance measuring method, device, equipment and storage medium Pending CN113763495A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202010523504.7A CN113763495A (en) 2020-06-10 2020-06-10 Distance measuring method, device, equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202010523504.7A CN113763495A (en) 2020-06-10 2020-06-10 Distance measuring method, device, equipment and storage medium

Publications (1)

Publication Number Publication Date
CN113763495A true CN113763495A (en) 2021-12-07

Family

ID=78785358

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202010523504.7A Pending CN113763495A (en) 2020-06-10 2020-06-10 Distance measuring method, device, equipment and storage medium

Country Status (1)

Country Link
CN (1) CN113763495A (en)

Citations (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR20050035670A (en) * 2003-10-14 2005-04-19 정영진 a
CN105554247A (en) * 2015-12-07 2016-05-04 魅族科技(中国)有限公司 Measuring method, measuring system and terminal
CN107255813A (en) * 2017-06-30 2017-10-17 努比亚技术有限公司 Distance-finding method, mobile terminal and storage medium based on 3D technology
CN108805138A (en) * 2018-04-19 2018-11-13 北京金尺云数科技有限公司 A kind of method that mobile phone photograph calculates foot's data
CN109330106A (en) * 2018-11-01 2019-02-15 成都牛晶科技有限公司 A kind of subscript dimension measurement method based on mobile phone photograph
CN109405736A (en) * 2018-10-09 2019-03-01 东莞市北井光控科技有限公司 Semiconducter IC component size measurement method, device and terminal device
CN109579752A (en) * 2018-11-20 2019-04-05 维沃移动通信有限公司 A kind of measurement method and terminal device
US20200013234A1 (en) * 2017-03-01 2020-01-09 ZOZO, Inc. Size measurement device, management server, user terminal and size measurement system

Patent Citations (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR20050035670A (en) * 2003-10-14 2005-04-19 정영진 a
CN105554247A (en) * 2015-12-07 2016-05-04 魅族科技(中国)有限公司 Measuring method, measuring system and terminal
US20200013234A1 (en) * 2017-03-01 2020-01-09 ZOZO, Inc. Size measurement device, management server, user terminal and size measurement system
CN107255813A (en) * 2017-06-30 2017-10-17 努比亚技术有限公司 Distance-finding method, mobile terminal and storage medium based on 3D technology
CN108805138A (en) * 2018-04-19 2018-11-13 北京金尺云数科技有限公司 A kind of method that mobile phone photograph calculates foot's data
CN109405736A (en) * 2018-10-09 2019-03-01 东莞市北井光控科技有限公司 Semiconducter IC component size measurement method, device and terminal device
CN109330106A (en) * 2018-11-01 2019-02-15 成都牛晶科技有限公司 A kind of subscript dimension measurement method based on mobile phone photograph
CN109579752A (en) * 2018-11-20 2019-04-05 维沃移动通信有限公司 A kind of measurement method and terminal device

Similar Documents

Publication Publication Date Title
US20200366834A1 (en) Automatic guided capturing and presentation of images
CN109492607B (en) Information pushing method, information pushing device and terminal equipment
CN110390569B (en) Content promotion method, device and storage medium
CN110619807B (en) Method and device for generating global thermodynamic diagram
CN111695960A (en) Object recommendation system, method, electronic device and storage medium
US10796032B2 (en) Method and system for space design
CN111967892A (en) Information recommendation method and device
CN111597465A (en) Display method and device and electronic equipment
CN111291258A (en) Recommendation method and device for searching hot words, electronic equipment and readable medium
US10424009B1 (en) Shopping experience using multiple computing devices
CN110211017B (en) Image processing method and device and electronic equipment
CN115600629A (en) Vehicle information two-dimensional code generation method, electronic device and computer readable medium
CN111652675A (en) Display method and device and electronic equipment
US11604904B2 (en) Method and system for space design
CN110647688A (en) Information presentation method and device, electronic equipment and computer readable medium
CN116524088B (en) Jewelry virtual try-on method, jewelry virtual try-on device, computer equipment and storage medium
CN113763495A (en) Distance measuring method, device, equipment and storage medium
CN111310086A (en) Page jump method and device and electronic equipment
JP7342065B2 (en) Information processing device, information processing method, and information processing program
CN115619904A (en) Image processing method, device and equipment
CN112394809A (en) Method, device and communication equipment for realizing augmented reality
CN113076469B (en) Model construction method, data recommendation method and device
US20230214543A1 (en) Method and system for space design
CN108831012B (en) Vending method and device of vending machine
CN110633124A (en) Toolbar display method, apparatus, electronic device and 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