Vr-based electron beam generation method, apparatus, and medium

By generating a 3D model of the electron beam in a VR environment and performing image processing, the scattering effect and intensity distribution of the electron beam are simulated. This solves the problems of insufficient physical realism and low dynamic adjustment efficiency in traditional solutions, and achieves efficient and realistic electron beam visualization and cross-platform compatibility.

CN121639924BActive Publication Date: 2026-06-19UNIV OF SCI & TECH BEIJING
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202511755440.2
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2025-11-26
Publication Date
2026-06-19
Estimated Expiration
2045-11-26

AI Technical Summary

Technical Problem

Traditional electron beam visualization solutions lack physical realism in VR environments, have low efficiency in dynamic adjustment, are difficult to accurately simulate the intensity distribution and scattering effects of electron beams, and require complete reconstruction of the 3D model when parameters are changed, resulting in redundant calculations.

Method used

The original electron beam 3D model is generated in a VR environment. The electron scattering effect and intensity distribution are simulated by image blurring and brightness processing. The texture is locally updated by using position mapping relationship to avoid reconstructing the 3D model. The influence of optical elements is simulated by combining local spatial coordinate system and nonlinear displacement function.

Benefits of technology

It enables the faithful visualization of the physical properties of electron beams in VR environments, improves the real-time performance and interactive efficiency of dynamic parameter adjustment, reduces the computing power requirements of VR devices, and supports deployment on mobile and lightweight devices.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121639924B_ABST
    Figure CN121639924B_ABST
Patent Text Reader

Abstract

This invention relates to the field of VR technology, specifically to a VR-based electron beam generation method, device, and medium. The method includes: generating a corresponding original electron beam 3D model in a VR environment based on electron beam parameters; determining the positional mapping relationship between the predefined VR environment and the original 2D image data; performing image blurring and brightness processing according to the electron beam parameters to obtain updated 2D image data; and mapping the updated 2D image data as a texture onto the surface of the original electron beam 3D model to generate a standard electron beam 3D model in the VR environment. By simulating electron scattering effects through image blurring, an edge blurring effect conforming to physical laws is generated. Furthermore, by mapping the intensity distribution through image brightness processing, the electron beam in the VR environment exhibits realistic optical characteristics of a bright center and gradually weakening edges, thereby achieving faithful visualization of the physical properties of the electron beam.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to a VR-based electron beam generation method, device, and medium, belonging to the technical field of VR. Background Technology

[0002] With the development of technology, people can use virtual reality (VR) environments to observe and interact with various scenarios. Taking electron beam visualization as an example, people can observe electron beams in a VR environment, thereby learning in detail about the operating principles of electron microscopes and the influence of electron beam parameters.

[0003] However, traditional electron beam visualization methods still have some shortcomings:

[0004] 1. Insufficient physical realism: Traditional solutions rely on simplified geometric models (e.g., cylinders) to directly render electron beams, which makes it difficult to accurately simulate the intensity distribution and scattering effects of electron beams, resulting in discrepancies between the electron beams in VR scenes and real electron microscope observations.

[0005] 2. Inefficient dynamic adjustment: Traditional solutions require a complete reconstruction of the 3D model when parameters change, which generates redundant calculations, especially in scenarios involving fine-tuning of position. Summary of the Invention

[0006] This invention addresses the shortcomings of existing technologies by providing a VR-based electron beam generation method, device, and medium.

[0007] The technical solution of this invention to solve the above-mentioned technical problems is as follows: A VR-based electron beam generation method, comprising:

[0008] Obtain the electron beam parameters input by the user, and generate the corresponding original electron beam 3D model in the VR environment based on the electron beam parameters;

[0009] Acquire preset raw 2D image data and determine the positional mapping relationship between the predefined VR environment and the raw 2D image data;

[0010] Based on the electron beam parameters, image blurring and image brightness processing are performed to obtain updated 2D image data;

[0011] Based on the position mapping relationship, the updated 2D image data is used as a texture and mapped onto the surface of the original electron beam 3D model to generate a standard electron beam 3D model in the VR environment.

[0012] The beneficial effects of this invention are: 1. By simulating the electron scattering effect through image blurring processing, an edge blurring effect that conforms to physical laws is generated, and by mapping the intensity distribution through image brightness processing, the electron beam in the VR environment presents the real optical characteristics of being bright at the center and gradually weakening at the edges, thereby realizing the true visualization of the physical properties of the electron beam.

[0013] 2. When the position of the electron beam changes, the texture is locally updated based on the position mapping relationship and symmetric difference calculation, avoiding the reconstruction of the 3D model, significantly improving the interaction efficiency, and realizing the real-time optimization of dynamic parameter adjustment.

[0014] 3. Physical calculations are offloaded to the 2D image layer, with the 3D model only handling texture mapping, reducing the computing power requirements of VR devices, supporting deployment on mobile and lightweight VR devices, and ensuring cross-platform compatibility.

[0015] Based on the above technical solution, the present invention can be further improved as follows:

[0016] Furthermore, based on the electron beam parameters, a corresponding original electron beam 3D model is generated in the VR environment, specifically including:

[0017] Based on the electron beam parameters, the corresponding position information, size information, orientation information, and intensity information are determined in the VR environment;

[0018] Based on the location information and the orientation information, a local spatial coordinate system is established in the VR environment;

[0019] Based on the location information and the size information, a corresponding first 3D action area is determined, and based on the direction information, the first 3D action area is extended and superimposed to obtain a second 3D action area;

[0020] Based on the intensity information, the second 3D action area is visually filled to generate the corresponding original electron beam 3D model.

[0021] The beneficial effects of adopting the above-mentioned further solutions are:

[0022] By specifying the position, size, orientation, and intensity information of the electron beam, a realistic 3D action area can be constructed, thereby generating a qualified original 3D electron beam model. This model generation method is more scientific and reasonable, providing an accurate and reliable foundation for the subsequent generation of standard electron beam 3D models. Position information ensures the accurate placement of the electron beam in the VR environment; size information determines the scale of the electron beam; orientation information determines the propagation direction of the electron beam; and intensity information reflects the energy distribution of the electron beam. These information elements work together to make the generated original electron beam 3D model more physically realistic and accurate, contributing to improved quality and effectiveness of the entire electron beam visualization process. Furthermore, establishing a local spatial coordinate system facilitates precise description and calculation of the spatial position and orientation of the electron beam, simplifying subsequent processing and operations.

[0023] Furthermore, the method also includes:

[0024] Bind the second 3D action area to the original electron beam 3D model;

[0025] It is determined that the electron beam parameters have been adjusted, and the type of parameter adjustment is determined;

[0026] If the parameter type being adjusted is the location information, then based on the location information before and after adjustment, determine the symmetrical difference set between the second 3D action area before and after adjustment, and adjust the second 3D action area based on the symmetrical difference set;

[0027] If the adjusted parameter type is the direction information or the size information, then the original electron beam 3D model is regenerated;

[0028] If the adjusted parameter type is the intensity information, then the image blurring and / or image brightness processing is performed again to obtain updated 2D image data.

[0029] Furthermore, image blurring and brightness processing are performed based on the electron beam parameters to obtain updated 2D image data, specifically including:

[0030] Based on the electron beam parameters, a convolution kernel is generated using a two-dimensional Gaussian function to characterize the intensity distribution of the electron beam;

[0031] For each pixel in the original 2D image data, a weighted average is performed using the convolution kernel to perform image blurring; wherein the weights of the convolution kernels corresponding to all pixels sum to 1;

[0032] The original 2D image data is processed for image brightness based on the intensity information to obtain updated 2D image data.

[0033] Furthermore, image brightness processing is performed on the original 2D image data based on the intensity information to obtain updated 2D image data, specifically including:

[0034] Based on the intensity information, thickness information is added to the original 2D image data; wherein the thickness information is positively correlated with the intensity information, and the maximum value of the thickness information is lower than the size information;

[0035] A brightness attenuation direction is generated along the thickness information;

[0036] Based on the brightness decay direction, the brightness information of the specified area with the highest brightness is determined according to the intensity information, and the brightness information of other areas outside the specified area is gradually decayed along the brightness decay direction; wherein, the brightness information of the original 2D image data with the same thickness information is the same.

[0037] After image brightness processing, the original 2D image data carrying the thickness information is used as the updated 2D image data.

[0038] The beneficial effects of adopting the above-mentioned further solutions are:

[0039] By adding thickness information positively correlated with intensity to the original 2D image data and generating a brightness attenuation direction along this direction, and then applying a reasonable gradual attenuation of brightness in different regions, the intensity distribution of the electron beam can be accurately mapped onto the image data. This updated 2D image data more realistically reflects the physical characteristics of the electron beam, providing high-quality texture data for subsequent mapping onto the surface of the original electron beam 3D model. This results in a more realistic optical effect in the final generated standard electron beam 3D model within the VR environment, further enhancing the physical realism and accuracy of electron beam visualization. Simultaneously, this processing method also helps improve the adaptability and flexibility of the entire electron beam generation method under different parameter adjustment scenarios, ensuring the generation of realistic electron beam effects regardless of variations in intensity information.

[0040] Furthermore, based on the aforementioned position mapping relationship, the updated 2D image data is used as a texture and mapped onto the surface of the original electron beam 3D model to generate a standard electron beam 3D model in the VR environment, specifically including:

[0041] Based on the position mapping relationship, the updated 2D image data of the outermost layer along the brightness decay direction is used as a texture and mapped onto the surface of the original electron beam 3D model.

[0042] The designated area is used as the central area of ​​the original electron beam 3D model. Along the brightness attenuation direction, the brightness information corresponding to each thickness information is mapped into the interior of the original electron beam 3D model.

[0043] The original electron beam 3D model with the surface and interior mapped is used as the standard electron beam 3D model.

[0044] Furthermore, based on the aforementioned position mapping relationship, the updated 2D image data is used as a texture and mapped onto the surface of the original electron beam 3D model to generate a standard electron beam 3D model in the VR environment, specifically including:

[0045] Based on the position mapping relationship, the UV coordinate system corresponding to the updated 2D image data is determined;

[0046] For each vertex in the second 3D action area, determine its position vector relative to the origin corresponding to the position information, and project the position vector onto the X-axis and Y-axis directions of the local spatial coordinate system to obtain the corresponding components;

[0047] The corresponding UV coordinates are obtained based on the components corresponding to the X-axis direction and the Y-axis direction;

[0048] Based on the coordinate range of the UV coordinates, the corresponding region image is extracted from the updated 2D image data and mapped onto the surface of the original electron beam 3D model to generate a standard electron beam 3D model in the VR environment.

[0049] Furthermore, based on the directional information, the first 3D effective area is extended and superimposed to obtain a second 3D effective area, specifically including:

[0050] Based on the direction information, the first 3D action area is extended and superimposed, and it is determined whether there are any obstructions on the path corresponding to the direction information.

[0051] If an obstruction exists, determine the type of the obstruction;

[0052] If the type of the obstruction is an optical element, then when passing through the obstruction, the original 2D image data is geometrically deformed based on the position mapping relationship, and after passing through the obstruction, the size information of the first 3D action area is adjusted in the extension and superposition process according to the result of the geometric deformation.

[0053] The geometric deformation process includes: based on the position mapping relationship, converting the Cartesian coordinates of the region where the original 2D image data is located to polar coordinates; obtaining a radial displacement function through a nonlinear displacement function, and performing geometric deformation on the original 2D image data through the radial displacement function, and converting the polar coordinates of the original 2D image data after geometric deformation to Cartesian coordinates within the region.

[0054] The beneficial effects of adopting the above-mentioned further solutions are:

[0055] Considering the actual impact of optical elements on the electron beam, by geometrically deforming the original 2D image data and adjusting the size information during the extension and superposition of the first 3D action area, the physical changes of the electron beam as it passes through optical elements can be simulated more accurately. This makes the generated second 3D action area more realistic, and the resulting standard electron beam 3D model can more accurately reflect the propagation and distribution of the electron beam in the real environment. For example, in an electron microscope, the electron beam passes through optical elements such as lenses, which affect the shape and size of the electron beam. Through the above processing method, this process can be simulated more realistically in a VR environment, providing users with a more realistic electron beam visualization experience. Moreover, this processing method has good adaptability to different types of optical elements, and can accurately simulate and adjust the electron beam according to different position mapping relationships and nonlinear displacement functions, further improving the accuracy and reliability of the electron beam generation method.

[0056] On the other hand, this application also proposes a VR-based electron beam generation device, comprising:

[0057] At least one processor; and,

[0058] A memory communicatively connected to the at least one processor; wherein,

[0059] The memory stores instructions that can be executed by the at least one processor to enable the at least one processor to perform the VR-based electron beam generation method as described in any of the above examples.

[0060] On the other hand, this application also proposes a non-volatile computer storage medium storing computer-executable instructions configured as a VR-based electron beam generation method as described in any of the above examples. Attached Figure Description

[0061] The accompanying drawings, which are included to provide a further understanding of this application and form part of this application, illustrate exemplary embodiments and are used to explain this application, but do not constitute an undue limitation of this application. In the drawings:

[0062] Figure 1 This is a flowchart illustrating the VR-based electron beam generation method in the embodiments of this application;

[0063] Figure 2 This is a schematic diagram of the original 2D image data in one scenario of an embodiment of this application;

[0064] Figure 3This is a schematic diagram illustrating image brightness processing in one scenario of an embodiment of this application;

[0065] Figure 4 This is a schematic diagram of a VR-based electron beam generation device in an embodiment of this application. Detailed Implementation

[0066] The specific embodiments of the present invention will be described in detail below. The present invention can be implemented in many other ways different from those described herein, and those skilled in the art can make similar modifications without departing from the spirit of the present invention. Therefore, the present invention is not limited to the specific embodiments disclosed.

[0067] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as commonly understood by one of ordinary skill in the art to which this invention pertains. The terminology used is for describing particular embodiments only and is not intended to limit the invention.

[0068] The technical solutions provided by the various embodiments of this application are described in detail below with reference to the accompanying drawings.

[0069] like Figure 1 As shown, this application provides a VR-based electron beam generation method, including:

[0070] S101: Obtain the electron beam parameters input by the user, and generate the corresponding original electron beam 3D model in the VR environment based on the electron beam parameters.

[0071] A Virtual Reality (VR) environment, or simply VR environment, is a virtual three-dimensional space created using computer technology that provides users with an immersive experience. Users can wear appropriate VR devices (such as VR glasses, VR headsets, cave-like VR devices, etc.) to view content and perform interactive actions within this virtual VR environment. In this embodiment, the viewed content primarily consists of an electron beam, while the interactive actions may include inputting and modifying electron beam parameters.

[0072] Specifically, based on the electron beam parameters, the corresponding position information, size information, orientation information, and intensity information are determined in the VR environment. The position information describes the center position of the electron beam's starting point corresponding to the given electron beam parameters; the size information describes the radius and width of the electron beam; the orientation information describes the emission direction of the electron beam; and the intensity information describes the brightness level of the electron beam.

[0073] Based on the location and orientation information, a local spatial coordinate system is established within the VR environment. This local spatial coordinate system is a three-dimensional spatial coordinate system, and its main purpose is to establish the original 3D model of the electron beam. For example, the local spatial coordinate system is established with the location information as the origin and the orientation information as the Z-axis.

[0074] Based on the location and size information, the corresponding first 3D action area is determined. A circular area is generated with the location information as the center and the size information as the radius. A cylindrical area obtained by adding a preset thickness to this circular area is used as the first 3D action area.

[0075] Based on the directional information, the first 3D action region is extended and superimposed to obtain the second 3D action region. Typically, the direction of the electron beam is a straight line; therefore, by extending the cylindrical region and superimposing the extended portion with the previous portion, the second 3D action region can be obtained. Alternatively, the thickness of the cylindrical region can be modified according to the extension direction to obtain the second 3D action region.

[0076] Based on the intensity information, the second 3D action area is visually filled to generate the corresponding original electron beam 3D model. At this point, the original electron beam 3D model has not yet had surface texture added, so appropriate transparent materials can be used for visual filling. To increase realism, the brightness of the transparent material can also be adjusted according to the intensity information; the higher the intensity, the brighter the material.

[0077] Furthermore, after obtaining the second 3D action region and the original electron beam 3D model, the second 3D action region can be bound to the original electron beam 3D model. After this binding is achieved, adjusting the second 3D action region means adjusting the original electron beam 3D model, which facilitates a rapid response and presentation of adjustment effects when dynamically adjusting electron beam parameters subsequently.

[0078] Identify that the electron beam parameters have been adjusted, and determine the type of parameter adjustment. For example, the user may have set new electron beam parameters, in which case the electron beam parameters have been adjusted.

[0079] If the parameter type being adjusted is position information, then based on the position information before and after adjustment, the symmetric difference between the second 3D action regions before and after adjustment is determined. The symmetric difference refers to the region outside the overlapping area between the second 3D action regions before and after adjustment (which also corresponds to the original electron beam 3D model).

[0080] Adjusting the second 3D action area based on the symmetric difference set allows for adjustment only to the non-overlapping areas outside the overlapping areas. Within these non-overlapping areas, the moved-out areas need to be restored to their original state with the visual fill removed, while the moved-in areas need to have new effects applied and the visual fill increased. The overlapping areas, however, do not require any changes.

[0081] If the parameter type being adjusted is orientation information or size information, it indicates that the shape of the original electron beam 3D model has changed, and the original electron beam 3D model needs to be regenerated.

[0082] If the parameter being adjusted is intensity information, the original electron beam 3D model is considered to require no change. In this case, image blurring and / or image brightness processing need to be performed again to obtain updated 2D image data. The details of this image processing will be explained below.

[0083] S102: Obtain preset raw 2D image data and determine the positional mapping relationship between the predefined VR environment and the raw 2D image data.

[0084] The raw 2D image data is primarily used for generating the surface texture of the original electron beam 3D model, simulating the surface texture of the electron beam. This data can be preset. Typically, real electron microscope images are grayscale; therefore, when setting the raw 2D image data, it can be configured as follows: Figure 2 As shown, it is set as a grid stripe shape, and different gray values ​​of the grid represent different intensity information of the electron beam. For example, as... Figure 2 As shown, the original 2D image data contains multiple adjacent stripes (for ease of description, Figure 2 (The following explanation uses only three stripes as an example.) A single stripe contains multiple grids, each grid corresponding to one or more pixels. The grids in a single stripe are basically the same color, while a few have different colors. The colors of adjacent stripes are basically opposite, forming complementary colors, thus simulating the actual state of an electron beam.

[0085] The position mapping relationship refers to the mapping relationship between the origin of the local spatial coordinate system of the three-dimensional space corresponding to the VR environment and the origin of the two-dimensional space corresponding to the original 2D image data, so as to facilitate the subsequent mapping of the original 2D image data as texture to the original electron beam 3D model.

[0086] S103: Perform image blurring and image brightness processing based on the electron beam parameters to obtain updated 2D image data.

[0087] Image blurring is primarily used to simulate electron scattering processes. It restores the signal diffusion caused by electron interactions by blurring the original 2D image data. Image brightness processing, on the other hand, is mainly used to simulate signal intensity response, mapping the signal intensity distribution generated by electron interactions.

[0088] Specifically, based on the electron beam parameters, a convolution kernel is generated using a two-dimensional Gaussian function to characterize the intensity distribution of the electron beam. The convolution kernel can be as shown in Equation 1:

[0089] Formula 1;

[0090] in, For convolution kernel, The coordinates of the pixels within the kernel. To control the standard deviation of ambiguity, its value is directly related to the electron beam size information and can be set to... Where R is the size information and k is the adjustment coefficient, which is usually taken as 3.

[0091] For each pixel in the original 2D image data, a weighted average is performed using convolution kernels to perform image blurring; where the weights of the convolution kernels corresponding to all pixels sum to 1, as shown in Formula 2:

[0092] Formula 2;

[0093] Where (i,j) are the coordinates of the pixel. The pixel value at pixel (i,j) after image blurring. For the convolution kernel at the offset The weight value at that point, In relative position The original pixel value at the location; where the offset range can be traversed within a rectangular window of [-3σ,3σ]×[-3σ,3σ] centered at pixel (i,j) and traversed (m,n).

[0094] Image brightness processing is performed on the original 2D image data based on intensity information to obtain updated 2D image data. Generally speaking, the higher the intensity information, the higher the brightness adjustment required during image brightness processing; the two are positively correlated. For example, a corresponding mapping table can be pre-set, so that after determining the intensity information, the corresponding brightness information can be directly found in the table. Alternatively, a correspondence can be generated between the two, and a linear relationship can be used to reduce computational complexity and ensure real-time performance. Then, based on the correspondence between intensity and brightness information, the brightness information of the original 2D image data can be adjusted to obtain updated 2D image data.

[0095] However, since the updated 2D image data is used to map onto the surface of the original electron beam 3D model, the brightness information can only reflect the brightness of the electron beam surface and cannot represent the characteristic that the center brightness of the electron beam is higher than the edge brightness.

[0096] Based on this, thickness information is added to the original 2D image data according to the intensity information; the thickness information is positively correlated with the intensity information, and the maximum value of the thickness information is lower than that of the size information. For example... Figure 3 As shown, after adding thickness information to the original 2D image data, updated 2D image data is obtained. This updated 2D image data can then be presented as 3D image data. Furthermore, a pre-defined mapping table or a linear relationship can be established between thickness information and intensity information. Once the intensity information is determined, the corresponding thickness information can be directly retrieved from the table.

[0097] The brightness attenuation direction is generated along the thickness information. For example... Figure 3 As shown, the brightness decay direction is consistent with the thickness direction, and the brightness information gradually decays along the brightness decay direction.

[0098] Based on the direction of brightness decay, the brightness information of the specified area with the highest brightness is determined according to the intensity information. The specified area with the highest brightness can be the first 20% to 40% of the area along the direction of brightness decay. Its brightness information can be obtained by looking up a table or calculating a linear relationship, as described above.

[0099] Along the brightness decay direction, the brightness information of other areas outside the specified area is gradually attenuated; where the brightness information of the original 2D image data with the same thickness information is the same, the attenuation process can be as shown in Formula 3:

[0100] Formula 3;

[0101] Where r is the thickness difference between the current position and the specified area. This refers to the brightness information at the position of the thickness difference r. For the brightness information of the specified area, This is the size information.

[0102] At this point, the original 2D image data, after brightness processing and carrying thickness information, is used as the updated 2D image data. Of course, when obtaining the corresponding thickness information, brightness information, and gradual decay, corresponding maximum or minimum values ​​can be set to ensure that they do not exceed the preset range.

[0103] It should be noted that the addition of thickness information is only a visual and intuitive way of recording brightness information. In fact, other methods can also be used to record brightness information.

[0104] S104: Based on the position mapping relationship, the updated 2D image data is used as a texture and mapped onto the surface of the original electron beam 3D model to generate a standard electron beam 3D model in the VR environment.

[0105] Having obtained the updated 2D image data and the original electron beam 3D model, the updated 2D image data can now be mapped onto the surface of the original electron beam 3D model to generate a standard electron beam 3D model.

[0106] Specifically, based on the position mapping relationship, the UV coordinate system corresponding to the updated 2D image data is determined. The origin of this UV coordinate system can be obtained through the position mapping relationship.

[0107] For each vertex in the second 3D action area, determine its position vector relative to the origin corresponding to the position information, where the position vector points from the origin to the vertex's position.

[0108] Projecting the position vector onto the X and Y axes of the local spatial coordinate system yields the corresponding components. Based on these components, the corresponding UV coordinates are obtained, as shown in Formulas 4 and 5.

[0109] Formula 4;

[0110] Formula 5;

[0111] in, , Let u and v be the coordinates of the i-th vertex. Let be the coordinates of the i-th vertex in the XY plane, where X and Y are the corresponding X-axis direction vector and Y-axis direction vector, respectively. Let be the range of a vertex in the XY plane. The range of all vertices is [- , ]×[- , ].

[0112] Based on the range of UV coordinates, the corresponding region image is extracted from the updated 2D image data and mapped onto the surface of the original electron beam 3D model to generate a standard electron beam 3D model in the VR environment. For example, the maximum and minimum values ​​of the UV coordinates of all vertices are found. , , , At this time, [ , ]×[ , The updated 2D image data within the rectangular area is used as the cropped region image, and vertex mapping is performed based on the coordinates of each vertex in the UV coordinates and the coordinates in the second 3D action area.

[0113] Furthermore, when updating 2D image data that carries thickness information, the above only completes the surface mapping and does not achieve the mapping of internal brightness information.

[0114] At this point, following the above method, based on the position mapping relationship, the updated 2D image data of the outermost layer along the brightness decay direction is used as a texture and mapped onto the surface of the original electron beam 3D model before internal mapping is performed.

[0115] During the internal mapping process, such as Figure 3 As shown, a designated area is taken as the central region of the original electron beam 3D model. Along the brightness decay direction, the brightness information corresponding to each thickness information is mapped to the interior of the original electron beam 3D model. That is, the brightness information of the central region of the original electron beam 3D model (whose width is the same as the thickness information of the designated region updating the 2D image data) is adjusted to the brightness information of the designated region, and along the brightness decay direction (from the inside to the outside in the original electron beam 3D model), the brightness information corresponding to different thickness information is filled to different radius positions of the original electron beam 3D model, and the brightness information at the same radius position remains consistent. At this time, the brightness information of the central region of the original electron beam 3D model is the highest, and the brightness information gradually decreases as it moves towards the edge region.

[0116] At this point, the original electron beam 3D model with the surface and interior mapped is used as the standard electron beam 3D model.

[0117] 1. By simulating the electron scattering effect through image blurring processing, an edge blurring effect that conforms to physical laws is generated. By mapping the intensity distribution through image brightness processing, the electron beam in the VR environment presents the real optical characteristics of being bright at the center and gradually weakening at the edges, thereby realizing the true visualization of the physical properties of the electron beam.

[0118] 2. When the position of the electron beam changes, the texture is locally updated based on the position mapping relationship and symmetric difference calculation, avoiding the reconstruction of the 3D model, significantly improving the interaction efficiency, and realizing the real-time optimization of dynamic parameter adjustment.

[0119] 3. Physical calculations are offloaded to the 2D image layer, with the 3D model only handling texture mapping, reducing the computing power requirements of VR devices, supporting deployment on mobile and lightweight VR devices, and ensuring cross-platform compatibility.

[0120] In one embodiment, in a real VR scenario, there may be some conditions that affect the shape, intensity, etc. of the electron beam.

[0121] Specifically, based on the directional information, the first 3D action area is extended and superimposed, and it is determined whether there are any obstructions on the path corresponding to the directional information. These obstructions can be pre-set in the VR environment.

[0122] If an obstruction exists, determine the type of obstruction. Generally, the type of obstruction can include two types: optical element types (such as convex lenses, concave lenses, etc.) and other types (such as canvas, etc.).

[0123] If the occlusion is an optical element, then when passing through the occlusion, the original 2D image data is geometrically deformed based on the position mapping relationship.

[0124] Specifically, the main function of geometric deformation is to simulate the electromagnetic field distortion effect and reproduce the spatial distortion of the electron beam under the action of the electromagnetic lens.

[0125] The geometric transformation process involves converting the Cartesian coordinates within the region containing the original 2D image data into polar coordinates based on positional mapping relationships. The origin of this polar coordinate system can be determined using the positional information of the electron beam (i.e., the center point of the electron beam).

[0126] A radial displacement function is obtained through a nonlinear displacement function, and then the original 2D image data is geometrically deformed using the radial displacement function. The radial displacement function can be represented by Equation 6.

[0127] Formula Six;

[0128] in, Let r be the position of the point at a distance r from the center of the circle before the geometric transformation. Let k be the distance between the point and the center of the circle after geometric deformation, and k be the torsional strength coefficient. A negative value indicates contraction, and a positive value indicates expansion. k is obtained from the strength information and the magnetic field strength of the lens. k = -α*I, where α is the scaling factor, which is a constant, and I is the strength information.

[0129] At this point, the polar coordinates of the original 2D image data after geometric deformation are converted to Cartesian coordinates within the region, and the geometric deformation action is completed.

[0130] After passing the obstruction, the dimensional information of the first 3D action area is adjusted during the extension and superposition process based on the result of geometric deformation. After geometric deformation, the dimensional information of the electron beam is changed, and in subsequent extension and superposition processes, the extension and superposition continues according to this new dimensional information.

[0131] like Figure 4 As shown in the illustration, this application also provides a VR-based electron beam generation device, including:

[0132] At least one processor; and,

[0133] A memory communicatively connected to the at least one processor; wherein,

[0134] The memory stores instructions that can be executed by the at least one processor to enable the at least one processor to perform the VR-based electron beam generation method as described in any of the above embodiments.

[0135] This application also provides a non-volatile computer storage medium storing computer-executable instructions, wherein the computer-executable instructions are configured as the VR-based electron beam generation method as described in any of the above embodiments.

[0136] The various embodiments in this application are described in a progressive manner. Similar or identical parts between embodiments can be referred to mutually. Each embodiment focuses on describing the differences from other embodiments. In particular, the device and medium embodiments are basically similar to the method embodiments, so the description is relatively simple; relevant parts can be referred to the description of the method embodiments.

[0137] The devices and media provided in this application are one-to-one with the methods. Therefore, the devices and media also have similar beneficial technical effects as their corresponding methods. Since the beneficial technical effects of the methods have been described in detail above, the beneficial technical effects of the devices and media will not be repeated here.

[0138] The technical features of the above embodiments can be combined in any way. For the sake of brevity, not all possible combinations of the technical features in the above embodiments are exhaustively listed. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.

[0139] For those skilled in the art, various modifications and improvements can be made without departing from the concept of the present invention, and these modifications and improvements are all within the scope of protection of the present invention. The scope of protection of the present invention is defined by the appended claims.

Claims

1. A method for generating an electron beam based on VR, characterized in that, include: Obtain the electron beam parameters input by the user, and generate the corresponding original electron beam 3D model in the VR environment based on the electron beam parameters; Acquire preset raw 2D image data and determine the positional mapping relationship between the predefined VR environment and the raw 2D image data; wherein, the raw 2D image data is a grid stripe shape, and different intensity information of the electron beam is represented by different gray values ​​of the grids; the raw 2D image data contains multiple adjacent stripes, a single stripe contains multiple grids, and each grid corresponds to one or more pixels. Based on the electron beam parameters, image blurring and image brightness processing are performed to obtain updated 2D image data; Based on the position mapping relationship, the updated 2D image data is used as a texture and mapped onto the surface of the original electron beam 3D model to generate a standard electron beam 3D model in the VR environment. Based on the electron beam parameters, a corresponding original electron beam 3D model is generated in the VR environment, specifically including: Based on the electron beam parameters, the corresponding position information, size information, orientation information, and intensity information are determined in the VR environment; Based on the location information and the orientation information, a local spatial coordinate system is established in the VR environment; Based on the location information and the size information, a corresponding first 3D action area is determined, and based on the direction information, the first 3D action area is extended and superimposed to obtain a second 3D action area; Based on the intensity information, the second 3D action area is visually filled to generate the corresponding original electron beam 3D model. Based on the electron beam parameters, image blurring and brightness processing are performed to obtain updated 2D image data, specifically including: Based on the electron beam parameters, a convolution kernel is generated using a two-dimensional Gaussian function to characterize the intensity distribution of the electron beam; For each pixel in the original 2D image data, a weighted average is performed using the convolution kernel to perform image blurring; wherein the weights of the convolution kernels corresponding to all pixels sum to 1; Based on the intensity information, the original 2D image data is processed for image brightness to obtain updated 2D image data; Based on the intensity information, the original 2D image data is processed for image brightness to obtain updated 2D image data, specifically including: Based on the intensity information, thickness information is added to the original 2D image data; wherein the thickness information is positively correlated with the intensity information, and the maximum value of the thickness information is lower than the size information; A brightness attenuation direction is generated along the thickness information; Based on the brightness decay direction, the brightness information of the specified area with the highest brightness is determined according to the intensity information, and the brightness information of other areas outside the specified area is gradually decayed along the brightness decay direction; wherein, the brightness information of the original 2D image data with the same thickness information is the same. After image brightness processing, the original 2D image data carrying the thickness information is used as the updated 2D image data.

2. The VR-based electron beam generation method of claim 1, wherein, The method further includes: Bind the second 3D action area to the original electron beam 3D model; It is determined that the electron beam parameters have been adjusted, and the type of parameter adjustment is determined; If the parameter type being adjusted is the location information, then based on the location information before and after adjustment, determine the symmetrical difference set between the second 3D action area before and after adjustment, and adjust the second 3D action area based on the symmetrical difference set; If the adjusted parameter type is the direction information or the size information, then the original electron beam 3D model is regenerated; If the adjusted parameter type is the intensity information, then the image blurring and / or image brightness processing is performed again to obtain updated 2D image data.

3. The VR-based electron beam generation method of claim 1, wherein, Based on the aforementioned position mapping relationship, the updated 2D image data is used as a texture and mapped onto the surface of the original electron beam 3D model to generate a standard electron beam 3D model in the VR environment, specifically including: Based on the position mapping relationship, the updated 2D image data of the outermost layer along the brightness decay direction is used as a texture and mapped onto the surface of the original electron beam 3D model. The designated area is used as the central area of ​​the original electron beam 3D model. Along the brightness attenuation direction, the brightness information corresponding to each thickness information is mapped into the interior of the original electron beam 3D model. The original electron beam 3D model with the surface and interior mapped is used as the standard electron beam 3D model.

4. The VR-based electron beam generation method of claim 1, wherein, Based on the aforementioned position mapping relationship, the updated 2D image data is used as a texture and mapped onto the surface of the original electron beam 3D model to generate a standard electron beam 3D model in the VR environment, specifically including: Based on the position mapping relationship, the UV coordinate system corresponding to the updated 2D image data is determined; For each vertex in the second 3D action area, determine its position vector relative to the origin corresponding to the position information, and project the position vector onto the X-axis and Y-axis directions of the local spatial coordinate system to obtain the corresponding components; The corresponding UV coordinates are obtained based on the components corresponding to the X-axis direction and the Y-axis direction; Based on the coordinate range of the UV coordinates, the corresponding region image is extracted from the updated 2D image data and mapped onto the surface of the original electron beam 3D model to generate a standard electron beam 3D model in the VR environment.

5. The VR-based electron beam generation method of claim 1, wherein, Based on the directional information, the first 3D effective area is extended and superimposed to obtain the second 3D effective area, specifically including: Based on the direction information, the first 3D action area is extended and superimposed, and it is determined whether there are any obstructions on the path corresponding to the direction information. If an obstruction exists, determine the type of the obstruction; If the type of the obstruction is an optical element, then when passing through the obstruction, the original 2D image data is geometrically deformed based on the position mapping relationship, and after passing through the obstruction, the size information of the first 3D action area is adjusted in the extension and superposition process according to the result of the geometric deformation. The geometric deformation process includes: based on the position mapping relationship, converting the Cartesian coordinates of the region where the original 2D image data is located to polar coordinates; obtaining a radial displacement function through a nonlinear displacement function, and performing geometric deformation on the original 2D image data through the radial displacement function, and converting the polar coordinates of the original 2D image data after geometric deformation to Cartesian coordinates within the region.

6. A VR-based electron beam generating apparatus, characterized by comprising: include: At least one processor; as well as, A memory communicatively connected to the at least one processor; wherein, The memory stores instructions executable by the at least one processor, which, when executed by the at least one processor, enables the at least one processor to perform the VR-based electron beam generation method as described in any one of claims 1 to 5.

7. A non-transitory computer storage medium storing computer-executable instructions that, when executed, cause a computer to perform: The computer-executable instructions are configured as the VR-based electron beam generation method as described in any one of claims 1 to 5.

Citation Information

Patent Citations

  • Particle flow field reconstruction model training method and device and particle flow field reconstruction method and device

    CN119579801A

  • Charged Particle Beam Device and Method for Controlling Same

    US20240242928A1