A method, device and electronic equipment for drawing three-dimensional virtual pipeline

By using a 3D virtual pipeline drawing method and a Bézier curve algorithm in a virtual environment, the problems of high cost and poor effectiveness in operation training are solved, and efficient virtual training is achieved.

CN118521722BActive Publication Date: 2024-11-05YANTAI JIERUI NETWORK TRADING
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411001054.X
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-07-25
Publication Date
2024-11-05
Estimated Expiration
2044-07-25

AI Technical Summary

Technical Problem

In existing technologies, training operators in actual pipeline connection operations can easily lead to increased training costs and poor results from virtual training.

Method used

A three-dimensional virtual pipeline drawing method is adopted. By determining the location of the target point and using the Bézier curve algorithm, a three-dimensional virtual pipeline is generated to realize virtual training.

Benefits of technology

It reduced training costs and improved training efficiency and effectiveness.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118521722B_ABST
    Figure CN118521722B_ABST
Patent Text Reader

Abstract

The embodiment of the present application provides a method, device and electronic device for drawing a three-dimensional virtual pipeline, which relates to the field of image drawing technology. The method for drawing a three-dimensional virtual pipeline includes: determining a drawing area; determining the position of at least one target point in the drawing area, wherein the target point is the endpoint of the three-dimensional virtual pipeline, and the target point is connected to a preset three-dimensional virtual object; and generating a target three-dimensional virtual pipeline based on a Bezier curve algorithm according to the position of at least one target point. This is to solve the problem in the related art that when conducting actual operation training for operators, the training cost is likely to increase; while virtual training is less and it is difficult to achieve training results.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of image rendering technology, and in particular to a method, device and electronic equipment for rendering a three-dimensional virtual pipeline. Background Art

[0002] At present, many industries need to connect pipelines in practice. For example, in the chemical production process, reactant pipelines and product pipelines need to be connected, and in the medical industry, many instrument pipelines need to be connected. Therefore, when conducting actual operation training for operators, operators are required to connect pipelines by hand. However, due to the lack of experience and poor hands-on ability of some operators, it is likely to cause damage to training consumables and training materials, resulting in increased training costs.

[0003] Virtual training refers to the process in which operators use computer networks to complete specific work tasks in a virtual environment. Virtual training is of great significance in training and teaching. However, there are few virtual trainings on pipeline connection at present, and it is difficult to achieve training results. Summary of the invention

[0004] In view of this, the embodiments of the present application provide a three-dimensional virtual pipeline drawing method, device and electronic device to solve the problem in the related technology that when conducting actual operation training for operators, the training cost is likely to increase; while virtual training is less and it is difficult to achieve training results.

[0005] In a first aspect, an embodiment of the present application provides a method for drawing a three-dimensional virtual pipeline, comprising the following steps:

[0006] Determine the drawing area;

[0007] In the drawing area, determining the position of at least one target point, wherein the target point is an end point of the three-dimensional virtual pipeline, and the target point is connected to a preset three-dimensional virtual object;

[0008] According to the position of at least one target point, a target three-dimensional virtual pipeline is generated based on a Bezier curve algorithm.

[0009] In some possible implementations, determining the position of at least one target point includes:

[0010] Determine the positions of all endpoints of the 3D virtual pipeline.

[0011] In some possible implementations, determining the position of at least one target point includes:

[0012] In response to at least one click operation by the user;

[0013] For each click operation of at least one click operation by the user, the position of the connection point closest to the position of the user's click operation is determined as the position of the target point, wherein the connection point is a point on a preset three-dimensional virtual object.

[0014] In some possible implementations, generating a target three-dimensional virtual pipeline based on a Bezier curve algorithm according to a position of at least one target point includes:

[0015] Generate a target three-dimensional virtual pipeline based on a Bezier curve algorithm according to the position of at least one target point and the position of the historical three-dimensional virtual pipeline;

[0016] The historical three-dimensional virtual pipeline is a three-dimensional virtual pipeline that has been drawn in the drawing area.

[0017] In some possible implementations, generating a target three-dimensional virtual pipeline based on a Bezier curve algorithm according to a position of at least one target point and a position of a historical three-dimensional virtual pipeline includes:

[0018] According to the position of at least one target point and the position of the historical three-dimensional virtual pipeline, a target three-dimensional virtual pipeline group is generated based on a Bezier curve algorithm, and the target three-dimensional virtual pipeline group includes a plurality of three-dimensional virtual pipelines;

[0019] A three-dimensional virtual pipeline with the least overlap with the historical three-dimensional virtual pipeline is determined from the target three-dimensional virtual pipeline group, and the three-dimensional virtual pipeline with the least overlap with the historical three-dimensional virtual pipeline is used as the target three-dimensional virtual pipeline.

[0020] In some possible implementations, the minimum overlap with the historical 3D virtual pipeline means the minimum overlap with the historical 3D virtual pipeline intersections, and / or the minimum overlap with the historical 3D virtual pipeline means the minimum overlap with the area where the historical 3D virtual pipeline is located and the surrounding preset range area.

[0021] In some possible implementations, generating a target three-dimensional virtual pipeline based on a Bezier curve algorithm according to a position of at least one target point and a position of a historical three-dimensional virtual pipeline includes:

[0022] According to the position of at least one target point and the position of the historical three-dimensional virtual pipeline, a target three-dimensional virtual pipeline group is generated based on a Bezier curve algorithm, and the target three-dimensional virtual pipeline group includes a plurality of three-dimensional virtual pipelines;

[0023] In response to the user's selection operation, the three-dimensional virtual pipeline selected by the user is used as the target three-dimensional virtual pipeline.

[0024] In a second aspect, an embodiment of the present application provides a vehicle travel avoidance device, comprising:

[0025] A determination unit, used for determining a drawing area of ​​a three-dimensional virtual pipeline;

[0026] A processing unit is used to determine the position of at least one target point in a drawing area of ​​a three-dimensional virtual pipeline, wherein the target point is an endpoint of the three-dimensional virtual pipeline and is connected to a preset three-dimensional virtual object; and generate a three-dimensional virtual pipeline based on a Bezier curve algorithm according to the position of the at least one target point.

[0027] In a third aspect, an embodiment of the present application provides an electronic device, comprising a memory for storing computer program instructions and a processor for executing the program instructions, wherein when the computer program instructions are executed by the processor, the electronic device is triggered to execute the method provided in the first aspect of the embodiment of the present application.

[0028] In a fourth aspect, an embodiment of the present application provides a computer-readable storage medium, which includes a stored program, wherein when the program is running, the device where the computer-readable storage medium is located is controlled to execute the method provided in the first aspect of the embodiment of the present application.

[0029] By adopting the solution provided in the embodiment of the present application, a virtual pipeline is drawn in a virtual training manner, which can avoid actual operation and thus reduce training costs; and the target three-dimensional virtual pipeline can be generated by determining the position of the target point, which can improve training efficiency. BRIEF DESCRIPTION OF THE DRAWINGS

[0030] In order to more clearly illustrate the technical solutions of the embodiments of the present application, the drawings required for use in the embodiments will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative labor.

[0031] Figure 1 A schematic diagram of a flow chart of a method for drawing a three-dimensional virtual pipeline provided in an embodiment of the present application;

[0032] Figure 2 A schematic diagram of an exemplary method for determining an unconnected endpoint provided in an embodiment of the present application;

[0033] Figure 3 A schematic diagram of a method for determining the position of at least one target point provided in an embodiment of the present application;

[0034] Figure 4 A schematic diagram of a method for generating a target three-dimensional virtual pipeline based on a Bezier curve algorithm provided in an embodiment of the present application;

[0035] Figure 5 A schematic diagram of another method for generating a target three-dimensional virtual pipeline based on a Bezier curve algorithm provided in an embodiment of the present application;

[0036] Figure 6 A schematic diagram of a device for drawing a three-dimensional virtual pipeline provided in an embodiment of the present application;

[0037] Figure 7 A schematic diagram of the structure of an electronic device provided by an embodiment of the present invention. DETAILED DESCRIPTION

[0038] In order to better understand the technical solution of the present application, the embodiments of the present application are described in detail below with reference to the accompanying drawings.

[0039] It should be clear that the described embodiments are only part of the embodiments of the present application, rather than all the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in the field without creative work are within the scope of protection of the present application.

[0040] The terms used in the embodiments of the present application are only for the purpose of describing specific embodiments, and are not intended to limit the present application. The singular forms "a", "said" and "the" used in the embodiments of the present application and the appended claims are also intended to include plural forms, unless the context clearly indicates other meanings.

[0041] It should be understood that the term "and / or" used in this article is only a description of the association relationship of associated objects, indicating that there can be three relationships. For example, A and / or B can represent: A exists alone, A and B exist at the same time, and B exists alone. In addition, the character " / " in this article generally indicates that the associated objects before and after are in an "or" relationship.

[0042] In view of the above problems, the embodiments of the present application provide a method, device and electronic device for drawing a three-dimensional virtual pipeline to solve the problem in the related art that when conducting actual operation training for operators, the training cost is likely to increase; while virtual training is less and it is difficult to achieve training results. The following is a detailed description.

[0043] See also Figure 1 , is a method for drawing a three-dimensional virtual pipeline provided in an embodiment of the present application, such as Figure 1 As shown, the method for drawing a three-dimensional virtual pipeline includes the following steps:

[0044] Step S101: Determine the drawing area.

[0045] It should be noted that since the method for drawing a 3D virtual pipeline provided in the embodiment of the present application is mainly used for training and teaching, and mainly trains operators to connect pipelines, when drawing, a preset 3D virtual object is required in the background, and the preset 3D virtual object is a 3D virtual object of the pipeline to be connected. For example, if the training scenario is to connect medical instrument pipelines, the preset 3D virtual object can be a 3D virtual medical instrument.

[0046] In this way, the drawing area can be an area on the same layer or the same grid as the preset three-dimensional virtual object. For example, the preset three-dimensional virtual object is a pre-drawn object. In this case, the layer or grid area where the preset three-dimensional virtual object is located is a drawable area. Therefore, the area where the preset three-dimensional virtual object is located can be directly used as the drawing area. Alternatively, a new area can be created and the new area can be used as the drawing area, and the new area can be a layer or grid above the preset three-dimensional object. For example, the area where the preset three-dimensional virtual object is located is an undrawable area, such as the three-dimensional virtual object is in picture format, etc. In this case, a new area needs to be created as the drawing area.

[0047] Step S102: Determine the position of at least one target point in the drawing area.

[0048] The target point is an end point of the three-dimensional virtual pipeline, and the target point is located on a preset three-dimensional virtual object.

[0049] It should be noted that, in the embodiments of the present application, the three-dimensional virtual pipeline may be a virtual pipeline having only two endpoints, or may be a virtual pipeline having multiple endpoints.

[0050] Since the method for drawing a three-dimensional virtual pipeline provided in the embodiment of the present application is mainly used for training and teaching, and mainly trains operators on their ability to connect pipelines, and there are two main situations for connecting pipelines. One situation is that some endpoints of the pipeline have been pre-connected, and the other endpoints are not connected. The operator is trained on the ability to connect some endpoints. For example, in a chemical scene, the feed changes with the progress of the reaction, so the container connected to the feed end of the feed pipe will change over time, but the discharge end of the feed pipe is fixedly connected to the reactor, so it is only necessary to train the operator on the ability to connect the feed end. Another situation is that all endpoints of the pipeline are not connected, and the operator is trained on the ability to connect all endpoints. For example, when connecting a circuit, all wires are connected to physical objects, and the operator is trained on the ability to connect physical objects according to the circuit diagram.

[0051] In the embodiments of the present application, no matter which of the above situations is adopted, the endpoints of the three-dimensional virtual pipeline need to be connected to the preset three-dimensional virtual objects to realize the drawing of the three-dimensional virtual pipeline and achieve the purpose of training operators to connect pipelines.

[0052] As a possible implementation, when some endpoints of the pipeline are pre-connected and some endpoints are not connected, in step S102, determining the position of at least one target point includes:

[0053] Identify unconnected endpoints;

[0054] Determine the location of each unconnected endpoint.

[0055] That is, when some endpoints of the pipeline are pre-connected and some are not connected, it is obvious that the pre-connected endpoints do not need to be connected again, and only the unconnected endpoints need to be connected. Therefore, it is necessary to first determine the unconnected endpoints and then determine the position of each unconnected endpoint.

[0056] For example, Figure 2 As shown, when the three-dimensional virtual objects are two feed bins A and one reactor B, the connected endpoints are endpoint 1 and endpoint 2, that is, endpoint 1 and endpoint 2 are fixedly connected to the reactor, and the unconnected endpoints determined are endpoint 3 and endpoint 4. Determining the position of each unconnected endpoint is: determining the position of endpoint 3 and endpoint 4.

[0057] As a possible implementation, when all endpoints of the pipeline are not connected, in step S102, determining the position of at least one target point includes:

[0058] Determine the positions of all endpoints of the 3D virtual pipeline.

[0059] That is, when all endpoints of the pipeline are not connected, it is necessary to examine and train the operator's ability to connect all endpoints on the 3D virtual pipeline. Therefore, it is necessary to determine the positions of all endpoints of the 3D virtual pipeline, otherwise the drawing of the 3D virtual pipeline cannot be completed.

[0060] As a possible implementation, Figure 3 As shown, in step S102, determining the position of at least one target point includes:

[0061] Step S121: responding to at least one click operation by the user;

[0062] Step S122: for each click operation in at least one click operation by the user, the position of the connection point closest to the position of the user's click operation is determined as the position of the target point, wherein the connection point is a point on a preset three-dimensional virtual object.

[0063] That is, the machine responds to the operator's click operation, and according to the click position, determines the position of the connection point on the preset three-dimensional object closest to the click position, and uses the position of the connection point as the position of the target point. Since the embodiment of the present application focuses on training the operator's ability to connect pipelines, the operator is required to operate to connect the unconnected endpoints on the three-dimensional virtual pipeline to the three-dimensional virtual object. For the machine, this is a response to the operator's operation. Since the operator's click position cannot be accurately determined to the connection point position due to problems such as the operator's technique, the position of the connection point closest to the operation position can be determined as the position of the target point, thereby reducing the operator's click accuracy requirements and improving training efficiency.

[0064] In some embodiments, several connection points may be set on a preset three-dimensional virtual object. For example, when the three-dimensional virtual object is a virtual feed bin and the three-dimensional virtual pipeline is a virtual feed pipe, only the feed port may be used as a connection point.

[0065] In some embodiments, all points on the preset three-dimensional virtual object can be used as connection points. For example, when the three-dimensional virtual object is a swimming pool and the three-dimensional virtual pipeline is a water inlet pipe, any point in the swimming pool can be used as a connection point.

[0066] Step S103: Generate a target three-dimensional virtual pipeline based on a Bezier curve algorithm according to the position of at least one target point.

[0067] That is, since the purpose of the embodiment of the present application is to train operators to connect pipelines, in order to improve the learning ability of operators, the generated target three-dimensional virtual pipeline must meet the visualization requirements so that operators can learn the generated target three-dimensional virtual pipeline. The target three-dimensional virtual pipeline generated according to the Bessel algorithm is a naturally curved curve rather than a straight line. Since most actual pipelines are naturally curved curves, the Bessel curve is more conducive to the learning of operators, and the Bessel curve is more beautiful.

[0068] As a possible implementation, in step S103, generating a target three-dimensional virtual pipeline based on a Bezier curve algorithm according to the position of at least one target point includes:

[0069] According to the position of at least one target point and the position of the historical three-dimensional virtual pipeline, a target three-dimensional virtual pipeline is generated based on a Bezier curve algorithm; wherein the historical three-dimensional virtual pipeline is a three-dimensional virtual pipeline drawn in the drawing area.

[0070] That is, since in actual pipeline connection, it is often necessary to connect multiple complex pipelines, and the pipelines may affect each other, in addition to generating the target three-dimensional virtual pipeline based on the target point position of the current target three-dimensional virtual pipeline to be generated, the position of the historical three-dimensional virtual pipeline should also be considered, so that the generated target three-dimensional virtual pipeline can not only meet the position of the target point, but also adapt to the position of the historical three-dimensional virtual pipeline.

[0071] In some embodiments, according to at least one target point position and the position of the historical three-dimensional virtual pipeline, generating the target three-dimensional virtual pipeline based on the Bezier curve algorithm includes: generating the target three-dimensional virtual pipeline based on the Bezier curve algorithm according to at least one target point position, the position of the historical three-dimensional virtual pipeline, and preset rules. For example, in an industrial scene, in order to meet the industrial safety requirements, sometimes two pipelines need to be set up with countermeasures. At this time, the preset rule is that when the historical three-dimensional virtual pipeline is located on the left, the target three-dimensional virtual pipeline can only be wound from the right side of the three-dimensional virtual object. Then, according to at least one target point position, the historical three-dimensional virtual pipeline located on the left, and the preset rules, the target three-dimensional virtual pipeline winding from the right side of the three-dimensional virtual object can be generated based on the Bezier curve algorithm.

[0072] It should be noted that, in addition to being able to affect the target 3D virtual pipeline based on preset rules, the historical 3D virtual pipeline may also affect the target 3D virtual pipeline due to visualization requirements, which is explained in detail below.

[0073] As a possible implementation, in step S103, Figure 4 As shown, generating a target three-dimensional virtual pipeline based on a Bezier curve algorithm according to the position of at least one target point and the position of the historical three-dimensional virtual pipeline includes:

[0074] Step S141: generating a target three-dimensional virtual pipeline group based on a Bezier curve algorithm according to the position of at least one target point and the position of the historical three-dimensional virtual pipeline, wherein the target three-dimensional virtual pipeline group includes a plurality of three-dimensional virtual pipelines;

[0075] Step S142: determining the 3D virtual pipeline with the least overlap with the historical 3D virtual pipeline from the target 3D virtual pipeline group, and taking the 3D virtual pipeline with the least overlap with the historical 3D virtual pipeline as the target 3D virtual pipeline.

[0076] That is, when the position of the target point is determined, sometimes multiple three-dimensional virtual pipelines can be generated. At this time, in order to improve the visualization effect, that is, to facilitate the operator to observe the three-dimensional virtual pipelines in the drawing area, the three-dimensional virtual pipeline with the least overlap with the historical three-dimensional virtual pipeline can be determined from the target three-dimensional virtual pipeline group, and the three-dimensional virtual pipeline can be used as the target three-dimensional virtual pipeline, so that the spacing between multiple three-dimensional virtual pipelines is large, which is convenient for the operator to observe. For example, the target virtual pipeline in the target virtual pipeline group can be wound from the top of the three-dimensional virtual object or from the bottom of the three-dimensional virtual object, but the bottom of the three-dimensional virtual object includes more historical three-dimensional virtual pipelines, and the top of the three-dimensional virtual object includes fewer historical three-dimensional virtual pipelines. In this case, in order to improve the visualization effect, it can be wound from the bottom of the three-dimensional virtual object, that is, to facilitate the operator to observe the three-dimensional virtual pipeline, the target three-dimensional virtual pipeline can be wound from the bottom of the three-dimensional virtual object.

[0077] As a possible implementation, in step S103, the minimum overlap with the historical 3D virtual pipeline means the minimum overlap with the historical 3D virtual pipeline intersections, and / or the minimum overlap with the historical 3D virtual pipeline means the minimum overlap with the area where the historical 3D virtual pipeline is located and the surrounding preset range area.

[0078] It should be noted that the area where the historical three-dimensional virtual pipeline is located is the position occupied by the historical three-dimensional virtual pipeline, and the surrounding preset range area is the area near the historical three-dimensional virtual pipeline. For example, the area 2mm near the historical three-dimensional virtual pipeline can be used as the surrounding preset area.

[0079] As a possible implementation, in step S103, Figure 5 As shown, generating a target three-dimensional virtual pipeline based on a Bezier curve algorithm according to the position of at least one target point and the position of the historical three-dimensional virtual pipeline includes:

[0080] Step S151: generating a target three-dimensional virtual pipeline group based on a Bezier curve algorithm according to the position of at least one target point and the position of the historical three-dimensional virtual pipeline, wherein the target three-dimensional virtual pipeline group includes a plurality of three-dimensional virtual pipelines;

[0081] Step S152: In response to the user's selection operation, the 3D virtual pipeline selected by the user is used as the target 3D virtual pipeline.

[0082] That is, in an embodiment of the present application, in addition to using the three-dimensional virtual pipeline that has the least overlap with the historical three-dimensional virtual pipeline as the target three-dimensional virtual pipeline, the user can also customize the three-dimensional virtual pipeline. In this way, based on the user's selection operation, the three-dimensional virtual pipeline selected by the user can be used as the target three-dimensional virtual pipeline to meet the user's personalized visual needs.

[0083] Exemplarily, a specific method for drawing a three-dimensional virtual pipeline is provided below.

[0084] Step 1: Determine the drawing area: Create a new grid, which is used to replace or cover the grid where the preset three-dimensional virtual object is located, and the new grid is used as the drawing area.

[0085] Step 2: In the drawing area, determine the position of at least one target point: In the drawing area, define the positions of the start point and the end point of the three-dimensional virtual pipeline.

[0086] Step 3: Generate a target three-dimensional virtual pipeline based on a Bezier curve algorithm according to the position of at least one target point. Generate a target three-dimensional virtual pipeline based on a Bezier curve algorithm according to the positions of the start point and the end point of the three-dimensional virtual pipeline.

[0087] See also Figure 6 , is a three-dimensional virtual pipeline drawing device provided in an embodiment of the present application, such as Figure 7 As shown, the device comprises:

[0088] A determination unit 601 is used to determine a drawing area of ​​a three-dimensional virtual pipeline;

[0089] The processing unit 602 is used to determine the position of at least one target point in the drawing area of ​​the three-dimensional virtual pipeline, wherein the target point is the endpoint of the three-dimensional virtual pipeline and the target point is connected to a preset three-dimensional virtual object; and generate the three-dimensional virtual pipeline based on the Bezier curve algorithm according to the position of the at least one target point.

[0090] As a possible implementation manner, the processing unit 602 is specifically configured to determine the positions of all endpoints of the three-dimensional virtual pipeline.

[0091] As a possible implementation method, the processing unit 602 is specifically used to respond to at least one click operation of the user; for each click operation of the user in the at least one click operation, the position of the connection point closest to the position of the user's click operation is determined as the position of the target point, wherein the connection point is a point on a preset three-dimensional virtual object.

[0092] As a possible implementation method, the processing unit 602 is specifically used to generate a target three-dimensional virtual pipeline based on a Bezier curve algorithm according to the position of at least one target point and the position of a historical three-dimensional virtual pipeline; wherein the historical three-dimensional virtual pipeline is a three-dimensional virtual pipeline drawn in the drawing area.

[0093] As a possible implementation method, the processing unit 602 is specifically used to generate a target three-dimensional virtual pipeline group based on a Bezier curve algorithm according to the position of at least one target point and the position of a historical three-dimensional virtual pipeline, and the target three-dimensional virtual pipeline group includes multiple three-dimensional virtual pipelines; determine the three-dimensional virtual pipeline with the least overlap with the historical three-dimensional virtual pipeline from the target three-dimensional virtual pipeline group, and use the three-dimensional virtual pipeline with the least overlap with the historical three-dimensional virtual pipeline as the target three-dimensional virtual pipeline.

[0094] As a possible implementation method, the processing unit 602 is specifically used to generate a target three-dimensional virtual pipeline group based on a Bezier curve algorithm according to the position of at least one target point and the position of a historical three-dimensional virtual pipeline, and the target three-dimensional virtual pipeline group includes multiple three-dimensional virtual pipelines; in response to a user's selection operation, the three-dimensional virtual pipeline selected by the user is used as the target three-dimensional virtual pipeline.

[0095] Corresponding to the above embodiments, the present application also provides an electronic device. Figure 7 A schematic diagram of the structure of an electronic device provided in an embodiment of the present invention, the electronic device 700 may include: a processor 701, a memory 702 and a communication unit 703. These components communicate through one or more buses, and those skilled in the art can understand that the structure of the electronic device shown in the figure does not constitute a limitation on the embodiment of the present invention, it can be a bus structure or a star structure, and can also include more or fewer components than shown in the figure, or combine certain components, or arrange the components differently.

[0096] The communication unit 703 is used to establish a communication channel so that the electronic device can communicate with other devices, receive user data sent by other devices or send user data to other devices.

[0097] The processor 701 is the control center of the electronic device. It uses various interfaces and lines to connect various parts of the entire electronic device. It runs or executes software programs and / or modules stored in the memory 702, and calls data stored in the memory to perform various functions of the electronic device and / or process data. The processor can be composed of an integrated circuit (IC), for example, it can be composed of a single packaged IC, or it can be composed of multiple packaged ICs with the same or different functions. For example, the processor 701 can include only a central processing unit (CPU). In an embodiment of the present invention, the CPU can be a single computing core or multiple computing cores.

[0098] The memory 702 is used to store the execution instructions of the processor 701. The memory 702 can be implemented by any type of volatile or non-volatile storage device or a combination thereof, such as static random access memory (SRAM), electrically erasable programmable read-only memory (EEPROM), erasable programmable read-only memory (EPROM), programmable read-only memory (PROM), read-only memory (ROM), magnetic memory, flash memory, magnetic disk or optical disk.

[0099] When the execution instructions in the memory 702 are executed by the processor 701, the electronic device 700 can execute Figure 1 Some or all of the steps in the illustrated embodiments.

[0100] In a specific implementation, the present invention further provides a computer storage medium, wherein the computer storage medium may store a program, and when the program is executed, the program may include some or all of the steps in each embodiment of the method for drawing a three-dimensional virtual pipeline provided by the present invention. The storage medium may be a disk, an optical disk, a read-only memory (ROM) or a random access memory (RAM), etc.

[0101] Those skilled in the art can clearly understand that the technology in the embodiments of the present invention can be implemented by means of software plus a necessary general hardware platform. Based on this understanding, the technical solution in the embodiments of the present invention can be essentially or partly contributed to the prior art in the form of a software product, which can be stored in a storage medium such as ROM / RAM, a magnetic disk, an optical disk, etc., and includes several instructions for enabling a computer device (which can be a personal computer, a server, or a network device, etc.) to execute the methods described in the various embodiments of the present invention or certain parts of the embodiments.

[0102] In this specification, the same or similar parts between the various embodiments can be referred to each other. In particular, for the device embodiment and the terminal embodiment, since they are basically similar to the method embodiment, the description is relatively simple, and the relevant parts can be referred to the description in the method embodiment.

Claims

1. A method for drawing a three-dimensional virtual pipeline, characterized in that: The steps include: Determine the drawing area; In the drawing area, determining the position of at least one target point, wherein the target point is an end point of a three-dimensional virtual pipeline, and the target point is located on a preset three-dimensional virtual object, and the preset three-dimensional virtual object is a three-dimensional virtual object of the pipeline to be connected; Generate a target three-dimensional virtual pipeline based on a Bezier curve algorithm according to the position of the at least one target point; Generating the target three-dimensional virtual pipeline based on the Bezier curve algorithm according to the position of the at least one target point comprises: Generate a target three-dimensional virtual pipeline based on a Bezier curve algorithm according to the position of at least one target point and the position of the historical three-dimensional virtual pipeline; The historical three-dimensional virtual pipeline is the three-dimensional virtual pipeline drawn in the drawing area; The generating of the target three-dimensional virtual pipeline based on the Bezier curve algorithm according to the position of at least one target point and the position of the historical three-dimensional virtual pipeline comprises: According to the position of at least one target point and the position of the historical three-dimensional virtual pipeline, a target three-dimensional virtual pipeline group is generated based on a Bezier curve algorithm, and the target three-dimensional virtual pipeline group includes a plurality of three-dimensional virtual pipelines; Determine the three-dimensional virtual pipeline with the least overlap with the historical three-dimensional virtual pipeline from the target three-dimensional virtual pipeline group, and use the three-dimensional virtual pipeline with the least overlap with the historical three-dimensional virtual pipeline as the target three-dimensional virtual pipeline; The least overlap with the historical three-dimensional virtual pipeline means having the least intersections with the historical three-dimensional virtual pipeline, and / or the least overlap with the historical three-dimensional virtual pipeline means having the least overlap with the area where the historical three-dimensional virtual pipeline is located and the surrounding preset range area; Or, generating the target three-dimensional virtual pipeline based on the Bezier curve algorithm according to the position of at least one target point and the position of the historical three-dimensional virtual pipeline includes: According to the position of at least one target point and the position of the historical three-dimensional virtual pipeline, a target three-dimensional virtual pipeline group is generated based on a Bezier curve algorithm, and the target three-dimensional virtual pipeline group includes a plurality of three-dimensional virtual pipelines; In response to the user's selection operation, the three-dimensional virtual pipeline selected by the user is used as the target three-dimensional virtual pipeline.

2. The method according to claim 1, characterized in that Determining the position of at least one target point comprises: Determine the positions of all endpoints of the 3D virtual pipeline.

3. The method according to claim 1, characterized in that Determining the position of at least one target point comprises: In response to at least one click operation by the user; For each click operation of the at least one click operation of the user, the position of the connection point closest to the position of the user's click operation is determined as the position of the target point, wherein the connection point is a point on a preset three-dimensional virtual object.

4. A three-dimensional virtual pipeline drawing device, characterized in that: include: A determination unit, used for determining a drawing area of ​​a three-dimensional virtual pipeline; A processing unit is used to determine the position of at least one target point in the drawing area of ​​the three-dimensional virtual pipeline, wherein the target point is an end point of the three-dimensional virtual pipeline, and the target point is connected to a preset three-dimensional virtual object; the preset three-dimensional virtual object is a three-dimensional virtual object of the pipeline to be connected, and the three-dimensional virtual pipeline is generated based on a Bezier curve algorithm according to the position of the at least one target point; Generating the target three-dimensional virtual pipeline based on the Bezier curve algorithm according to the position of the at least one target point comprises: Generate a target three-dimensional virtual pipeline based on a Bezier curve algorithm according to the position of at least one target point and the position of the historical three-dimensional virtual pipeline; The historical three-dimensional virtual pipeline is the three-dimensional virtual pipeline drawn in the drawing area; The generating of the target three-dimensional virtual pipeline based on the Bezier curve algorithm according to the position of at least one target point and the position of the historical three-dimensional virtual pipeline comprises: According to the position of at least one target point and the position of the historical three-dimensional virtual pipeline, a target three-dimensional virtual pipeline group is generated based on a Bezier curve algorithm, and the target three-dimensional virtual pipeline group includes a plurality of three-dimensional virtual pipelines; Determine the three-dimensional virtual pipeline with the least overlap with the historical three-dimensional virtual pipeline from the target three-dimensional virtual pipeline group, and use the three-dimensional virtual pipeline with the least overlap with the historical three-dimensional virtual pipeline as the target three-dimensional virtual pipeline; The least overlap with the historical three-dimensional virtual pipeline means having the least intersections with the historical three-dimensional virtual pipeline, and / or the least overlap with the historical three-dimensional virtual pipeline means having the least overlap with the area where the historical three-dimensional virtual pipeline is located and the surrounding preset range area; Or, generating the target three-dimensional virtual pipeline based on the Bezier curve algorithm according to the position of at least one target point and the position of the historical three-dimensional virtual pipeline includes: According to the position of at least one target point and the position of the historical three-dimensional virtual pipeline, a target three-dimensional virtual pipeline group is generated based on a Bezier curve algorithm, and the target three-dimensional virtual pipeline group includes a plurality of three-dimensional virtual pipelines; In response to the user's selection operation, the three-dimensional virtual pipeline selected by the user is used as the target three-dimensional virtual pipeline.

5. An electronic device, characterized in that: The invention comprises a memory for storing computer program instructions and a processor for executing the program instructions, wherein when the computer program instructions are executed by the processor, the electronic device is triggered to execute the method according to any one of claims 1 to 3.

6. A computer-readable storage medium, characterized in that: The computer-readable storage medium includes a stored program, wherein when the program is executed, the device where the computer-readable storage medium is located is controlled to execute the method according to any one of claims 1 to 3.