3D model printing method, mobile terminal, server and readable storage medium
By acquiring, editing and printing 3D models between the mobile terminal and the server, the problem of difficulty for users in the prior art to perform multi-color 3D printing anytime and anywhere is solved, and printing flexibility and experience are improved.
Patent Information
- Application Number
- CN202410885626.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-07-01
- Publication Date
- 2024-11-15
AI Technical Summary
The existing multi-color 3D printing technology is carried out on the PC side, making it difficult for users to operate anytime, anywhere, reducing the printing experience.
Provide a 3D model printing method. Using mobile terminals and servers, users can obtain, display and edit 3D models on mobile terminals, generate printing parameters, and send parameters to servers for printing, realizing personalized printing by users anytime, anywhere.
It improves users' printing flexibility and experience, and users can preview, edit and print models on mobile terminals, without being restricted by devices, and realize personalized printing needs.
Smart Images

Figure CN118952668A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of 3D printing, and in particular to a 3D model printing method, a mobile terminal, a server and a readable storage medium. Background Art
[0002] At present, multi-color 3D printing is based on open source slicing schemes to color and slice models, and then use the sliced models for printing. However, open source slicing schemes are currently on the PC side. It is difficult for users to perform multi-color printing operations anytime and anywhere without a PC, which reduces the user's printing experience. Summary of the invention
[0003] In view of this, the present application provides a 3D model printing method, a mobile terminal, a server and a readable storage medium, which realizes the need for users to use mobile terminals to print models anytime and anywhere.
[0004] In a first aspect, an embodiment of the present application provides a 3D model printing method, which is applied to a mobile terminal, and the method includes:
[0005] Acquire a target 3D model and display the target 3D model;
[0006] In response to a user's print editing operation on the target 3D model, generating printing parameters of the target 3D model;
[0007] The model is printed according to the printing parameters.
[0008] In a second aspect, an embodiment of the present application provides a 3D model printing method, which is applied to a server, and the method includes:
[0009] In response to a model download request carrying model information, a target 3D model associated with the model information is sent to a mobile terminal, so that the mobile terminal can print and edit the target 3D model to generate printing parameters of the target 3D model;
[0010] The printing parameters are obtained, and the 3D printer is controlled to print the model according to the printing parameters.
[0011] In a third aspect, an embodiment of the present application provides a mobile terminal, which includes a processor and a memory, wherein the memory stores programs or instructions that can be executed on the processor, and when the programs or instructions are executed by the processor, the steps of the method of the first aspect are implemented.
[0012] In a fourth aspect, an embodiment of the present application provides a server, which includes a processor and a memory, wherein the memory stores programs or instructions that can be executed on the processor, and when the programs or instructions are executed by the processor, the steps of the method of the second aspect are implemented.
[0013] In a fifth aspect, an embodiment of the present application provides a readable storage medium, on which a program or instruction is stored, and when the program or instruction is executed by a processor, the steps of the method of the first aspect or the second aspect are implemented.
[0014] In an embodiment of the present application, the mobile terminal obtains the target 3D model from the server and displays the target 3D model, so that the user can preview the target 3D model. The user performs a print editing operation on the target 3D model on the mobile terminal, obtains the printing parameters of the target 3D model, and prints the model according to the printing parameters. In an embodiment of the present application, a print editing operation is performed on the 3D model on the mobile terminal, thereby realizing the printing of the model. The user can edit according to his own needs to realize personalized printing, and the user can use the mobile terminal to print the model anytime and anywhere, without being restricted by the device, thereby improving the printing flexibility.
[0015] The above description is only an overview of the technical solution of the present application. In order to more clearly understand the technical means of the present application, it can be implemented in accordance with the contents of the specification. In order to make the above and other purposes, features and advantages of the present application more obvious and easy to understand, the specific implementation methods of the present application are listed below. BRIEF DESCRIPTION OF THE DRAWINGS
[0016] The drawings described herein are used to provide a further understanding of the present application and constitute a part of the present application. The illustrative embodiments of the present application and their descriptions are used to explain the present application and do not constitute an improper limitation on the present application. In the drawings:
[0017] Figure 1 A schematic diagram showing a flow chart of a 3D model printing method applied to a mobile terminal according to an embodiment of the present application;
[0018] Figure 2 A schematic diagram of the process of automatically coloring a target 3D model according to an embodiment of the present application is shown;
[0019] Figure 3 A structural block diagram of a 3D model printing method applied to a server according to an embodiment of the present application is shown. DETAILED DESCRIPTION
[0020] The following will be combined with the drawings in the embodiments of the present application to clearly describe the technical solutions in the embodiments of the present application. Obviously, the described embodiments are part of the embodiments of the present application, rather than all the embodiments. All other embodiments obtained by ordinary technicians in this field based on the embodiments in the present application belong to the scope of protection of this application.
[0021] The terms "first", "second", etc. in the specification and claims of the present application are used to distinguish similar objects, and are not used to describe a specific order or sequence. It should be understood that the data used in this way can be interchangeable under appropriate circumstances, so that the embodiments of the present application can be implemented in an order other than those illustrated or described here, and the objects distinguished by "first", "second", etc. are generally of one type, and the number of objects is not limited. For example, the first object can be one or more. In addition, "and / or" in the specification and claims represents at least one of the connected objects, and the character " / " generally indicates that the objects associated with each other are in an "or" relationship.
[0022] The 3D model printing method, mobile terminal, server and readable storage medium provided in the embodiments of the present application are described in detail below with reference to the accompanying drawings through specific embodiments and their application scenarios.
[0023] The present application embodiment provides a 3D model printing method applied to a mobile terminal, wherein the mobile terminal includes a mobile phone, a tablet computer, or other portable device with wireless communication capability. Figure 1 As shown, the method includes:
[0024] S101, obtaining a target 3D model, and displaying the target 3D model.
[0025] In this step, the mobile terminal obtains the target 3D model from the server and displays the target 3D model so that the user can preview the target 3D model.
[0026] In one embodiment of the present application, obtaining a target 3D model includes: in response to a user's selection instruction for model information, downloading a target 3D model associated with the model information from a server; wherein the target 3D model is obtained by the server after merging faces of an original 3D model.
[0027] In this embodiment, a plurality of model information is displayed on the mobile terminal, and each model information corresponds to a corresponding 3D model. The user selects the model information on the mobile terminal, that is, inputs a selection instruction for the model information to be printed among the plurality of model information, and the selection instruction includes but is not limited to click input, key input, press input, etc.
[0028] Based on the user's selection instruction, the selected model information is determined, and the mobile terminal sends a model download request carrying the model information to the server. The model information can be a model name, a model number, a model diagram, and other identifiers that can distinguish different models, so that the server can determine the target 3D model with an associated relationship through the information. The mobile terminal downloads the target 3D model associated with the model information from the server to display the target 3D model. The target 3D model can be in .obj, .stl, .dae, 3MF (3D Manufacturing Format) and other formats.
[0029] Through the association relationship between the model information and the target 3D model, the target 3D model that needs to be printed and edited can be accurately downloaded, so that subsequent printing and editing operations can be performed on the target 3D model to meet the user's printing needs.
[0030] It should be noted that the target 3D model is obtained by merging the faces of the original 3D model by the server, that is, the server merges the faces of the original 3D model to reduce the number of faces and vertices of the original 3D model, and obtains the target 3D model and provides it to the mobile terminal. By transmitting the target 3D model after the face merging, the mobile terminal can receive and load the preview model faster, with lower resource usage, and improve the performance of the mobile terminal.
[0031] S102 : In response to a user's print editing operation on a target 3D model, generate print parameters of the target 3D model.
[0032] In this step, the user performs a print editing operation on the target 3D model on the mobile terminal to obtain the print parameters of the target 3D model. In one embodiment, the print editing operation on the target 3D model includes one or more of a coloring editing operation, a transformation editing operation, and a slicing editing operation, and the transformation editing operation includes operations such as rotation, scaling, and translation on the target 3D model.
[0033] When the print editing operation includes a coloring editing operation, the generated printing parameters are coloring parameters; when the print editing operation includes a transform editing operation, the generated printing parameters are model matrix parameters; when the print editing operation includes a slicing editing operation, the generated printing parameters are slicing parameters. Exemplarily, the user first performs a coloring operation on the target 3D model to obtain coloring parameters, and after coloring the target 3D model, the user rotates, scales, translates, and other operations on the target 3D model to obtain model matrix parameters, and then generates slicing parameters through model slicing settings, such as settings for model support, support type, skirt, and other options.
[0034] The embodiments of the present application can perform coloring, transformation, and slicing editing operations on the target 3D model on a mobile terminal, thereby enabling customized printing using a mobile terminal anytime and anywhere.
[0035] S103, printing the model according to the printing parameters.
[0036] In this step, the mobile terminal sends the generated printing parameters to the server, which performs color configuration and slices the original 3D model according to the printing parameters, and stores the sliced file after slicing. At the same time, the server generates a print task and sends the URL (Uniform Resource Locator) of the slice file to the 3D printer. The 3D printer will automatically download the slice file in response to the print task and print the model.
[0037] In the embodiment of the present application, a 3D model is printed and edited on a mobile terminal, thereby realizing model printing. Users can edit according to their own needs to realize personalized printing, and users can use mobile terminals to print models anytime and anywhere without being restricted by devices, thereby improving printing flexibility.
[0038] In one embodiment of the present application, when the print editing operation includes a coloring editing operation, in response to the user's print editing operation on the target 3D model, the print parameters of the target 3D model are generated, including:
[0039] Obtaining the wire color of the consumables receiving device associated with the mobile terminal;
[0040] In response to a user's instruction to select a model component of a target 3D model, determining the model component; and, in response to a user's instruction to select a wire color, determining a first target color corresponding to the model component;
[0041] A coloring parameter including a model component and a first target color corresponding to the model component is generated.
[0042] In this embodiment, after the target 3D model is previewed, the user can perform coloring and editing operations on the target 3D model. The mobile terminal is associated with a consumables receiving device, and the mobile terminal can obtain the wire color of the consumables receiving device.
[0043] The target 3D model includes at least one model component. The user selects one or more model components of the target 3D model. After selecting the model component, the wire color is selected. After the wire color is selected, the first target color corresponding to the selected model component is determined. Alternatively, the wire color can be selected first and then the model component. The present application does not specifically limit the order of selecting the wire color and the model component. Then, the user can continue to select the model component and the wire color in this way until the coloring editing operation is completed, and the color filling of the target 3D model is completed. Finally, the coloring parameters of the model component and the first target color corresponding to the model component are generated.
[0044] In the embodiment of the present application, the wire color of the consumables holding device associated with the mobile terminal is displayed so that the user can select and fill the color of the 3D model, so that the color selected by the user is the wire color of the 3D printer, ensuring that the color of the printed model is consistent with the color selected by the user, avoiding color differences, and saving printing time.
[0045] In one embodiment of the present application, in response to a user's coloring editing operation on a target 3D model, generating coloring parameters of the target 3D model includes:
[0046] Obtaining the wire color of the consumables receiving device associated with the mobile terminal;
[0047] In response to a user's automatic coloring instruction for the target 3D model, a second target color that is the same as the color of a model component of the target 3D model is automatically matched from the wire color of the consumables containing device to generate a coloring parameter including the model component and the second target color corresponding to the model component; wherein the color of the model component is a default color of the model component or a user-defined color for the model component;
[0048] The method further includes:
[0049] If the second target color that is the same as the color of the model component is not matched, the Euclidean distance between the color of the model component and the wire color of the consumable holding device is calculated, and the third target color corresponding to the model component is determined in the wire color based on the Euclidean distance to generate coloring parameters including the model component and the third target color corresponding to the model component.
[0050] In this embodiment, after the target 3D model is previewed, the user can perform coloring and editing operations on the target 3D model. The mobile terminal is associated with a consumables receiving device, and the mobile terminal can obtain the wire color of the consumables receiving device.
[0051] The target 3D model includes at least one model component, and each model component has a corresponding color. The color of the model component can be a default color, that is, the color that the model component already has when the mobile terminal downloads the target 3D model. The color of the model component can also be a user-defined color. For example, the mobile terminal displays a palette module with multiple colors to be selected. The colors to be selected in the palette module can be completely the same as or not completely the same as the wire colors of the consumables holding device. The user selects one or more model components of the target 3D model, and after selecting the model component, selects the color to be selected. Alternatively, the color to be selected can be selected first and then the model component. The present application does not specifically limit the order of selecting the colors to be selected and the model component.
[0052] In response to the user's automatic coloring instruction for the target 3D model, for example, the user clicks the "auto coloring" control to trigger the automatic coloring instruction, and then the second target color that is the same as the color of the model component of the target 3D model is automatically matched from the wire color of the consumables receiving device, that is, a mapping relationship is established between the model component and the wire color to complete the color filling of the target 3D model. Finally, the coloring parameters of the model component and the second target color corresponding to the model component are generated.
[0053] The embodiment of the present application can automatically match the wire color of the consumables containing device with the color of the model component, thereby saving printing time.
[0054] In addition, if there is no color in the wire color of the consumable containing device that is the same as the color of the model component, that is, the second target color that is the same as the color of the model component is not matched, the Euclidean distance between the color of the model component and the wire color of the consumable containing device is calculated, and the third target color is determined from the wire colors of the consumable containing device based on the Euclidean distance. For example, the wire color with the smallest Euclidean distance can be determined as the third target color corresponding to the model component to complete the color filling of the target 3D model.
[0055] Each color is composed of three components: red (R), green (G), and blue (B). The value range of each component is usually 0 to 255. Euclidean distance is a way to measure the "straight-line" distance between two points in a multidimensional space. In the RGB color space, each color can be regarded as a point in a three-dimensional space. For example, the color of the model component is A, and the color of the wire is B. Their RGB values are (R1, G1, B1) and (R2, G2, B2) respectively. Then the Euclidean distance d between A and B = [(R2-R1) 2 +(G2-G1) 2 +(B2-B1) 2 ] 1 / 2 The Euclidean distances between the multiple wire colors and the color of the model component are calculated, and the wire color corresponding to the minimum Euclidean distance is used as the third target color.
[0056] In one embodiment, Figure 2 As shown, the automatic coloring process of the target 3D model may include: receiving an automatic coloring instruction, determining whether the color of the current model component is the same as the color of the wire material for which a mapping relationship has not been established. If they are the same, a mapping relationship is established between the current model component and the same wire material color; if they are not the same, determining whether the color of the current model component is the same as the color of the wire material for which a mapping relationship has been established. If they are the same, a mapping relationship is established between the current model component and the same wire material color. In this way, automatic matching of the current model component and the wire material color of the same color is achieved.
[0057] If the color of the current model component is different from the wire color with an established mapping relationship, it is determined whether there is a wire color that has not been mapped. If so, the wire colors that have not been mapped are matched by color proximity so that a mapping relationship is established between the current model component and the most similar wire color. By determining the most similar color among the wire colors that have not been mapped, the color of the model component can be richer and the use of too many identical colors for coloring can be avoided. If not, all wire colors are matched by color proximity so that a mapping relationship is established between the current model component and the most similar wire color. In this way, it can be ensured that the model component can be colored with the most similar color to meet the coloring needs of users.
[0058] In the embodiment of the present application, the color deviation of the printed model is reduced by finding a wire color that is close to the color of the model parts and then coloring the model.
[0059] In one embodiment of the present application, generating coloring parameters includes: generating coloring parameters in response to a coloring confirmation instruction of a user for a target 3D model; or,
[0060] In response to a user's selection instruction for a model component of a target 3D model and a selection instruction for a wire color, a fourth target color corresponding to the model component is determined, and the color of the model component is modified according to the fourth target color to generate coloring parameters including the model component and the fourth target color corresponding to the model component.
[0061] In this embodiment, during the user's coloring editing process, the mobile terminal displays the target 3D model, allowing the user to preview the colored target 3D model. If the user is satisfied with the manually selected color or the automatically matched color, the coloring confirmation instruction is triggered, for example, the "coloring confirmation" control is clicked to generate coloring parameters for printing. If the user is not satisfied with the manually selected color or the automatically matched color, the color can be manually selected for modification. Specifically, the user selects one or more model components whose colors need to be modified. After selecting the model components, the wire color or the color to be selected is selected. Alternatively, the wire color or the color to be selected can be selected first and then the model components are selected to select the model components whose colors need to be modified and the color to be modified (the fourth target color), and the color modification is implemented to meet the user's color requirements for the model.
[0062] In one embodiment of the present application, in response to a user's selection instruction for a model component of a target 3D model, the method includes: in response to a user's selection operation for a model component of a target 3D model, determining a terminal screen position corresponding to the selection operation, and determining an intersection point between a ray starting from the terminal screen position and the target 3D model, and obtaining group information of the corresponding model component according to the intersection point, wherein the group information includes a vertex set and a facet set, thereby determining the model component. In this way, the model component selected by the user can be accurately obtained, thereby realizing the coloring operation of the model component.
[0063] In one embodiment of the present application, model printing is performed according to printing parameters, including: sending the printing parameters to a server so that the server slices the original 3D model of the target 3D model according to the printing parameters; and controlling the 3D printer to print the model according to the sliced file after the slicing process.
[0064] In this embodiment, the mobile terminal sends the generated printing parameters to the server, and the server performs color configuration and slice processing on the original 3D model according to the printing parameters, and stores the sliced file after the slicing process. At the same time, the server generates a print task and sends the URL of the slice file to the 3D printer. The 3D printer will automatically download the slice file in response to the print task and print the original 3D model.
[0065] It should be noted that when the server performs slicing processing, it slices the original 3D model stored in the server. By using the original 3D model for slicing, a higher model accuracy after slicing can be guaranteed.
[0066] In one embodiment of the present application, the method further includes: in response to the print view instruction, acquiring and displaying model printing process information;
[0067] The method further includes: in response to the print stop instruction, sending a print stop signal to control the 3D printer to stop printing.
[0068] In this embodiment, after the 3D printer downloads the slice file, it will print the model and store the real-time printing process information of the model. The printing process information can also be sent to the server for storage. The printing process information includes printing progress, printing status, printing video information, etc.
[0069] When the user has a need to view the printing process, the print viewing instruction is triggered, such as clicking the "view printing process" control, and the printing process information sent by the 3D printer or server is obtained, and process monitoring or video monitoring of the printing process is realized to meet the user's viewing needs for the printing process.
[0070] When the user wants to stop printing the model, for example, if a printing abnormality is found, the printing operation can be paused, continued, or canceled anytime and anywhere. For example, by clicking the "Stop Printing Process" control, a stop printing signal is sent to the 3D printer to control the 3D printer to stop printing, or a stop printing signal is sent to the server, which is then sent by the server to the 3D printer to control the 3D printer to stop printing, thereby realizing stop printing control anytime and anywhere.
[0071] In one embodiment of the present application, before acquiring the target 3D model and displaying the target 3D model, the method further includes:
[0072] In response to a model building instruction from a user, generating an original 3D model;
[0073] The 3D model file of the original 3D model is sent to the server, wherein the 3D model file includes a model file and / or a material file, so that the server can generate the original 3D model according to the 3D model file and obtain the target 3D model after merging the faces of the original 3D model.
[0074] In this embodiment, the user uses open source modeling software on the mobile terminal to perform modeling and generate the original 3D model. The 3D model file including the model file such as vertex information, patch information, and material information such as brush number and brush color is sent to the server, so that the server can generate the original 3D model according to the model file and the material file. In this way, modeling can be achieved on the mobile terminal, which is convenient for user operation, and the original 3D model can be stored in the server to enrich the model library of the server. In addition, when the user or other users have the need to print the model in the future, they can directly download the model they want to print from the server for printing and editing without having to perform the modeling operation, thereby improving the efficiency of model printing.
[0075] In some embodiments, in addition to sending the 3D model file of the original 3D model to the server for storage, it can also be sent to the cloud space of the mobile terminal for storage, so that the user can use the mobile terminal to download the model anytime and anywhere for printing and editing.
[0076] The embodiments of the present application can perform modeling on a mobile terminal and then send it to a server for storage and processing. When a user has a printing requirement, the model is downloaded from the server, allowing the user to print and edit the 3D model on the mobile terminal, thereby meeting personalized and flexible model printing requirements.
[0077] In one embodiment of the present application, the method further includes: determining the model component in response to a user's selection instruction for a model component of the original 3D model; and determining a default color corresponding to the model component in response to a user's selection instruction for a color to be selected, so as to generate a material file; or
[0078] The historical colored model is obtained, and the default color of the original 3D model is determined according to the coloring parameters of the historical colored model to generate a material file.
[0079] In this embodiment, during the modeling process, you can choose to color different model components of the original 3D model, for example, by coloring them in the modeling software; or, instead of coloring them during the modeling process, you can use open source slicing software to color the model after modeling.
[0080] During the coloring process, the user can select model components, and select brushes and colors in the palette module of the mobile terminal to color the model. After coloring, the color corresponding to the model component is recorded as the default color of the model component, thereby generating material information including brush number, brush color, etc. Alternatively, the coloring parameters of the historically colored model are used to determine the colors of different model components of the original 3D model to color the model. After coloring, the color corresponding to the model component is recorded as the default color of the model component, thereby generating material information including brush number, brush color, etc. The historically colored model can be a model of the same or similar type as the original 3D model, which can be constructed and colored by the current user, or constructed and colored by other users.
[0081] In the embodiment of the present application, the model can be colored on the mobile terminal and then sent to the server for storage and processing. When the user has a printing demand, the model can be downloaded from the server. After downloading, the user can color the model again, or print it according to the default color without coloring, which improves the flexibility of color editing.
[0082] The present application embodiment provides a 3D model printing method applied to a server, such as Figure 3 As shown, the method includes:
[0083] S301, sending the target 3D model to the mobile terminal, so that the mobile terminal can print and edit the target 3D model to generate printing parameters of the target 3D model;
[0084] S302, obtaining printing parameters, and controlling the 3D printer to print the model according to the printing parameters.
[0085] In this embodiment, a plurality of model information is displayed on the mobile terminal, and each model information corresponds to a corresponding target 3D model. The user selects the model information on the mobile terminal, that is, inputs a selection instruction for the model information to be printed among the plurality of model information. Based on the user's selection instruction, the selected model information is determined, and the mobile terminal sends a model download request carrying the model information to the server. The model information may be the model information itself or an identifier of the model information. The server responds to the model download request carrying the model information, determines the target 3D model associated with it based on the model information, and sends the target 3D model associated with the model information to the mobile terminal. The mobile terminal downloads the target 3D model associated with the model information from the server and sends it to the mobile terminal. Through the association relationship between the model information and the target 3D model, the target 3D model that needs to be printed and edited can be accurately downloaded, so that subsequent printing and editing operations can be performed on the target 3D model to meet the user's printing needs.
[0086] After obtaining the target 3D model, the mobile terminal provides a preview for the user. The user can perform print editing operations on the target 3D model on the mobile terminal to generate the printing parameters of the target 3D model. The server obtains the printing parameters, and performs color configuration and slice processing on the original 3D model according to the printing parameters, and stores the sliced files after the slice processing. At the same time, the server generates a print task and sends the URL of the slice file to the 3D printer. The 3D printer will automatically download the slice file in response to the print task and print the model.
[0087] In the embodiment of the present application, the server provides the 3D model to the terminal, and the user performs print and edit operations on the 3D model on the mobile terminal, thereby realizing the printing of the model. The user can edit according to his own needs to realize personalized printing, and the user can use the mobile terminal to print the model anytime and anywhere without being restricted by the device, thereby improving printing flexibility.
[0088] In one embodiment of the present application, before sending the target 3D model to the mobile terminal, the method further includes:
[0089] Obtaining a 3D model file of the original 3D model, the 3D model file including a model file and / or a material file, and parsing the 3D model file to obtain the original 3D model;
[0090] According to the model file, the original 3D model is merged to obtain the target 3D model;
[0091] The target 3D model, the model information of the target 3D model and the original 3D model are stored in association.
[0092] In this embodiment, the user uses open source modeling software on the mobile terminal to perform modeling and generate the original 3D model. The 3D model file including the model file of vertex information, face information, and material information such as brush number and brush color is sent to the server. After the server obtains the 3D model file of the original 3D model, it parses the 3D model file to obtain the original 3D model.
[0093] The server merges the faces of the original 3D model to reduce the number of faces and vertices of the original 3D model, obtains the target 3D model, and establishes an association relationship between the target 3D model, the model information of the target 3D model, and the original 3D model for storage.
[0094] Through this association relationship, the target 3D model can be determined according to the model information when a model download request is obtained, and the original 3D model of the target 3D model can be determined when slicing is performed according to printing parameters, thereby achieving accurate positioning of the corresponding information.
[0095] By performing face merging processing, the number of faces and vertices of the original 3D model is reduced, and the target 3D model obtained after the face merging processing is transmitted to the mobile terminal, so that the mobile terminal can receive and load the preview model faster, occupy less resources, and improve the performance of the mobile terminal.
[0096] In one embodiment of the present application, according to the model file, the original 3D model is merged with faces to obtain the target 3D model, including: determining the vertex pairs to be merged of the original 3D model according to the model file, wherein if there is an edge connection relationship between two vertices and the distance between the two vertices is less than a preset distance, the two vertices are determined to be the vertex pairs to be merged; and the face merging is achieved by iteratively merging the vertex pairs to be merged, and the preset distance can be determined according to the required accuracy of the model. In this way, the facets can be merged quickly, and the loss of model details can be avoided to a certain extent.
[0097] By merging the faces of the original 3D model, the mobile terminal can very quickly download the model with low distortion and small size for preview, which reduces the time required for downloading and improves the performance of the mobile terminal.
[0098] In one embodiment of the present application, controlling a 3D printer to print a model according to printing parameters includes:
[0099] Slice the original 3D model of the target 3D model according to the printing parameters to generate a slice file, and the target 3D model is obtained by merging the facets of the original 3D model;
[0100] Control the 3D printer to print the model according to the slice file.
[0101] In this embodiment, after the server receives the printing parameters sent by the mobile terminal, the server performs color configuration and slices the original 3D model according to the printing parameters, and stores the sliced file after the slicing. At the same time, the server generates a print task and sends the URL of the slice file to the 3D printer. The 3D printer will automatically download the slice file in response to the print task and print the model.
[0102] It should be noted that when the server performs slicing processing, it slices the original 3D model stored in the server. By using the original 3D model for slicing, a higher model accuracy after slicing can be guaranteed.
[0103] In one embodiment of the present application, the method further includes: in response to the print view request, acquiring and sending model printing process information to the mobile terminal;
[0104] The method further includes: in response to the print stop request, sending a print stop signal to the 3D printer to control the 3D printer to stop printing.
[0105] In this embodiment, after the 3D printer downloads the slice file, it will print the original 3D model and store the real-time printing process information of the original 3D model. The printing process information can also be sent to the server for storage. The printing process information includes printing progress, printing status, printing video information, etc.
[0106] When the user has a need to view the printing process, the print viewing instruction is triggered, such as clicking the "view printing process" control, and the server sends the printing process information to the mobile terminal for the user to view, thereby realizing process monitoring or video monitoring of the printing process and meeting the user's viewing needs for the printing process.
[0107] When the user wants to stop printing the model, for example, if a printing anomaly is found, the user can pause, continue, or cancel the printing operation anytime and anywhere. For example, by clicking the "Stop Printing Process" control, a stop printing signal is sent to the server. After receiving the stop printing signal, the server forwards it to the 3D printer to control the 3D printer to stop printing, thus realizing stop printing control anytime and anywhere.
[0108] An embodiment of the present application also provides a mobile terminal, which includes a processor and a memory, and the memory stores programs or instructions that can be run on the processor. When the program or instructions are executed by the processor, the various steps of the above-mentioned 3D model printing method embodiment are implemented, and the same technical effect can be achieved. To avoid repetition, they are not repeated here.
[0109] An embodiment of the present application also provides a server, which includes a processor and a memory, and the memory stores programs or instructions that can be run on the processor. When the program or instructions are executed by the processor, the various steps of the above-mentioned 3D model printing method embodiment are implemented, and the same technical effect can be achieved. To avoid repetition, they are not repeated here.
[0110] The memory included in the mobile terminal or server can be used to store software programs and various data. The memory may mainly include a first storage area for storing programs or instructions and a second storage area for storing data, wherein the first storage area may store an operating system, an application program or instruction required for at least one function (such as a sound playback function, an image playback function, etc.), etc. In addition, the memory may include a volatile memory or a non-volatile memory, or the memory may include both volatile and non-volatile memories. Among them, the non-volatile memory may be a read-only memory (ROM), a programmable read-only memory (PROM), an erasable programmable read-only memory (EPROM), an electrically erasable programmable read-only memory (EEPROM), or a flash memory. The volatile memory may be a random access memory (RAM), a static random access memory (SRAM), a dynamic random access memory (DRAM), a synchronous dynamic random access memory (SDRAM), a double data rate synchronous dynamic random access memory (DDRSDRAM), an enhanced synchronous dynamic random access memory (ESDRAM), a synchronous link dynamic random access memory (SLDRAM) and a direct memory bus random access memory (DRRAM). The memory in the embodiments of the present application includes but is not limited to these and any other suitable types of memory.
[0111] The processor included in the mobile terminal or server may include one or more processing units; optionally, the processor integrates an application processor and a modem processor, wherein the application processor mainly processes operations related to the operating system, user interface, and application programs, and the modem processor mainly processes wireless communication signals, such as a baseband processor. It is understandable that the modem processor may not be integrated into the processor.
[0112] The embodiment of the present application also provides a readable storage medium, on which a program or instruction is stored. When the program or instruction is executed by a processor, each process of the above-mentioned 3D model printing method embodiment is implemented, and the same technical effect can be achieved. To avoid repetition, it will not be repeated here.
[0113] The present application also provides the following embodiments:
[0114] Reference number 1, a 3D model printing method, applied to a mobile terminal, the method comprising:
[0115] Acquire a target 3D model and display the target 3D model;
[0116] In response to a user's print editing operation on the target 3D model, generating printing parameters of the target 3D model;
[0117] The model is printed according to the printing parameters.
[0118] Reference number 2, based on reference number 1, the step of obtaining the target 3D model includes:
[0119] In response to a user's selection instruction for model information, the target 3D model associated with the model information is downloaded from a server; wherein the target 3D model is obtained by the server after merging faces of the original 3D model.
[0120] Reference numeral 3, based on reference numeral 1, the printing editing operation includes at least one of a coloring editing operation, a transformation editing operation, and a slicing editing operation;
[0121] When the print editing operation includes a coloring editing operation, the print parameters include coloring parameters; when the print editing operation includes a transformation editing operation, the print parameters include model matrix parameters; when the print editing operation includes a slicing editing operation, the print parameters include slicing parameters.
[0122] Reference numeral 4, based on reference numeral 3, when the print editing operation includes a coloring editing operation, the generating of the print parameters of the target 3D model in response to the print editing operation of the target 3D model by the user includes:
[0123] Obtaining a wire color of a consumables receiving device associated with the mobile terminal;
[0124] In response to a user's instruction to select a model component of the target 3D model, determining the model component; and in response to a user's instruction to select a wire color, determining a first target color corresponding to the model component;
[0125] A coloring parameter including the model component and a first target color corresponding to the model component is generated.
[0126] Reference numeral 5, based on reference numeral 3, generating coloring parameters of the target 3D model in response to a coloring editing operation of the target 3D model by a user, including:
[0127] Obtaining a wire color of a consumables receiving device associated with the mobile terminal;
[0128] In response to a user's automatic coloring instruction for the target 3D model, automatically matching a second target color that is the same as the color of a model component of the target 3D model from the wire color of the consumables containing device to generate a coloring parameter including the model component and the second target color corresponding to the model component; wherein the color of the model component is a default color of the model component or a user-defined color for the model component;
[0129] The method further comprises:
[0130] If a second target color identical to the color of the model component is not matched, the Euclidean distance between the color of the model component and the wire color of the consumable holding device is calculated, and a third target color corresponding to the model component is determined in the wire color according to the Euclidean distance to generate coloring parameters including the model component and the third target color corresponding to the model component.
[0131] Reference number 6, based on reference number 4 or 5, generating the coloring parameters includes:
[0132] generating the coloring parameters in response to a user's coloring confirmation instruction for the target 3D model; or,
[0133] In response to a user's selection instruction for a model component of the target 3D model and a selection instruction for the wire color, a fourth target color corresponding to the model component is determined, and the color of the model component is modified according to the fourth target color to generate the coloring parameters including the model component and the fourth target color corresponding to the model component.
[0134] Reference number 7, based on reference number 1, printing the model according to the printing parameters includes:
[0135] The printing parameters are sent to a server, so that the server can slice the original 3D model of the target 3D model according to the printing parameters; and the 3D printer is controlled to print the model according to the sliced file after the slice processing.
[0136] Reference number 8, based on reference number 1, the method further includes:
[0137] In response to a print view instruction, obtaining and displaying model printing process information;
[0138] The method further comprises:
[0139] In response to the print stop instruction, a print stop signal is sent to control the 3D printer to stop printing.
[0140] Reference number 9, based on reference number 1, before acquiring the target 3D model and displaying the target 3D model, the method further includes:
[0141] In response to a model building instruction from a user, generating an original 3D model;
[0142] The 3D model file of the original 3D model is sent to the server, wherein the 3D model file includes a model file and / or a material file, so that the server can generate the original 3D model according to the 3D model file and obtain the target 3D model after merging the faces of the original 3D model.
[0143] Reference number 10, based on reference number 9, the method further includes:
[0144] In response to a user's selection instruction for a model component of the original 3D model, determining the model component; and, in response to a user's selection instruction for a color to be selected, determining a default color corresponding to the model component to generate the material file; or,
[0145] A historical colored model is obtained, and a default color of the original 3D model is determined according to a coloring parameter of the historical colored model to generate the material file.
[0146] The present application also provides the following embodiments:
[0147] Reference numeral 11, a 3D model printing method, characterized in that it is applied to a server, and the method comprises:
[0148] Sending the target 3D model to a mobile terminal, so that the mobile terminal can print and edit the target 3D model to generate printing parameters of the target 3D model;
[0149] The printing parameters are obtained, and the 3D printer is controlled to print the model according to the printing parameters.
[0150] Reference number 12, based on reference number 11, before sending the target 3D model to the mobile terminal, the method further includes:
[0151] Acquire a 3D model file of an original 3D model, wherein the 3D model file includes a model file and / or a material file, and parse the 3D model file to obtain the original 3D model;
[0152] According to the model file, merging the original 3D model into faces to obtain the target 3D model;
[0153] The target 3D model, the model information of the target 3D model and the original 3D model are stored in association.
[0154] Reference number 13, based on reference number 12, merging the original 3D model according to the model file to obtain the target 3D model, including:
[0155] Determining a pair of vertices to be merged of the original 3D model according to the model file, wherein if there is an edge connection relationship between two vertices and a distance between the two vertices is less than a preset distance, then determining the two vertices as a pair of vertices to be merged;
[0156] The facets of the original 3D model are merged by iteratively merging the vertex pairs to be merged, so as to obtain the target 3D model.
[0157] Reference number 14, based on reference number 11, controlling the 3D printer to print the model according to the printing parameters includes:
[0158] Slicing the original 3D model of the target 3D model according to the printing parameters to generate a slice file, wherein the target 3D model is obtained by merging the facets of the original 3D model;
[0159] The 3D printer is controlled to print the model according to the slice file.
[0160] Reference number 15, based on reference number 11, the method further includes:
[0161] In response to the print viewing request, acquiring and sending model printing process information to the mobile terminal;
[0162] The method further comprises:
[0163] In response to the print stop request, a print stop signal is sent to the 3D printer to control the 3D printer to stop printing.
[0164] The embodiments of the present application are described above in conjunction with the accompanying drawings, but the present application is not limited to the above-mentioned specific implementation methods. The above-mentioned specific implementation methods are merely illustrative and not restrictive. Under the guidance of the present application, ordinary technicians in this field can also make many forms without departing from the purpose of the present application and the scope of protection of the claims, all of which are within the protection of the present application.
Claims
1. A 3D model printing method, characterized in that: Applied to a mobile terminal, the method comprises: Acquire a target 3D model and display the target 3D model; In response to a user's print editing operation on the target 3D model, generating printing parameters of the target 3D model; The model is printed according to the printing parameters.
2. The method according to claim 1, characterized in that The step of obtaining the target 3D model comprises: In response to a user's selection instruction for model information, the target 3D model associated with the model information is downloaded from a server; wherein the target 3D model is obtained by the server after merging faces of the original 3D model.
3. The method according to claim 1, characterized in that The printing editing operation includes at least one of a coloring editing operation, a transformation editing operation, and a slicing editing operation; When the print editing operation includes a coloring editing operation, the print parameters include coloring parameters; when the print editing operation includes a transform editing operation, the print parameters include model matrix parameters; when the print editing operation includes a slicing editing operation, the print parameters include slicing parameters; When the print editing operation includes a coloring editing operation, generating the printing parameters of the target 3D model in response to the print editing operation of the target 3D model by the user includes: Obtaining a wire color of a consumables receiving device associated with the mobile terminal; In response to a user's instruction to select a model component of the target 3D model, determining the model component; and in response to a user's instruction to select a wire color, determining a first target color corresponding to the model component; generating coloring parameters including the model component and a first target color corresponding to the model component; The step of generating coloring parameters of the target 3D model in response to a coloring editing operation of the target 3D model by a user includes: Obtaining a wire color of a consumables receiving device associated with the mobile terminal; In response to a user's automatic coloring instruction for the target 3D model, automatically matching a second target color that is the same as the color of a model component of the target 3D model from the wire color of the consumables containing device to generate a coloring parameter including the model component and the second target color corresponding to the model component; wherein the color of the model component is a default color of the model component or a user-defined color for the model component; The method further comprises: If a second target color identical to the color of the model component is not matched, a Euclidean distance between the color of the model component and the wire color of the consumables containing device is calculated, and a third target color corresponding to the model component is determined in the wire color according to the Euclidean distance, so as to generate a coloring parameter including the model component and the third target color corresponding to the model component; The generating of the coloring parameters comprises: generating the coloring parameters in response to a user's coloring confirmation instruction for the target 3D model; or, In response to a user's selection instruction for a model component of the target 3D model and a selection instruction for the wire color, a fourth target color corresponding to the model component is determined, and the color of the model component is modified according to the fourth target color to generate the coloring parameters including the model component and the fourth target color corresponding to the model component.
4. The method according to claim 1, characterized in that: Printing the model according to the printing parameters includes: Sending the printing parameters to a server, so that the server can slice the original 3D model of the target 3D model according to the printing parameters; Control the 3D printer to print the model according to the sliced file after slicing.
5. The method according to claim 1, characterized in that The method further comprises: In response to the print view instruction, obtaining and displaying the model printing process information; The method further comprises: In response to the print stop instruction, sending a print stop signal to control the 3D printer to stop printing; Before acquiring the target 3D model and displaying the target 3D model, the method further includes: In response to a model building instruction from a user, generating an original 3D model; Sending a 3D model file of the original 3D model to a server, wherein the 3D model file includes a model file and / or a material file, so that the server generates the original 3D model according to the 3D model file and obtains the target 3D model after merging the faces of the original 3D model; The method further comprises: In response to a user's selection instruction for a model component of the original 3D model, determining the model component; and, in response to a user's selection instruction for a color to be selected, determining a default color corresponding to the model component to generate the material file; or, A historical colored model is obtained, and a default color of the original 3D model is determined according to a coloring parameter of the historical colored model to generate the material file.
6. A 3D model printing method, characterized in that: Applied to a server, the method comprises: Sending the target 3D model to a mobile terminal, so that the mobile terminal can print and edit the target 3D model to generate printing parameters of the target 3D model; The printing parameters are obtained, and the 3D printer is controlled to print the model according to the printing parameters.
7. The method according to claim 6, characterized in that Before sending the target 3D model to the mobile terminal, the method further includes: Acquire a 3D model file of an original 3D model, wherein the 3D model file includes a model file and / or a material file, and parse the 3D model file to obtain the original 3D model; According to the model file, merging the original 3D model into faces to obtain the target 3D model; The target 3D model, the model information of the target 3D model and the original 3D model are stored in association; The step of merging the original 3D model according to the model file to obtain the target 3D model includes: Determining a pair of vertices to be merged of the original 3D model according to the model file, wherein if there is an edge connection relationship between two vertices and a distance between the two vertices is less than a preset distance, then determining the two vertices as a pair of vertices to be merged; Merging the facets of the original 3D model by iteratively merging the vertex pairs to be merged to obtain the target 3D model; The step of controlling the 3D printer to print the model according to the printing parameters comprises: Slicing the original 3D model of the target 3D model according to the printing parameters to generate a slice file, wherein the target 3D model is obtained by merging the facets of the original 3D model; Controlling the 3D printer to print the model according to the slice file; The method further comprises: In response to the print viewing request, acquiring and sending model printing process information to the mobile terminal; The method further comprises: In response to the print stop request, a print stop signal is sent to the 3D printer to control the 3D printer to stop printing.
8. A mobile terminal, characterized in that: The method comprises a processor and a memory, wherein the memory stores a program or instruction running on the processor, and when the program or instruction is executed by the processor, the steps of the 3D model printing method according to any one of claims 1 to 5 are implemented.
9. A server, characterized in that: It comprises a processor and a memory, wherein the memory stores a program or instruction running on the processor, and when the program or instruction is executed by the processor, the steps of the 3D model printing method as claimed in claim 6 or 7 are implemented.
10. A readable storage medium having a program or instruction stored thereon, characterized in that: When the program or instruction is executed by a processor, the steps of the 3D model printing method according to any one of claims 1 to 7 are implemented.
