Virtual reality ideological and political content adaptive generation method based on affective computing
By constructing a physiological feedback-driven screen space post-processing mechanism at the end of the mobile virtual reality rendering pipeline, and utilizing dual lookup tables and template buffers, dynamic visual atmosphere adjustment of virtual reality scenes is achieved, resolving the contradiction between rendering efficiency and dynamic responsiveness, reducing the risk of motion sickness, and maintaining high frame rates and visual comfort.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2026-01-15
- Publication Date
- 2026-04-10
AI Technical Summary
Existing mobile virtual reality applications suffer from a contradiction between rendering efficiency and dynamic response capability in immersive content interaction, leading to screen freezing. Furthermore, physiological signals used in ideological and political education fail to be mapped to the visual rendering layer in real time to dynamically adjust the scene's color tone, making it difficult to solve the problem of motion sickness caused by the conflict between visual stimulation and vestibular perception under high arousal levels.
By constructing a screen-space post-processing stage based on physiological feedback weights at the end of the rendering pipeline of the graphics processing unit, and utilizing a double lookup table interpolation and template buffer mechanism, the visual atmosphere of the virtual reality scene is adjusted in real time. Combined with depth gradient and velocity buffer data, dynamic atmosphere rendering and high frame rate display under limited computing power are achieved.
Without increasing GPU load, high frame rate continuous reconstruction of visual style in virtual reality scenes was achieved, eliminating the physiological conflict between high-intensity visual style and user vestibular movement, thus ensuring user immersion and comfort.
Smart Images

Figure CN121544785B_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The present application relates to a virtual reality ideological and political content adaptive generation method based on affective computing, belonging to the field of virtual reality image processing. BACKGROUND
[0002] The current mobile virtual reality application development is limited by the graphics processor computing power and power consumption heat design constraints. The pre-baked rendering pipeline is a general technology for maintaining high-resolution and high-refresh-rate display of binoculars. In the development stage, the scene global illumination, shadow masking and tone mapping parameters are fixed as static texture maps or illumination probe data, reducing the real-time floating point operation load at runtime, and ensuring that the rendering frame rate meets the anti-motion sickness safety threshold. Immersive content interaction needs to reconstruct the scene visual atmosphere in real time according to user physiological feedback or teaching logic. The static pre-baking paradigm has a contradiction between rendering efficiency and dynamic response capability. Several different styles of scene resources are pre-prepared for runtime switching by asset replacement. The instant reloading of geometry data and high-resolution textures causes memory bandwidth congestion and a dramatic increase in frame generation time, resulting in picture freezing and destroying the immersive experience. Introducing real-time global illumination or volume light calculation to dynamically generate atmosphere, the calculation overhead exceeds the load limit of mainstream mobile virtual reality hardware, resulting in a frame rate below the baseline.
[0003] In addition to the rendering load level restrictions, existing physiological signal assisted ideological and political teaching technical solutions are mostly limited to upper-level logic interaction effect evaluation, lacking deep integration with the underlying rendering pipeline. For example, a kind of ideological and political interaction method based on virtual reality is disclosed in the Chinese patent CN117153004A. Although the heart rate changes are recorded when the students select the teaching content, the physiological data combined with the time parameter are used as the posterior index for determining the learning effect level, this one-way open-loop mode does not map the physiological signals in real time to the visual rendering layer to dynamically adjust the scene tone or atmosphere. The system cannot reconstruct the visual style in real time according to the user's emotional fluctuations, and it is difficult to solve the problem of motion sickness caused by the conflict between visual stimulation and vestibular perception under high arousal. Therefore, the physiological data has not been fully released in enhancing immersion and visual comfort.
[0004] Therefore, it is necessary to construct a low-overhead visual reconstruction mechanism based on screen space without destroying pre-baked static assets and without increasing GPU shading load, to solve the contradiction between dynamic atmosphere rendering and limited computing power and information presentation clarity, which is the technical problem to be solved by the present application. SUMMARY
[0005] To solve the problems raised in the background art, the technical solution of the present application is as follows: a virtual reality ideological and political content adaptive generation method based on affective computing, comprising:
[0006] acquire real-time physiological signal data of a user and calculate a deviation value of the real-time physiological signal data relative to a preset reference value, map the deviation value to a normalized visual intervention weight coefficient;
[0007] preloading at least two three-dimensional color lookup tables in a graphics memory of a graphics processing unit, the three-dimensional color lookup tables including a reference lookup table mapping a reference visual style and a target lookup table mapping a target intervention visual style;
[0008] rasterizing information primitives in a scene into corresponding pixels in a rasterization stage of a rendering pipeline of the virtual reality scene, and writing a specific mask identifier value into a stencil buffer at a position corresponding to the pixel;
[0009] performing a screen space post-processing step on a current processing pixel generated by the rasterization in a fragment shading stage of the rendering pipeline: reading a value of the current processing pixel in the stencil buffer, and determining whether the value is equal to the mask identifier value;
[0010] if the value is equal to the mask identifier value, setting a visual intervention weight coefficient for the current processing pixel to zero;
[0011] if the value is not equal to the mask identifier value, keeping the visual intervention weight coefficient unchanged;
[0012] using an original color value of the current processing pixel as an index, performing texture sampling in the reference lookup table and the target lookup table respectively to obtain a reference color value and a target color value;
[0013] performing a linear interpolation operation on the reference color value and the target color value using the visual intervention weight coefficient determined in the determining step to obtain a final display pixel color value and outputting the final display pixel color value to a display device.
[0014] Preferably, the screen space post-processing step further comprises: acquiring a depth buffer texture generated by a current rendering frame, and sampling the depth buffer texture to obtain a linear depth value of the current processing pixel; calculating a spatial depth modulation coefficient using a preset gradient mapping function, the spatial depth modulation coefficient showing a non-linear increasing trend with an increase of the linear depth value; calculating a product of the visual intervention weight coefficient and the spatial depth modulation coefficient to obtain a local mixing weight; and using the local mixing weight instead of the visual intervention weight coefficient in the linear interpolation operation, so that a mixing proportion of the target lookup table to the pixel color is enhanced with an increase of a scene depth, thereby simulating a three-dimensional atmospheric perspective effect in a screen space.
[0015] Preferably, the executing the screen space post-processing step further comprises: obtaining a velocity buffer texture generated by the current rendering frame, sampling the velocity buffer texture to obtain an instantaneous velocity vector of the current processing pixel in the screen space; calculating a module of the instantaneous velocity vector and taking it as an instantaneous motion intensity value; calculating a dynamic damping coefficient D according to the instantaneous motion intensity value by using the following formula: wherein D is the dynamic damping coefficient, V cur is the instantaneous motion intensity value, V min is a preset static threshold, V max is a preset extreme speed threshold; when V cur is less than V min , D takes 1.0, and when V cur is greater than V max , D takes 0; calculating a product of the visual intervention weight coefficient and the dynamic damping coefficient to obtain an actual mixing weight after motion compensation correction; using the actual mixing weight to replace the visual intervention weight coefficient when executing the linear interpolation operation.
[0016] Preferably, the target lookup table comprises red, green, blue color channels and a transparency channel, and the screen coordinate distortion intensity value corresponding to the target intervention visual style is pre-stored in the transparency channel; the executing the screen space post-processing step further comprises: synchronously obtaining the target color value and the screen coordinate distortion intensity value when sampling the target lookup table; modulating the amplitude of a preset reference disturbance vector according to the visual intervention weight coefficient and the screen coordinate distortion intensity value to obtain a pixel offset vector; offset correcting the texture coordinates of the current processing pixel by using the pixel offset vector, and outputting the final display pixel color value based on the corrected texture coordinates.
[0017] Preferably, the executing the screen space post-processing step further comprises: after executing the linear interpolation operation to obtain a preliminary mixed color value, calculating a first luminance component of the original color value and a second luminance component of the preliminary mixed color value, respectively; calculating a luminance compensation coefficient according to the ratio relationship between the first luminance component and the second luminance component; uniformly scaling and correcting the red, green and blue channels of the preliminary mixed color value by using the luminance compensation coefficient to generate the final display pixel color value which retains the original luminance feature.
[0018] Preferably, the executing the screen space post-processing step further comprises: obtaining a normalized position coordinate of the current processing pixel in the screen coordinate system; calculating a radial distance value of the normalized position coordinate relative to the center point of the screen; calculating a space adjustment coefficient according to the radial distance value by using a preset radial attenuation function, the space adjustment coefficient monotonically increases with the increase of the radial distance value; calculating a product of the visual intervention weight coefficient and the space adjustment coefficient to obtain a local effective mixing weight; using the local effective mixing weight to replace the visual intervention weight coefficient when executing the linear interpolation operation.
[0019] Preferably, calculating the deviation of the real-time physiological signal data from the preset benchmark value includes: constructing a sliding sampling window with a fixed time length, calculating the root mean square value of the real-time physiological signal data within the sliding sampling window; calculating the absolute value of the difference between the root mean square value and the preset benchmark value, and mapping the absolute value of the difference to the interval between zero and one as the initial value of the visual intervention weight coefficient.
[0020] Preferably, the information primitives include teaching text primitives, interactive interface primitives, and preset historical artifact primitives in the virtual reality scene; the mask identifier value is a specific integer value reserved in the template buffer and not involved in the regular scene occlusion culling calculation.
[0021] Preferably, linear interpolation is performed, specifically including: multiplying the difference obtained by subtracting the visual intervention weight coefficient from the target color value by the reference color value to obtain a first component; multiplying the target color value by the visual intervention weight coefficient to obtain a second component; and adding the first component and the second component to obtain the final display pixel color value.
[0022] Preferably, the preset gradient mapping function is a smooth step function, the spatial depth modulation coefficient is zero when the linear depth value is less than the preset starting distance threshold, and is one when the linear depth value is greater than the preset saturation distance threshold, and smooth interpolation is performed between the starting distance threshold and the saturation distance threshold.
[0023] Compared with the prior art, the beneficial effects of the present invention are:
[0024] 1. In the ideological and political content of virtual reality based on affective computing, a dynamic color lookup table blending mechanism based on screen space post-processing is constructed to solve the technical problem of continuous global visual style reconstruction under the premise of maintaining a high frame rate in virtual reality scenes. In the fragment shader stage, the normalized weight coefficient of the mapped physiological signal is used to perform linear interpolation operation on the pixel color of the current frame between the reference lookup table and the target lookup table. The complex scene re-rendering task is transformed into texture sampling and vector blending with constant time complexity. This ensures that the visual style transformation is independent of the number of geometric faces and the number of light sources in the scene, without increasing the vertex processing load or causing memory data exchange blockage, and achieves millisecond-level visual atmosphere response and smooth picture.
[0025] 2. Construct a visual intervention intensity negative feedback damping loop with speed buffer data to eliminate high intensity visual style deviation and user vestibular motion perception physiological conflict, dynamically generate a damping coefficient negatively correlated with field of view motion speed by sampling screen space speed texture and calculating motion vector module length, real-time modulate the final color mixing weight, use graphics rendering intermediate buffer data, without introducing motion sensors or increasing complex logical operations, build the visual rendering layer adaptive perception ability to user motion state, ensure that the user automatically reduces the visual intervention intensity to maintain spatial cognitive stability when quickly turning his head or moving, and smoothly restores the target atmosphere after the line of sight is stable.
[0026] 3. Use color lookup table transparency channel non-standard multiplexing logic to simultaneously realize color style mapping and screen space coordinate disturbance decoupling rendering in a single texture sampling period, multiplex the target lookup table texture idle transparency channel to store distortion intensity, the shader directly obtains the intensity parameter while performing color sampling, uses the parameter to modulate the procedural noise vector to offset the current pixel texture coordinate, without increasing the number of texture sampling and memory occupancy, uses a single data source to drive color drift and spatial distortion dual rendering, eliminates the phenomenon of asynchronous timing in multi-channel processing, and reduces the GPU texture bandwidth pressure. BRIEF DESCRIPTION OF DRAWINGS
[0027] Fig. 1 An adaptive rendering process schematic diagram of the present application fusing physiological feedback and double lookup table interpolation;
[0028] Fig. 2 An average frame rate and frame generation time performance comparison diagram of different visual generation schemes of the present application;
[0029] Fig. 3 A system overall architecture schematic diagram of the present application integrating biological perception terminal and XR2 algorithm core. DETAILED DESCRIPTION
[0030] The present embodiment is intended to explain the technical solutions of the present application in detail, but the embodiment should not be understood as limiting the protection scope of the present application.
[0031] The application provides a virtual reality ideological and political content adaptive generation method based on emotional computing, constructs a physiological response weight-based screen space post-processing stage at the end of a graphics processing unit rendering pipeline, realizes real-time continuous reconstruction of a virtual reality scene visual atmosphere, and the system comprises a biological signal processing module, a rasterization stage of a graphics rendering pipeline and post-processing logic in a fragment shader, a data stream starts from a physiological sensor of a user end, is calculated through a normalized weight, and finally drives a hybrid operation of a color lookup table in a display memory and pixel output; in order to solve the rendering blocking problem caused by the fact that the scene visual style needs to be adjusted in real time according to an emotional state under a static pre-baking paradigm, the application establishes a mapping procedure from physiological signals to visual weights, acquires real-time physiological signal data of a user at a data acquisition end at a preset sampling frequency such as 50Hz, and selects skin electricity or heart rate variability, in order to eliminate signal instantaneous jitter, the system constructs a fixed-length sliding sampling window such as 500 milliseconds, calculates the effective value of the signal in the window through a root mean square algorithm, performs normalization mapping, differentiates the calculated root mean square value from a preset reference value, maps the absolute value of the difference to a floating point number interval of 0.0 to 1.0, generates a normalized visual intervention weight coefficient W, and if the calculation result exceeds the interval, the result is truncated to a boundary value, the weight coefficient W is transmitted to the fragment shader as a global control variable for driving subsequent visual style transformation.
[0032] In order to solve the problem that global post-processing may cause the contrast of high-frequency information regions such as teaching texts and cultural relics to decrease, the application introduces a pixel-level semantic isolation mechanism based on a stencil buffer in the rendering pipeline, in the rasterization stage, the system classifies and marks the graphics elements, for information graphics elements such as teaching texts, interactive interfaces and preset historical cultural relics, the stencil writing function is enabled in the shader configuration, and a specific integer mask identification value, for example, 1, is written into the corresponding pixel address in the stencil buffer, for other background environment graphics elements, 0 is not written or written, in the fragment shading stage of the screen space post-processing, the shader program reads the value of the current processing pixel in the stencil buffer, if the value is equal to the mask identification value, it is determined that the pixel belongs to an information protection region, and the local visual intervention weight coefficient corresponding to the pixel is set to 0.0; if not, the global weight coefficient W is kept unchanged, the original hardware stencil test function is used to realize the visual layering effect that the environment atmosphere changes with the emotion and the key teaching information maintains the baseline definition; in order to adjust the scene tone under the condition that the computing power of a mobile terminal device is limited, the application adopts a dynamic interpolation mechanism based on a double-channel color lookup table, preloads two three-dimensional color lookup table textures in the display memory, the size can be 32*32*32 or 64*64*64, wherein the baseline lookup table LUT base stores color mapping data corresponding to a standard teaching environment, and the target lookup table LUT targetStore the color mapping data corresponding to the specific intervention emotion, in the fragment shader, take the original pixel color value (r, g, b) generated by the current rasterization as the three-dimensional texture coordinates, respectively sample the LUT base and the LUT target , obtain the reference color value C base and the target color value C target , perform linear interpolation operation by using the visual intervention weight coefficient W corrected by the template test, and the specific interpolation logic follows the formula: , wherein C final is the final display pixel color value, and the operation converts the scene illumination reconstruction into texture sampling and vector operation of constant level time complexity.
[0033] To solve the problem that full-screen uniform hue transformation destroys the three-dimensional depth feeling of a scene, the application introduces a weight space modulation mechanism based on a depth gradient, samples the depth buffer texture of the current frame in the fragment shading stage to obtain the linear depth value Z linear of the current pixel, defines a gradient mapping function, sets a starting distance threshold D start and a saturated distance threshold D end , when Z linear <D start , the spatial depth modulation coefficient M depth is 0; when Z linear >D end , M depth is 1; a transition value is generated by using a smooth step function between the two, the visual intervention weight coefficient W is multiplied by M depth to obtain the local mixing weight W local , and W local is used to replace the original weight when performing lookup table mixing, so that the near object retains the original hue and the far background presents the emotional atmosphere color, thereby simulating the three-dimensional atmospheric perspective effect in the screen space; to prevent motion sickness induced by rapid head rotation in a high arousal emotional state, the application constructs a dynamic damping mechanism based on a speed buffer, reuses the speed buffer texture used for time anti-aliasing in the rendering pipeline, samples the screen space instantaneous speed vector of the current pixel in the post-processing stage, and calculates the module length , according to the preset static threshold V min and the maximum speed threshold V max , calculates the dynamic damping coefficient D by using the formula , which ensures that when the pixel motion speed is lower than V min , the damping coefficient is 1.0; when the speed exceeds V max , the damping coefficient is reduced to 0.0, and the corrected actual mixing weight W finalW x D, a negative feedback loop is established, so that the user's visual field quickly scans the picture back to the reference tone, and the emotional atmosphere is restored after the visual line is stable.
[0034] In view of the problem that only changing color is insufficient to express extreme physiological feelings, the application adopts lookup table transparency channel multiplexing technology to realize dynamic distortion, in the prefabricated LUT target In the texture, the red, green and blue channels store color mapping information, and the transparency channel stores the screen coordinate distortion intensity value A dist , in the fragment shader, the LUT target is sampled, and C target and A dist are synchronously obtained , a reference disturbance vector is generated by using a programmatic noise algorithm combined with system time , a pixel offset vector is calculated ' , the texture coordinates (u, v) of the current pixel are offset and corrected by using the offset vector to obtain (u ' , v mix ), and the final color is output based on the new coordinates, and the color drift and spatial distortion are synchronously driven by using single texture sampling; since color transformation may cause image dynamic range compression and thus lose texture details, the application includes a detail back-annotation logic for luminance and chroma decoupling, after obtaining the preliminary mixed color value C raw by linear interpolation, the first luminance component L raw of the original pixel color C mix and the second luminance component L mix of C raw are calculated by using the luminance formula L=0.299R+0.587G+0.114B, a luminance compensation coefficient K=L mix / (L mix +ϵ) is calculated, where ϵ is a small value to prevent division by zero, the red, green and blue channels of C target are scaled by using K, and the final color is output, the luminance feature of the final pixel is consistent with the original texture, and the edge profile and texture details of the scene object are clear and identifiable.
[0035] Embodiment 1: In a simulated virtual reality teaching scene with specific harsh natural environment characteristics (such as high cold, extreme climate, etc.), the system runs on an integrated display device with limited computing power, the field of view contains high-frequency snowflake particles, complex mountain geometry and historical monument text that needs to be kept clear, when the root mean square value of the collected skin electricity signal exceeds the reference and the normalized visual intervention weight coefficient W tends to 1.0, the fragment shader executes the target color lookup table LUTlinear interpolation, the global color tone is offset to the cold color system and the ambient brightness is reduced, during which the rendering pipeline uses a specific mask value pre-written in the stencil buffer to identify the pixel area corresponding to the epitaph, and locks the local mixing weight of the area to 0.0, so that the key information graphics remain original brightness and contrast while the ambient light is darkened, the system samples the depth buffer texture to generate a spatial gradient parameter, and only applies high-weight intervention to background pixels beyond the preset distance threshold, thereby simulating atmospheric perspective depth in screen space, for extreme physiological state simulation, the system reuses the LUT target The distortion intensity value A stored in the transparency channel dist Modulate the procedural noise vector, and offset the texture coordinates, to avoid motion sickness, the system monitors the screen space instantaneous speed vector in the speed buffer in real time Once the length exceeds the extreme speed threshold, the actual mixing weight is reduced by a dynamic damping function, so that the picture reverts to the baseline clear state during rapid saccadic eye movements, this scheme dynamically couples the visual style with the user's physiological and motion state by reusing the intermediate buffer data in the rendering pipeline, achieving physiological adaptation of immersion and comfort under constant computational power overhead.
[0036] Embodiment 2: This embodiment aims to verify the performance of the virtual reality ideological and political content adaptive generation method in a real hardware environment with limited computing power, the effectiveness of visual style adjustment, and the ability to suppress motion sickness. The test is based on a mobile VR all-in-one machine equipped with Qualcomm Snapdragon XR2 platform, which represents the performance level of current mainstream independent VR devices. To simulate a real ideological and political teaching scene, a test scene is constructed that includes a complex snow mountain terrain, a dynamic snow particle system, and a high-precision historical epitaph model. To quantitatively evaluate system performance and visual effects, this embodiment sets up three comparative test schemes: control group A: uses the traditional static pre-baking scheme, scene lighting and color tone are fixed in the development stage, and no dynamic adjustment is made during runtime; control group B: uses a dynamic scheme based on real-time global lighting, which calculates lighting in real time to change the atmosphere during runtime; and the inventive group: uses the screen space post-processing scheme based on color lookup table and stencil buffer of the present application. The test examines frame rate stability and rendering overhead. Under the same test path, the average frame rate and GPU frame generation time of the three schemes are recorded. Data collection is performed by the performance analyzer integrated in the VR development toolchain, with a sampling frequency of 1 second and a duration of 60 seconds. The results are shown in Table 1.
[0037] Table 1: Performance comparison data table under different schemes
[0038]
[0039] Referring to Table 1, control group A, serving as the baseline, maintained a full frame rate of 72 FPS but could not respond to changes in physiological signals. Control group B, due to the high overhead of real-time illumination calculation, experienced a significant drop in frame rate to 45.2 FPS, with drastic fluctuations in frame generation time. The sample group of this invention, while achieving dynamic visual style reconstruction, maintained an average frame rate of 71.8 FPS, only 0.2 FPS lower than the static baseline, and with a mere 15 MB increase in video memory usage, demonstrating the extremely low computational cost and high engineering feasibility of this solution on mobile devices. To verify the visual intervention effect and key information protection mechanism, in the test, the root mean square value of the simulated user's electrodermal signal linearly increased from the baseline state of 0.2 to the high-wake state of 0.8, driving the visual intervention weight coefficient W to change synchronously. During this process, the average brightness values of the central inscription area and the surrounding background area of the screen were captured, and their contrast was calculated.
[0040] Table 2: Data on changes in brightness and contrast during visual intervention
[0041]
[0042] Referring to Table 2, as the weight W increases from 0.0 to 1.0, the average background brightness decreases from 0.75 to 0.20, creating a depressing and dim atmosphere. Thanks to the semantic isolation mechanism of the template buffer, the average brightness of the inscription area remains stable at 0.80, unaffected by global post-processing. This results in an increase in relative contrast from the initial 1.07 to 4.00, proving that the invention enhances the emotional atmosphere of the environment without compromising the readability of key information, thereby improving visual attention and information transmission efficiency by darkening the background. Finally, the effect of the dynamic damping mechanism on motion sickness is verified. The camera is controlled by a script to perform a rapid horizontal scan of the scene, simulating a user's rapid head turning action, with the angular velocity accelerating from 0 degrees / second to 180 degrees / second. During this period, the actual mixed weight W is recorded. final The experimental results show that when the angular velocity is below the preset static threshold of 30 degrees / second, W... final Maintain target value As angular velocity increases, W final Rapid nonlinear decay; when the angular velocity reaches the extreme velocity threshold of 120 degrees / second, W final When the value is reduced to 0.0, this negative feedback adjustment mechanism ensures that the image automatically reverts to a clear, natural base tone in the case of high optical flow generated by rapid motion, eliminating the conflict between high-contrast or distorted images and vestibular motion perception.
[0043] Example 3: This example combines Figs. 1 to 3 This section describes an adaptive generation method for ideological and political content in virtual reality based on affective computing, such as... Fig. 1As shown, the rasterization stage performs primitive rasterization and mask writing, enters the parallel processing flow, on the one hand, performs double lookup table texture sampling to realize synchronous sampling of reference LUT and target LUT and output color data, on the other hand, through template buffer semantic isolation, the mask of key information primitives such as text is identified and a weight zero signal is output, at the same time, the system performs real-time physiological signal acquisition of the user, performs sliding window sampling on the skin electricity or heart rate data, and then completes the visual intervention weight generation, that is, calculates the reference deviation value and normalizes the original weight coefficient, the core fragment linear interpolation operation is based on the fusion of the reference weight and the target color based on the maximum weight, the operation process is controlled by double control of depth gradient space modulation and speed buffer dynamic damping, the former generates a depth coefficient by nonlinearly enhancing the intervention according to the scene depth, and the latter detects the instantaneous speed to generate a damping coefficient to suppress the motion sickness, finally, the color mixed by interpolation is corrected by brightness component decoupling to maintain the high-frequency details of the original image texture, and finally output to the display end.
[0044] As shown in Fig. 2 , the left ordinate represents the average frame rate, in FPS, and the right ordinate represents the average frame generation time, in ms, the legend distinguishes the columnar display mode of the average frame rate and the average frame generation time, the data shows that the control group A has a higher average frame rate and a lower average frame generation time, the average frame rate of the control group B is reduced and the average frame generation time is greatly increased, and the sample group of the application is close to the control group A in various indicators, showing the performance characteristics of high frame rate and low delay; as shown in Fig. 3 , the overall architecture of the system includes a physical perception terminal, a VR all-in-one machine computing core and a visual presentation terminal, the physical perception terminal involves a biological sensor group worn by an experience user, specifically including a skin electricity detection module and a heart rate monitoring module, the wireless physiological data generated thereby is transmitted to the VR all-in-one machine computing core, which is based on the Qualcomm\XR2 platform, internally runs adaptive generation logic, performs processing from emotional computing weight to shader mixing, and calls a GPU display memory resource pool, which stores double-channel color lookup tables, i.e. LUTs, a template buffer for storing information masks, and speed and depth buffer textures; the adaptive image stream after processing is transmitted to the visual presentation terminal, high refresh rate picture output is realized through a VR optical display module, and visual stimulation feedback is formed to the experience user.
[0045] Embodiment 4: This embodiment aims to engineer and transparentize the mapping logic of the aforementioned physiological signal to visual intervention weight coefficient, eliminate the potential parameter setting black box, in the real-time emotional computing system, the stability of the mapping algorithm directly determines the stability of the visual feedback and the physiological comfort of the user, for this purpose, the system adopts an adaptive normalization algorithm based on a dynamic reference line, clearly defines the input end of the mapping algorithm, the system collects the original data sequence S rawThis sequence consists of timestamp-aligned voltage values. To filter out power frequency interference and motion artifacts, the system uses S... raw Perform a high-pass filter with a cutoff frequency of 0.5Hz and a cutoff frequency of... The low-pass filter generates a preprocessed signal S. filt In a length of T win Within a sliding window of 500ms, calculate S. filt Root mean square (RMS) cur As an indicator of physiological arousal at the current moment, this indicator reflects the instantaneous activation level of the user's sympathetic nervous system; secondly, regarding the baseline value RMS... base To determine the threshold, the system abandons the fixed threshold method and instead adopts a long-term moving average strategy to adapt to individual differences. The system maintenance length is T. long A historical data queue of 60 seconds is used to calculate the RMS of all data in the queue in real time. cur The average of the values, used as the dynamic baseline value RMS base This dynamic update mechanism ensures that even if a user's basic physiological level drifts over time, the system can still accurately capture relatively sudden emotional fluctuations.
[0046] Finally, perform nonlinear mapping and output smoothing, and calculate the deviation value. To avoid screen flickering caused by minor disturbances, the system introduces a dead-zone threshold δ, and intervention is only initiated when Δ > δ. The mapping function is defined as follows: Among them, W raw The initial values for the visual intervention weighting coefficients are given by [value 1], and k is the sensitivity coefficient, determined based on pre-conducted calibration tests by the user. To further smooth the output, the system adjusts W... raw Perform a first-order lag filter: Where α is the smoothing factor, typically set to 0.1, W out (t) The smoothed normalized weight coefficients output at the current time, W out (t-1) represents the output value at the previous time step. This algorithm ensures that visual intervention can both keenly respond to strong emotions and filter random noise, achieving a stable mapping from physiological signals to visual feedback. It utilizes the instantaneous response characteristics of the velocity buffer to establish a time-masking mechanism to address the coordination problem between the time lag in physiological signal processing and the high real-time performance of virtual reality rendering. The visual intervention weight coefficient... The computation depends on the root mean square integral of a sliding window with a length of 500 milliseconds, which introduces signal processing delay. The instantaneous velocity vector V in screen space... screen The acquisition and calculation of the dynamic damping coefficient D are completed in real time within the current rendering frame; when the user performs a rapid head rotation with an angular velocity greater than a preset threshold, the dynamic damping coefficient D converges to zero, making the actual blending weight W... finalInstantaneous zeroing and picture rollback to the non-intervention reference state, this is based on the real-time fusing mechanism of motion intensity during the sensitive and fast motion of user perception, which hides the delay of emotional computing module logical processing through the priority strategy of physical layer clarity.
[0047] Embodiment 5: To ensure the stability and reproducibility of the physiological signal mapping logic in the emotional computing module, this embodiment constructs a set of physiological signal reference line adaptive calibration procedures. At the initial stage of system startup or when the user's wearing state is detected to change, the program automatically guides the user to enter a 30-second resting calibration phase. In this phase, the system continuously collects the user's skin conductance signal, calculates the mean μ cal and standard deviation σ cal of the signal in this time window, constructs a personalized physiological reference model, and sets a dynamic response threshold , where T resp is the dynamic response threshold, and k2 is a preset threshold sensitivity coefficient, typically set to 2.0. This procedure ensures that the calculation of the subsequent visual intervention weight coefficient W is based on the relative deviation of the user's current physiological reference, rather than the absolute voltage value, effectively eliminating the influence of signal drift caused by individual differences, device wearing tightness, and environmental temperature and humidity changes.
[0048] For the possible color space mapping deviation in the color lookup table generation process, this embodiment formulates a set of offline calibration and data filling procedures based on standard light sources. In a controlled laboratory darkroom environment, the spectral radiometer is used to sample the display characteristics of the target VR display device under the standard D65 light source, obtaining a device-specific colorimetric feature file. Based on this feature file, the preset emotional color target value is accurately mapped from the CIELAB uniform color space to the linear sRGB space, generating a device-calibrated reference lookup table LUT base and target lookup table LUT target node data. This procedure eliminates the influence of hardware display deviation on visual style presentation through standardized color management processes, ensuring accurate reproduction of emotional atmosphere rendering effects on different batches of devices, providing a standardized data foundation for the engineering production and deployment of the system. For the target color lookup table LUT target construction and transparency channel data definition, using the standardized mapping procedure based on the CIELAB color space, corresponding to the high arousal anxiety emotional target lookup table, mapping the standard sRGB color space sampling node coordinates to the device-independent CIELAB space, and linearly attenuating the L * channel brightness gain value by 40% to 60%, a * and b *Channel phase angle 200-240 degree interval of cold color domain 15 degrees overall offset, inverse mapping back to sRGB space and write 32x32x32 precision three-dimensional texture data; synchronous multiplexing storage screen coordinate distortion intensity value A dist The transparency channel generates a reference disturbance vector N by using a simplex noise algorithm with a computational complexity of O(n), and ensures the time dimension t continuity of the texture coordinate offset based on the isotropic gradient characteristics of the simplex noise three-dimensional space slice, without increasing additional texture sampling by synchronously driving the color style offset and spatial geometric distortion through a single lookup table.
[0049] Embodiment 6: This embodiment describes a set of standardized system deployment pre-calibration and model construction procedures for different application scenarios to ensure the stability and consistency of the system in various hardware configurations and user groups. The procedure covers the whole process from sensor calibration, physiological baseline establishment to individualized parameter fine-tuning, and clearly defines the physical environment and sensor calibration process. Before system deployment, the physiological sensors used need to be calibrated. For the skin conductance sensor, a standard resistance box is used to simulate known conductance values. In a controlled environment with a temperature of 25 degrees Celsius and a relative humidity of 50%, the linear mapping relationship between the output voltage and the skin conductance of the sensor is calibrated, and the zero drift and gain error are recorded to generate a sensor-specific calibration coefficient matrix. For the heart rate sensor, a medical-grade electrocardiograph is used as the gold standard to synchronously collect the heart rate data of the subjects in the resting and exercise states, calculate the measurement error of the sensor, and construct a dynamic compensation algorithm based on the error distribution to correct the bias caused by the motion artifact.
[0050] Secondly, the personalized physiological baseline model is established, considering that the basic physiological levels of different users are different, the system needs to perform a baseline collection stage before the first use, guiding the user to perform a 60-second resting test in a calm state without external interference, the system continuously collects the skin electricity and heart rate data of the user, calculates the mean and standard deviation, shows a set of standardized emotional stimulus picture library (including neutral, positive and negative emotional pictures) to the user, records the response amplitude and recovery time of the physiological signal, and determines the physiological response sensitivity coefficient of the user, which is used for weight normalization processing in subsequent emotion calculation; finally, the online running abnormality detection and fault tolerance mechanism configuration are executed, the system internally has a real-time abnormality detection logic based on statistical principles, continuously monitors the signal-to-noise ratio and change rate of the physiological signal during running, if the signal is detected to have abnormal fluctuations or long-time signal loss, the system will automatically trigger the abnormality processing procedure, temporarily lock the current visual intervention weight coefficient, prevent picture flickering or false triggering caused by signal noise, at the same time, the system records the timestamp and type of the abnormal event, and generates a diagnosis report in the background log for subsequent maintenance personnel to analyze, in addition, for the possible network delay or computing power fluctuation, the system pre-installs a multi-level degradation strategy, when the frame rate is continuously detected to be lower than the safety threshold, the sampling accuracy of the color lookup table is automatically reduced or the secondary visual effects are turned off, to preferentially guarantee the smoothness of the picture and the comfort of the user, ensuring that the system can still maintain stable and reliable performance in the face of complex and variable actual application environment.
[0051] It is apparent for those skilled in the art that the present application is not limited to the details of the above exemplary embodiments, and the present application can be implemented in other specific forms without departing from the spirit or essential characteristics of the present application.
[0052] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present application and are not limiting, although the present application is described in detail with reference to the preferred embodiments, those skilled in the art should understand that the technical solutions of the present application can be modified or replaced equivalently without departing from the spirit and scope of the technical solutions of the present application.
Claims
1. A virtual reality ideological and political content adaptive generation method based on affective computing, characterized in that, The method comprises the following steps: acquiring real-time physiological signal data of a user and calculating a deviation value of the real-time physiological signal data relative to a preset reference value, mapping the deviation value to a normalized visual intervention weight coefficient; preloading at least two three-dimensional color lookup tables in the video memory of a graphics processing unit, the three-dimensional color lookup tables comprising a reference lookup table mapping a reference visual style and a target lookup table mapping a target intervention visual style; in a rasterization stage of a rendering pipeline of a virtual reality scene, rasterizing information primitives in the scene into corresponding pixels, and writing a specific mask identifier value into a position in a stencil buffer corresponding to the pixels; in a fragment shading stage of the rendering pipeline, performing a screen space post-processing step on a current processing pixel generated by rasterization: reading a value of the current processing pixel in the stencil buffer, and determining whether the value is equal to the mask identifier value; if the value is equal to the mask identifier value, setting the visual intervention weight coefficient for the current processing pixel to zero; if the value is not equal to the mask identifier value, keeping the visual intervention weight coefficient unchanged; using the original color value of the current processing pixel as an index, performing texture sampling in the reference lookup table and the target lookup table respectively to obtain a reference color value and a target color value; performing a linear interpolation operation on the reference color value and the target color value using the visual intervention weight coefficient determined in the determining step to obtain a final display pixel color value and outputting the final display pixel color value to a display device; wherein the screen space post-processing step further comprises: acquiring a depth buffer texture generated by the current rendering frame, and sampling the depth buffer texture to obtain a linear depth value of the current processing pixel; calculating a spatial depth modulation coefficient using a preset gradient mapping function, the spatial depth modulation coefficient increasing in a non-linear manner as the linear depth value increases; calculating a product of the visual intervention weight coefficient and the spatial depth modulation coefficient to obtain a local mixing weight; in the linear interpolation operation, using the local mixing weight instead of the visual intervention weight coefficient, so that the mixing ratio of the target lookup table to the pixel color increases as the scene depth increases, simulating a three-dimensional atmospheric perspective effect in the screen space; The executing the screen space post-processing step further comprises: obtaining a velocity buffer texture generated by a current rendering frame, sampling the velocity buffer texture to obtain an instantaneous velocity vector of a current processing pixel in a screen space; calculating a module of the instantaneous velocity vector and taking the module as an instantaneous motion intensity value; calculating a dynamic damping coefficient according to the instantaneous motion intensity value by using a formula as follows: Wherein, D is the dynamic damping coefficient, V cur is the instantaneous motion intensity value, V min is a preset static threshold, V max is a preset extreme speed threshold; when V cur is less than V min , D takes 1.0; when V cur is greater than V max , D takes 0; calculating a product of the visual intervention weight coefficient and the dynamic damping coefficient to obtain an actual mixing weight after motion compensation correction; using the actual mixing weight to replace the visual intervention weight coefficient when executing a linear interpolation operation.
2. The virtual reality ideological content self-adaptive generation method based on emotional computing according to claim 1, characterized in that, the target lookup table comprises red, green, blue color channels and an alpha channel, and the alpha channel has pre-stored screen coordinate distortion intensity values corresponding to the target intervention visual style; the screen space post-processing step further comprises: synchronously acquiring the target color value and the screen coordinate distortion intensity value when performing texture sampling on the target lookup table; modulating the amplitude of a preset reference perturbation vector according to the visual intervention weight coefficient and the screen coordinate distortion intensity value to obtain a pixel offset vector; offsetting and correcting the texture coordinates of the current processing pixel using the pixel offset vector, and outputting the final display pixel color value based on the corrected texture coordinates.
3. The virtual reality ideological content self-adaptive generation method based on emotional computing according to claim 1, characterized in that, The screen space post-processing step further comprises: after performing the linear interpolation operation to obtain the preliminary mixed color value, calculating a first luminance component of the original color value and a second luminance component of the preliminary mixed color value respectively; calculating a luminance compensation coefficient according to the ratio relationship between the first luminance component and the second luminance component; performing uniform scaling correction on the red, green and blue channels of the preliminary mixed color value by using the luminance compensation coefficient to generate a final display pixel color value which retains the original luminance characteristics.
4. The virtual reality ideological content self-adaptive generation method based on emotional computing according to claim 1, characterized in that, The screen space post-processing step further comprises: obtaining a normalized position coordinate of the current processing pixel in a screen coordinate system; calculating a radial distance value of the normalized position coordinate relative to a screen center point; calculating a space adjustment coefficient according to the radial distance value by using a preset radial attenuation function, the space adjustment coefficient monotonically increasing with the increase of the radial distance value; calculating a product of the visual intervention weight coefficient and the space adjustment coefficient to obtain a local effective mixing weight; using the local effective mixing weight to replace the visual intervention weight coefficient when performing the linear interpolation operation.
5. The virtual reality ideological content self-adaptive generation method based on emotional computing according to claim 1, characterized in that, The deviation value of the real-time physiological signal data relative to the preset reference value comprises: constructing a sliding sampling window with a fixed time length, calculating the root mean square value of the real-time physiological signal data in the sliding sampling window; calculating the absolute value of the difference between the root mean square value and the preset reference value, and mapping the absolute value of the difference to the interval of zero to one as the initial value of the visual intervention weight coefficient.
6. The virtual reality ideological content self-adaptive generation method based on emotional computing according to claim 1, characterized in that, The information element comprises a teaching text element, an interactive interface element and a preset historical cultural relic element in the virtual reality scene; and the mask identifier value is a specific integer value reserved in the template buffer and does not participate in the regular scene occlusion culling calculation.
7. The virtual reality ideological content self-adaptive generation method based on emotional computing according to claim 1, characterized in that, The linear interpolation operation comprises: multiplying a difference value obtained by subtracting the visual intervention weight coefficient from one by the reference color value to obtain a first component; multiplying the target color value by the visual intervention weight coefficient to obtain a second component; and adding the first component and the second component to obtain the final display pixel color value.
8. The virtual reality ideological content self-adaptive generation method based on emotional computing according to claim 1, characterized in that, The preset gradient mapping function is a smooth step function, the space depth modulation coefficient is zero when the linear depth value is less than a preset starting distance threshold, is one when the linear depth value is greater than a preset saturation distance threshold, and is smoothly interpolated between the starting distance threshold and the saturation distance threshold.
Citation Information
Patent Citations
Ideological and political interaction method based on virtual reality
CN117153004A
Graph mask method, system and device based on OpenGL SC and medium
CN120014148A
Method and device for processing content based on bio-signals
US20160210407A1