Material node generation method and device, equipment and storage medium
By building the encapsulation node of the octane material node function and the material generation toolbox in Unreal Engine, the problem of low material production efficiency under the traditional method is solved, the target material node is quickly generated, and the work efficiency is improved.
Patent Information
- Application Number
- CN202410975197.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-07-19
- Publication Date
- 2024-09-03
AI Technical Summary
The traditional Unreal Engine's own material node generation method is too low-level, resulting in low material production efficiency. In particular, the production time of complex materials is long, which seriously affects product production efficiency.
Build an encapsulation node of the octane material node function in Unreal Engine, generate a material toolbox by determining the node data, and display the toolbox on the material panel. Users can select node function options to generate target material nodes, such as gradient nodes, without connecting them. Multiple nodes improve work efficiency.
Through the use of encapsulated nodes and material toolboxes, users can quickly generate target material nodes, such as gradient nodes, which improves the efficiency and convenience of material production and reduces the time cost of complex material production.
Smart Images

Figure CN118587314A
Abstract
Description
Technical Field
[0001] The present application relates to the field of computers, and in particular to a material node generation method, device, equipment and storage medium. Background Art
[0002] The traditional UE (Unreal Engine) built-in material node method is too low-level. For example, every time a material is made, for example, to make a gradient node, it is necessary to connect various addition, subtraction, multiplication, vector splitting, sin, and cosine nodes to implement calculations, transformations, and other functions in order to achieve the functions required by the gradient node, resulting in low efficiency. Especially when the material is very complex, each function takes a long time to implement, which seriously affects the efficiency of product production. Summary of the invention
[0003] The embodiments of the present application provide a material node generation method, device, equipment and storage medium to solve at least one problem existing in the related art. The technical solution is as follows: In a first aspect, an embodiment of the present application provides a method for generating a material node, including: In Unreal Engine, build a package node for the octane material node function; Determine the node data of the encapsulated node, generate a material toolbox according to the node data, and display a material panel of the material toolbox, wherein the material panel has a plurality of node function options for a user to select; In response to a selection instruction for the node function option, determining a target node attribute; A target material node is generated on a material panel of the Unreal Engine according to the target node attribute.
[0004] In one embodiment, the encapsulation node for constructing the octane material node function in the Unreal Engine includes: Establishing a functional material node on the material panel of the Unreal Engine; Perform UV splitting in the creating functional material node to obtain floating point values in two axis directions; Performing calculation processing on at least one of the floating-point values to generate a new UV; Adjust the position of the new UV to obtain the encapsulation node of the octane material node function.
[0005] In one implementation, performing arithmetic processing on at least one of the floating-point values to generate a new UV includes: Performing addition or subtraction operations on the floating-point values corresponding to the X-axis direction and the Y-axis direction respectively to obtain a first operation result and a second operation result, wherein the addition operation or the subtraction operation is used to control the offset of the direction; The first operation result and the second operation result are combined to obtain a new UV.
[0006] In one embodiment, the position adjustment process of the new UV to obtain the encapsulation node of the octane material node function includes: Move the center of the new UV to the base position; Obtaining a rotation angle, performing a dot product operation according to the rotation angle, and obtaining a dot product operation result; The dot product operation result is rotated and moved, and a subtraction operation or an addition operation is performed to obtain a package node of the octane material node function.
[0007] In one implementation, determining the node data of the encapsulated node and generating a material toolbox according to the node data includes: Read the data content of the encapsulated node to obtain node data; The node data is processed by Python to generate the material toolbox.
[0008] In one embodiment, the node function options include at least one of a basic material option, a UV class option, a color modification option, a mask option, a basic operator option, and a normal displacement bump option; and in response to a selection instruction for the node function option, determining the target node attribute includes: In response to a selection instruction for at least one of the basic material option, the UV class option, the color modification option, the mask option, the basic operator option, and the normal displacement bump option, a target node attribute is determined, and the selected node function option is highlighted.
[0009] In one embodiment, generating a target material node on a material panel of the Unreal Engine according to the target node attribute includes: Detecting the actual position of the mouse cursor on the material panel of the Unreal Engine; In response to the paste instruction, a target material node is generated at the actual position according to the target node attributes.
[0010] In a second aspect, an embodiment of the present application provides a material node generation device, including: Construction module, used to build encapsulation nodes of octane material node functions in Unreal Engine; A display module, used for determining the node data of the encapsulated node, generating a material toolbox according to the node data, and displaying a material panel of the material toolbox, wherein the material panel has a plurality of node function options for the user to select; A determination module, configured to determine a target node attribute in response to a selection instruction for the node function option; A generation module is used to generate a target material node on a material panel of the Unreal Engine according to the target node attributes.
[0011] In a third aspect, an embodiment of the present application provides an electronic device, comprising: a processor and a memory, wherein the memory stores instructions, and the instructions are loaded and executed by the processor to implement a method in any one of the above-mentioned embodiments.
[0012] In a fourth aspect, an embodiment of the present application provides a computer-readable storage medium, which stores a computer program. When the computer program is executed, the method in any one of the above-mentioned embodiments is implemented.
[0013] The beneficial effects of the above technical solution include at least: By constructing an encapsulation node of the octane material node function in the Unreal Engine, determining the node data of the encapsulation node, and determining the node data by benchmarking the octane material node, a basis is provided for the subsequent generation of a material toolbox; a material toolbox is generated according to the node data, and the material panel of the material toolbox is displayed. The material panel has a number of node function options for users to select, and in response to a selection instruction for the node function option, the target node attribute is determined. According to the target node attribute, a target material node is generated on the material panel of the Unreal Engine. Users can select one or more node function options according to their own needs to finally generate a target material node. For example, when the target material node is a gradient node, it can be realized without connecting various nodes. It is convenient and fast, which is conducive to improving work efficiency.
[0014] The above summary is for illustrative purposes only and is not intended to be limiting in any way. In addition to the illustrative aspects, embodiments and features described above, further aspects, embodiments and features of the present application will be readily apparent by reference to the accompanying drawings and the following detailed description. BRIEF DESCRIPTION OF THE DRAWINGS
[0015] In the accompanying drawings, unless otherwise specified, the same reference numerals throughout the multiple drawings represent the same or similar parts or elements. These drawings are not necessarily drawn to scale. It should be understood that these drawings only depict some embodiments disclosed in the present application and should not be regarded as limiting the scope of the present application.
[0016] Figure 1 This is a schematic diagram of the steps of a material node generation method according to an embodiment of the present application; Figure 2 A schematic diagram of some nodes inside a packaging node according to an embodiment of the present application; Figure 3 This is a schematic diagram of some node data of an embodiment of the present application; Figure 4 This is a schematic diagram of a material toolbox according to an embodiment of the present application; Figure 5 This is a structural block diagram of a material node generation device according to an embodiment of the present application; Figure 6 This is a structural block diagram of an electronic device according to an embodiment of the present application. DETAILED DESCRIPTION
[0017] In the following, only some exemplary embodiments are briefly described. As those skilled in the art will appreciate, the described embodiments may be modified in various ways without departing from the spirit or scope of the present application. Therefore, the drawings and descriptions are considered to be exemplary and non-restrictive in nature.
[0018] Reference Figure 1 , a flow chart of a material node generation method according to an embodiment of the present application is shown, and the material node generation method may at least include steps S100-S400: S100. In Unreal Engine, construct a package node for the octane material node function.
[0019] S200, determining node data of the encapsulated node, generating a material toolbox according to the node data, and displaying a material panel of the material toolbox, wherein the material panel has a plurality of node function options for the user to select.
[0020] S300: In response to a selection instruction for a node function option, determine a target node attribute.
[0021] S400. Generate a target material node on the material panel of the Unreal Engine according to the target node attributes.
[0022] The material node generation method of the embodiment of the present application can be executed by an electronic control unit, controller, processor, etc. of a terminal such as a computer, a mobile phone, a tablet, a vehicle terminal, etc., or can be executed by a cloud server. For example, it can be executed by a computer, or more specifically, it can be executed by an Unreal Engine in a computer.
[0023] The technical solution of the embodiment of the present application is to construct an encapsulation node of the octane material node function in Unreal Engine (UE, Unreal Engine), determine the node data of the encapsulation node, and determine the node data by benchmarking the octane material node, so as to provide a basis for the subsequent generation of a material toolbox; generate a material toolbox according to the node data, and display the material panel of the material toolbox, the material panel has a number of node function options for users to select, and in response to the selection instruction of the node function option, determine the target node attribute, and generate the target material node on the material panel of the Unreal Engine according to the target node attribute. The user can select one or more node function options according to their own needs to finally generate the target material node. For example, when the target material node is a gradient node, it can be realized without connecting various nodes, which is convenient and fast, and is conducive to improving work efficiency.
[0024] It should be noted that the embodiment of the present application is described by taking the target material node to be finally established as a gradient node as an example, which does not constitute a specific limitation.
[0025] In one embodiment, step S100 includes steps S110-S140: S110. Create a functional material node on the material panel of the Unreal Engine.
[0026] Optionally, the user may generate a first creation instruction through a creation operation, and the Unreal Engine creates a functional material node on a material panel of the Unreal Engine in response to the first creation instruction.
[0027] S120. Perform UV splitting in the function material node to obtain floating point values in two axis directions.
[0028] Optionally, the user can click on the functional material node to enter the functional material node, generate a split instruction through the split operation, and the Unreal Engine responds to the split instruction, performs UV splitting in the established functional material node, and obtains floating-point values in two axis directions, such as the floating-point value in the X-axis direction and the floating-point value in the Y-axis direction.
[0029] S130, performing calculation processing on at least one floating point value to generate a new UV.
[0030] Optionally, steps S1301-S1302 are included: S1301, performing addition or subtraction operations on the floating-point values corresponding to the X-axis direction and the Y-axis direction respectively to obtain a first operation result and a second operation result, wherein the addition or subtraction operation is used to control the offset of the direction.
[0031] Optionally, according to the actual desired effect, the user inputs a first operation instruction, and the Unreal Engine responds to the first operation instruction by performing addition or subtraction operations on the floating point values corresponding to the X-axis direction and the Y-axis direction to obtain a first operation result and a second operation result. It should be noted that the addition or subtraction operation is used to control the offset of the direction.
[0032] S1302: According to the first operation result and the second operation result, a new UV is obtained by merging.
[0033] Then, after determining the first operation result and the second operation result, they are merged to obtain a new UV.
[0034] S140, adjusting the position of the new UV to obtain a package node of the octane material node function.
[0035] Optionally, steps S1401-S1403 are included: S1401. Move the center of the new UV to the reference position.
[0036] Optionally, the user can input a second operation instruction, and the Unreal Engine adjusts the position in response to the second operation instruction. For example, the reference position can be adjusted according to actual needs, and taking the reference position as (0, 0) as an example, the center of the new UV is moved to the reference position.
[0037] S1402, obtaining a rotation angle, performing a dot product operation according to the rotation angle, and obtaining a dot product operation result.
[0038] Then, the user inputs the rotation angle according to actual needs, and the Unreal Engine obtains the rotation angle, performs a dot product operation based on the rotation angle, calculates the corresponding positive and negative, and obtains the dot product operation result. For example, if the rotation angle is n, the formula for the dot product operation result is: x'=x*cos(n)+y*sin(n)y'=-x*sin(n)+y*cos(n) Among them, x is the floating point value before moving, x' is the floating point value after moving, y is the floating point value before moving, and y' is the floating point value after moving.
[0039] S1403. Perform rotation and movement according to the dot product operation result, and perform subtraction or addition operation to obtain a package node of the octane material node function.
[0040] Optionally, based on the dot product operation result, the user inputs a third operation instruction according to actual needs, and the Unreal Engine responds to the third operation instruction, performs addition or subtraction to move the rotational position, and then performs a subtraction or addition operation (for example, an addition operation was performed before and a subtraction operation is performed here, and an addition operation was performed before and a subtraction operation is performed here), to obtain the encapsulation node of the octane material node function, that is, the UE encapsulation material node that implements the corresponding octane material node function.
[0041] For example, suppose the UV is a block consisting of (0,1), (0,0), (1,0), (1,1), so first split the floating-point values in the two axis directions, subtract the center of the block (0.5,0.5), that is, the new UV, move it to the base position and rotate it, and then add the center of the block (0.5,0.5) back to the original position, so as to obtain an encapsulated node that can realize the function of rotating linear gradient.
[0042] It should be noted that some of the encapsulated nodes of the octane material node function are as follows Figure 2 As shown, after entering the functional material node, through the above steps S120, S130, S140 and other related operations based on actual needs, one or more basic nodes 21 can be generated accordingly and an output node 22 can be generated, and then a connection between the output node 22 and the basic node 21 is established. After all these nodes are encapsulated, the encapsulated node of the octane material node function is obtained.
[0043] In one embodiment, determining node data of a packaged node and generating a material toolbox according to the node data includes steps S210-S220: S210, read the data content of the encapsulated node to obtain the node data.
[0044] S220. Process the node data through Python to generate a material toolbox.
[0045] In one implementation, the data content of the encapsulation result is read by the Unreal Engine to obtain the node data, and the node data can be recorded in a txt document or a word document, such as Figure 3The following shows some node data. Then, Python is called through the Unreal Engine, and the corresponding content of the node data is copied to the clipboard for Python to process the node data, thereby generating a material toolbox. Among them, taking some nodes as an example: the setting parameters of the input rotate node, the default value of the node is 90, the parameter name is rotate 0_360, and the rotation value defaults to 90 when no value is set; in the linear_gradient group, the output node name is linear_gradient, so the output name is this group; sortpriority is the order of the output nodes, sortpriority is 2, and the rotate 0_360 option is the second one. The rest includes information such as position and GUID global identifier, etc. The node data records the information of all added nodes in the encapsulated node.
[0046] It should be noted that the user can process the node data using Python programming based on actual needs, or program and store it in advance using Python, and use the stored programming content to process the node data when calling Python, thereby generating a material toolbox. The material toolbox is used by users as a plug-in of the Unreal Engine.
[0047] like Figure 4 As shown, in one embodiment, in step S200, the material panel of the material toolbox is displayed, and the material panel has several node function options for the user to select; the node function options include basic material options, UV class options, color modification options, mask options, basic operator options, normal displacement bump options and other options. Other embodiments may include one or more of the above options, which can be adjusted according to actual needs.
[0048] Optionally, basic material options may include but are not limited to PBR material, material blending, water material and other sub-options; UV options may include but are not limited to UV transformation, three-plane projection, cubic projection, box projection and other sub-options; color modification options may include but are not limited to color correction, brightness, gamma, clipping, RGB inversion, contrast, blur, hue saturation, color tone, steps and other sub-options; mask options may include but are not limited to linear gradient, square gradient, circular gradient, angle gradient, checkerboard, noise, dust mask, ambient absorption, shutters, film material, find edge, cartoon, Fresnel, feather edge and other sub-options; basic operator options may include but are not limited to addition, subtraction, multiplication, division and other sub-options, normal displacement bump options may include but are not limited to displacement, normal bump, normal correction, normal blending, normal generation, bump box projection and other sub-options, other options may include but are not limited to mixing, time, wind generation, depth random, mosaic, non-metallic ior, edge fusion, transparency correction and other sub-options.
[0049] In one embodiment, in step S300, specifically, in response to a selection instruction for at least one of the basic material option, UV class option, color modification option, mask option, basic operator option, and normal displacement bump option, the target node attribute is determined, and the selected node function option is highlighted. Optionally, the user can input a selection instruction according to actual needs, select one or more sub-options in the basic material option, one or more sub-options in the UV class option, one or more sub-options in the color modification option, one or more sub-options in the mask option, one or more sub-options in the basic operator option, one or more sub-options in the normal displacement bump option, and one or more sub-options in other options, and the Unreal Engine determines the target node attribute based on the selected sub-options. In the embodiment of the present application, in order to facilitate prompting the user, the node function option selected by the user, specifically each selected sub-option, can be highlighted. For example, highlighting includes but is not limited to bolding, underlining, or color highlighting. In the embodiment of the present application, color highlighting is taken as an example, for example, each selected sub-option is highlighted in red.
[0050] In one implementation, step S400 includes steps S410-S420: S410. Detect the actual position of the mouse cursor on the material panel of the Unreal Engine.
[0051] Optionally, when the user wants to add a node corresponding to the target node attribute at a certain position of the material panel of the Unreal Engine, the user can place the mouse cursor at the corresponding position, and the Unreal Engine detects the actual position of the mouse cursor on the material panel of the Unreal Engine.
[0052] S420. In response to the paste instruction, generate a target material node at the actual position according to the target node attributes.
[0053] Optionally, the user can generate a paste instruction through a paste operation, such as right-clicking and selecting Paste or entering the shortcut key ctrl+v. In response to the paste instruction, the Unreal Engine generates a target material node with the target node attributes at the actual position according to the target node attributes.
[0054] Through the method of the embodiment of the present application, the material node of octane is benchmarked, the node data of the encapsulated node is determined, the encapsulated node data is processed by python, and a plug-in of the material toolbox is generated, so that users can select node function options based on actual needs and generate target node attributes. Compared with the node system that comes with UE, it can solve the problem of complex connection of many nodes and long time consumption to realize a function. At the same time, the material panel of the material toolbox uses Chinese, which is convenient for users to understand the functions, more convenient and with a low threshold for use, helping users improve work efficiency.
[0055] Reference Figure 5 , shows a structural block diagram of a material node generation device according to an embodiment of the present application, the device may include: Construction module, used to build encapsulation nodes of octane material node functions in Unreal Engine; A display module is used to determine the node data of the encapsulated node, generate a material toolbox according to the node data, and display the material panel of the material toolbox, wherein the material panel has a number of node function options for the user to select; A determination module, for determining a target node attribute in response to a selection instruction for a node function option; The generation module is used to generate a target material node on the material panel of the Unreal Engine according to the target node attributes.
[0056] The functions of each module in each device in the embodiments of the present application can be found in the corresponding description in the above method, and will not be repeated here.
[0057] Reference Figure 6 , shows a structural block diagram of an electronic device according to an embodiment of the present application, the electronic device includes: a memory 310 and a processor 320, the memory 310 stores instructions that can be run on the processor 320, and the processor 320 loads and executes the instructions to implement the material node generation method in the above embodiment. The number of the memory 310 and the processor 320 can be one or more.
[0058] In one embodiment, the electronic device further includes a communication interface 330 for communicating with external devices and performing data exchange transmission. If the memory 310, the processor 320 and the communication interface 330 are implemented independently, the memory 310, the processor 320 and the communication interface 330 can be interconnected through a bus and communicate with each other. The bus can be an Industry Standard Architecture (ISA) bus, a Peripheral Component Interconnect (PCI) bus or an Extended Industry Standard Architecture (EISA) bus, etc. The bus can be divided into an address bus, a data bus, a control bus, etc. For ease of representation, Figure 6 Only one thick line is used in the diagram, but this does not mean that there is only one bus or only one type of bus.
[0059] Optionally, in a specific implementation, if the memory 310, the processor 320 and the communication interface 330 are integrated on a chip, the memory 310, the processor 320 and the communication interface 330 can communicate with each other through an internal interface.
[0060] An embodiment of the present application provides a computer-readable storage medium storing a computer program, which, when executed by a processor, implements the material node generation method provided in the above embodiment.
[0061] An embodiment of the present application also provides a chip, which includes a processor for calling and executing instructions stored in the memory from the memory, so that a communication device equipped with the chip executes the method provided by the embodiment of the present application.
[0062] An embodiment of the present application also provides a chip, including: an input interface, an output interface, a processor and a memory, wherein the input interface, the output interface, the processor and the memory are connected via an internal connection path, and the processor is used to execute the code in the memory. When the code is executed, the processor is used to execute the method provided in the embodiment of the application.
[0063] It should be understood that the processor may be a central processing unit (CPU), or other general-purpose processors, digital signal processors (DSP), application specific integrated circuits (ASIC), field programmable gate arrays (FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. A general-purpose processor may be a microprocessor or any conventional processor, etc. It is worth noting that the processor may be a processor supporting the advanced RISC machines (ARM) architecture.
[0064] Further, optionally, the above-mentioned memory may include a read-only memory and a random access memory, and may also include a non-volatile random access memory. The memory may be a volatile memory or a non-volatile memory, or may include both volatile and non-volatile memories. Among them, the non-volatile memory may include 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 include a random access memory (RAM), which is used as an external cache. By way of example but not limitation, many forms of RAM are available. For example, static RAM (SRAM), dynamic random access memory (DRAM), synchronous DRAM (SDRAM), double data rate synchronous dynamic random access memory (DDR SDRAM), enhanced synchronous dynamic random access memory (ESDRAM), synchronous link dynamic random access memory (SLDRAM) and direct rambus RAM (DR RAM).
[0065] In the above embodiments, it can be implemented in whole or in part by software, hardware, firmware or any combination thereof. When implemented using software, it can be implemented in whole or in part in the form of a computer program product. The computer program product includes one or more computer instructions. When the computer program instructions are loaded and executed on a computer, the process or function according to the present application is generated in whole or in part. The computer can be a general-purpose computer, a special-purpose computer, a computer network, or other programmable device. The computer instructions can be stored in a computer-readable storage medium, or transmitted from one computer-readable storage medium to another computer-readable storage medium.
[0066] In the description of this specification, the description with reference to the terms "one embodiment", "some embodiments", "example", "specific example" or "some examples" means that the specific features, structures, materials or characteristics described in conjunction with the embodiment or example are included in at least one embodiment or example of the present application. Moreover, the described specific features, structures, materials or characteristics may be combined in any one or more embodiments or examples in a suitable manner. In addition, those skilled in the art may combine and combine different embodiments or examples described in this specification and the features of different embodiments or examples, unless they are contradictory.
[0067] In addition, the terms "first" and "second" are used for descriptive purposes only and should not be understood as indicating or implying relative importance or implicitly indicating the number of technical features indicated. Therefore, a feature defined as "first" or "second" may explicitly or implicitly include at least one of the features. In the description of this application, the meaning of "plurality" is two or more, unless otherwise clearly and specifically defined.
[0068] Any process or method description in the flow chart or otherwise described herein can be understood to represent a module, fragment or portion of a code including one or more executable instructions for implementing the steps of a specific logical function or process. And the scope of the preferred embodiment of the present application includes other implementations, in which the functions may not be performed in the order shown or discussed, including in a substantially simultaneous manner or in a reverse order according to the functions involved.
[0069] The logic and / or steps represented in the flowchart or otherwise described herein, for example, can be considered as an ordered list of executable instructions for implementing logical functions, which can be embodied in any computer-readable medium for use by an instruction execution system, apparatus or device (such as a computer-based system, a system including a processor or other system that can fetch instructions from an instruction execution system, apparatus or device and execute instructions), or used in combination with these instruction execution systems, apparatuses or devices.
[0070] It should be understood that the various parts of the present application can be implemented with hardware, software, firmware or a combination thereof. In the above embodiments, multiple steps or methods can be implemented with software or firmware stored in a memory and executed by a suitable instruction execution system. All or part of the steps of the above embodiment method can be completed by instructing the relevant hardware through a program, which can be stored in a computer-readable storage medium, and when the program is executed, it includes one of the steps of the method embodiment or a combination thereof.
[0071] In addition, each functional unit in each embodiment of the present application can be integrated into a processing module, or each unit can exist physically separately, or two or more units can be integrated into one module. The above-mentioned integrated module can be implemented in the form of hardware or in the form of a software functional module. If the above-mentioned integrated module is implemented in the form of a software functional module and sold or used as an independent product, it can also be stored in a computer-readable storage medium. The storage medium can be a read-only memory, a disk or an optical disk, etc.
[0072] The above is only a specific implementation of the present application, but the protection scope of the present application is not limited thereto. Any technician familiar with the technical field can easily think of various changes or substitutions within the technical scope disclosed in the present application, which should be included in the protection scope of the present application. Therefore, the protection scope of the present application should be based on the protection scope of the claims.
Claims
1. A material node generation method, characterized in that: include: In Unreal Engine, build a package node for the octane material node function; Determine the node data of the encapsulated node, generate a material toolbox according to the node data, and display a material panel of the material toolbox, wherein the material panel has a plurality of node function options for a user to select; In response to a selection instruction for the node function option, determining a target node attribute; A target material node is generated on a material panel of the Unreal Engine according to the target node attribute.
2. The material node generation method according to claim 1, characterized in that: In Unreal Engine, the encapsulated nodes for constructing the octane material node function include: Establishing a functional material node on the material panel of the Unreal Engine; Perform UV splitting in the creating functional material node to obtain floating point values in two axis directions; Performing calculation processing on at least one of the floating-point values to generate a new UV; Adjust the position of the new UV to obtain the encapsulation node of the octane material node function.
3. The material node generation method according to claim 2, characterized in that: The performing operation processing on at least one of the floating-point values to generate a new UV comprises: Performing addition or subtraction operations on the floating-point values corresponding to the X-axis direction and the Y-axis direction respectively to obtain a first operation result and a second operation result, wherein the addition operation or the subtraction operation is used to control the offset of the direction; The first operation result and the second operation result are combined to obtain a new UV.
4. The material node generation method according to claim 3, characterized in that: The position adjustment process of the new UV is performed to obtain the encapsulation node of the octane material node function, including: Move the center of the new UV to the base position; Obtaining a rotation angle, performing a dot product operation according to the rotation angle, and obtaining a dot product operation result; The dot product operation result is rotated and moved, and a subtraction operation or an addition operation is performed to obtain a package node of the octane material node function.
5. The material node generation method according to any one of claims 1 to 4, characterized in that: Determining the node data of the encapsulated node and generating a material toolbox according to the node data comprises: Read the data content of the encapsulated node to obtain node data; The node data is processed by Python to generate the material toolbox.
6. The material node generation method according to any one of claims 1 to 4, characterized in that: The node function options include at least one of a basic material option, a UV class option, a color modification option, a mask option, a basic operator option, and a normal displacement bump option; and in response to a selection instruction for the node function option, determining a target node attribute includes: In response to a selection instruction for at least one of the basic material option, the UV class option, the color modification option, the mask option, the basic operator option, and the normal displacement bump option, a target node attribute is determined, and the selected node function option is highlighted.
7. The material node generation method according to any one of claims 1 to 4, characterized in that: Generating a target material node on a material panel of the Unreal Engine according to the target node attribute includes: Detecting the actual position of the mouse cursor on the material panel of the Unreal Engine; In response to the paste instruction, a target material node is generated at the actual position according to the target node attributes.
8. A material node generation device, characterized in that: include: Construction module, used to build encapsulation nodes of octane material node functions in Unreal Engine; A display module, used for determining the node data of the encapsulated node, generating a material toolbox according to the node data, and displaying a material panel of the material toolbox, wherein the material panel has a plurality of node function options for the user to select; A determination module, configured to determine a target node attribute in response to a selection instruction for the node function option; A generation module is used to generate a target material node on a material panel of the Unreal Engine according to the target node attributes.
9. An electronic device, characterized in that: include: A processor and a memory, wherein the memory stores instructions, and the instructions are loaded and executed by the processor to implement the method according to any one of claims 1 to 7.
10. A computer-readable storage medium, wherein a computer program is stored in the computer-readable storage medium, and when the computer program is executed, the method according to any one of claims 1 to 7 is implemented.
