Music-based Ambient Light Display Method, Device, Equipment and Storage Medium

By obtaining the beat information and emotional type of the audio file, dynamically controlling the brightness and color of the on-board ambient lights, the problem of light beats in the existing technology does not conform to the rhythm of the music and improves the user experience.

CN114828359BActive Publication Date: 2025-08-01DONGFENG MOTOR CO LTD DONGFENG NISSAN PASSENGER VEHICLE CO
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202210577111.3
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-05-25
Publication Date
2025-08-01
Estimated Expiration
2042-05-25

AI Technical Summary

Technical Problem

The existing on-board ambient light technology cannot make the lights dance more in line with the rhythm of the music, resulting in the ambient light display being not vivid enough and the user experience is insufficient.

Method used

By obtaining the beat information of the audio file, sampling the audio file according to the beat, determining the brightness changes of the sampling points, and controlling the rhythm display of the atmosphere lights in combination with the emotional type and color interval. Algorithms such as dynamic threshold detection and Fourier transform are used to extract the audio rhythm and generate beat files to realize dynamic control of the light.

Benefits of technology

The lights are more in line with the music rhythm, which improves the user's sense of rhythm and the vividness of the ambient lights, and improves the display effect of the ambient lights.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN114828359B_ABST
    Figure CN114828359B_ABST
Patent Text Reader

Abstract

The present invention relates to the technical field of vehicle light control, and discloses a music-based ambient light display method, device, equipment and storage medium. The method comprises: when an audio file is played in a vehicle, obtaining a beat file corresponding to the audio file, wherein the beat file includes beat information and time information corresponding to each beat in the beat information; sampling the audio file according to the time information corresponding to each beat to obtain amplitude information of each sampling point; determining the brightness between the current sampling point and the next sampling point according to the amplitude information; and controlling the ambient light to follow the audio file for rhythmic display according to the brightness and the current sampling point, thereby sampling the music according to the beat information rather than sampling at a fixed sampling period, so that the light jumps more "on point", giving the user a better sense of rhythm.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of vehicle lamp control, and particularly to a music-based ambient lamp display method, device, equipment and storage medium. Background Art

[0002] An in-vehicle ambient lamp is a decorative lighting lamp, which usually forms various colors and brightness by controlling the duty cycle of the PWM wave of the light-emitting lamp beads RGB. It is mainly used to make the carriage more gorgeous at night, set off the atmosphere and create an indoor mood, and the light color cannot affect normal safe driving.

[0003] Under normal circumstances, the in-vehicle ambient lamp technology uses ADC to sample the audio signal in real time. It is necessary to preset a sampling period as a fixed sampling period, and then control the brightness of the lamp according to the amplitude at the time of sampling. The attenuation speed within each fixed sampling period is also relatively fixed, and the attenuation is rigid. Summary of the Invention

[0004] The main object of the present invention is to propose a music-based ambient lamp display method, device, equipment and storage medium, aiming to solve the problem of how to make the flicker of the ambient lamp light more in line with the music and improve the rhythm sense of the ambient lamp rhythm.

[0005] To achieve the above object, the present invention provides a music-based ambient lamp display method, which is applied to a vehicle. The music-based ambient lamp display method includes the following steps:

[0006] When the vehicle plays an audio file, obtain the beat file corresponding to the audio file, where the beat file includes beat information and time information corresponding to each beat in the beat information;

[0007] Sample the audio file according to the time information corresponding to each beat to obtain the amplitude information of each sampling point;

[0008] Determine the brightness between the current sampling point and the next sampling point according to the amplitude information;

[0009] Control the ambient lamp to follow the audio file for rhythm display according to the brightness and the current sampling point.

[0010] Optionally, the determining the brightness between the current sampling point and the next sampling point according to the amplitude information includes:

[0011] Obtain the time of the current sampling point and the time of the next sampling point;

[0012] Obtain a sampling window according to the time of the current sampling point and the time of the next sampling point;

[0013] Obtain the brightness attenuation coefficient according to the sampling window;

[0014] Obtain the brightness between the current sampling point and the next sampling point according to the brightness attenuation coefficient, amplitude information, system volume coefficient, and preset brightness state, so as to perform brightness attenuation within the sampling window.

[0015] Optionally, the controlling the atmosphere light to follow the audio file for rhythmic display according to the brightness and the current sampling point includes:

[0016] Obtain the emotional type of the audio file;

[0017] Determine the color range for the atmosphere light display according to the emotional type;

[0018] Control the atmosphere light to follow the audio file for rhythmic display starting from the current sampling point according to the brightness and the color corresponding to the color range.

[0019] Optionally, the controlling the atmosphere light to follow the audio file for rhythmic display starting from the current sampling point according to the brightness and the color corresponding to the color range includes:

[0020] Obtain the main frequency information of the current sampling point;

[0021] Determine the color temperature in the color range according to the main frequency information;

[0022] Control the atmosphere light to follow the audio file for rhythmic display starting from the current sampling point according to the brightness and the color corresponding to the color temperature.

[0023] Optionally, the obtaining the emotional type of the audio file includes:

[0024] Obtain the increase or decrease of the fixed tone in the audio file;

[0025] Count the number of increases or decreases of the fixed tone to obtain the number of changing tones;

[0026] Obtain the note with the highest amplitude and the note with the lowest amplitude in the beat information;

[0027] Obtain the pitch interval according to the note with the highest amplitude and the note with the lowest amplitude;

[0028] Obtain the beat speed according to the number of beats and the corresponding time in the beat information;

[0029] Generate an audio feature vector according to the beat information, the number of changing tones, the pitch interval, the beat speed, and the amplitude information;

[0030] The audio feature vector is recognized by an audio emotion recognition model to obtain the emotion type of the audio file;

[0031] Or,

[0032] Obtain the preset tag information of the audio file; obtain the emotion type of the audio file according to the preset tag information.

[0033] Optionally, the controlling the atmosphere light to rhythmically display following the audio file according to the brightness and the current sampling point further includes:

[0034] Obtain the main color tone configuration information of the atmosphere light;

[0035] Determine the start color and the end color of the color range to be displayed by the atmosphere light according to the main color tone configuration information;

[0036] Control the atmosphere light to rhythmically display following the audio file starting from the current sampling point according to the brightness and the start color and the end color corresponding to the color range.

[0037] Optionally, the obtaining the beat file corresponding to the audio file includes:

[0038] Quantize the audio file to obtain a quantized audio spectrum;

[0039] Convert the time-domain signal of the audio spectrum into a frequency-domain signal through Fourier transform to obtain a converted audio spectrum;

[0040] Perform differential processing on the current spectrum in the converted audio spectrum and the previous spectrum to obtain a processed audio spectrum;

[0041] Detect the processed audio spectrum according to a dynamic threshold to obtain an audio rhythm;

[0042] Quantize the audio rhythm, and extract beat information and the time information corresponding to each beat in the beat information;

[0043] Generate a beat file according to the beat information and the time information corresponding to each beat in the beat information.

[0044] In addition, to achieve the above object, the present invention also proposes an atmosphere light display device based on music, and the atmosphere light display device based on music includes:

[0045] An obtaining module, configured to obtain a beat file corresponding to an audio file when the vehicle plays the audio file, where the beat file includes beat information and the time information corresponding to each beat in the beat information;

[0046] A sampling module, configured to sample the audio file according to the time information corresponding to each beat, and obtain the amplitude information of each sampling point;

[0047] The acquisition module is further configured to determine the brightness between a current sampling point and a next sampling point based on the amplitude information;

[0048] The display module is used to control the atmosphere light to perform rhythmic display following the audio file according to the brightness and the current sampling point.

[0049] In addition, to achieve the above-mentioned purpose, the present invention also proposes a music-based atmosphere light display device, which includes: a memory, a processor, and a music-based atmosphere light display program stored on the memory and runnable on the processor, and the music-based atmosphere light display program is configured to implement the music-based atmosphere light display method as described above.

[0050] In addition, to achieve the above-mentioned purpose, the present invention also proposes a storage medium, on which a music-based atmosphere light display program is stored. When the music-based atmosphere light display program is executed by a processor, the music-based atmosphere light display method as described above is implemented.

[0051] The music-based ambient light display method proposed in the present invention obtains a beat file corresponding to an audio file when a vehicle plays an audio file, wherein the beat file includes beat information and time information corresponding to each beat in the beat information; the audio file is sampled according to the time information corresponding to each beat to obtain amplitude information of each sampling point; the brightness between the current sampling point and the next sampling point is determined according to the amplitude information; and the ambient light is controlled to follow the audio file for rhythmic display according to the brightness and the current sampling point, thereby sampling the music according to the beat information rather than sampling at a fixed sampling period, so that the light jumps more "on point", giving the user a better sense of rhythm. BRIEF DESCRIPTION OF THE DRAWINGS

[0052] Figure 1 This is a schematic structural diagram of a music-based atmosphere light display device in the hardware operating environment involved in an embodiment of the present invention;

[0053] Figure 2 This is a flow chart of a first embodiment of a music-based atmosphere lighting display method according to the present invention;

[0054] Figure 3 Schematic diagram of the overall framework of an embodiment of a music-based atmosphere light display method of the present invention;

[0055] Figure 4Schematic diagram of the process of extracting the beat file for an embodiment of the music-based atmosphere light display method of the present invention;

[0056] Figure 5 Schematic diagram of the process for the second embodiment of the music-based atmosphere light display method of the present invention;

[0057] Figure 6 Schematic diagram of the process for the third embodiment of the music-based atmosphere light display method of the present invention;

[0058] Figure 7 Schematic diagram of the light color distribution for an embodiment of the music-based atmosphere light display method of the present invention;

[0059] Figure 8 Schematic diagram of the functional modules for the first embodiment of the music-based atmosphere light display device of the present invention.

[0060] The realization, functional features and advantages of the object of the present invention will be further described with reference to the embodiments and the accompanying drawings. Detailed implementation manners

[0061] It should be understood that the specific embodiments described herein are only used to explain the present invention and are not used to limit the present invention.

[0062] Refer to Figure 1 , Figure 1 Schematic diagram of the device structure of the hardware operating environment involved in the embodiment solution of the present invention.

[0063] As Figure 1 shown, the device may include: a processor 1001, such as a CPU, a communication bus 1002, a user interface 1003, a network interface 1004, and a memory 1005. Among them, the communication bus 1002 is used to realize the connection and communication between these components. The user interface 1003 may include a display screen (Display), an input unit such as a button. Optionally, the user interface 1003 may further include a standard wired interface and a wireless interface. The network interface 1004 may optionally include a standard wired interface and a wireless interface (such as a Wi-Fi interface). The memory 1005 may be a high-speed RAM memory or a stable memory (non-volatile memory), such as a disk memory. Optionally, the memory 1005 may also be a storage device independent of the aforementioned processor 1001.

[0064] Those skilled in the art can understand that Figure 1 the structure of the music-based atmosphere light display device shown in

[0065] does not constitute a limitation to the music-based atmosphere light display device, and may include more or fewer components than shown, or combine certain components, or have different component arrangements.

[0065] AsFigure 1 As shown in Figure 1 , the memory 1005, which is a storage medium, may include an operating system, a network communication module, a user interface module, and a music-based atmosphere light display program.

[0066] In Figure 1 In the music-based atmosphere light display device shown in Figure 1 , the network interface 1004 is mainly used to connect to the server and communicate with the server for data; the user interface 1003 is mainly used to connect to the user terminal and communicate with the terminal for data; the music-based atmosphere light display device of the present invention calls the music-based atmosphere light display program stored in the memory 1005 through the processor 1001 and executes the music-based atmosphere light display method provided by the embodiments of the present invention.

[0067] Based on the above hardware structure, an embodiment of the music-based atmosphere light display method of the present invention is proposed.

[0068] Referring to Figure 2 , Figure 2 is a schematic flowchart of the first embodiment of the music-based atmosphere light display method of the present invention.

[0069] In the first embodiment, the music-based atmosphere light display method includes the following steps:

[0070] Step S10, when the vehicle plays an audio file, obtain the beat file corresponding to the audio file, where the beat file includes beat information and time information corresponding to each beat in the beat information.

[0071] It should be noted that the execution subject of this embodiment is the vehicle. A music-based atmosphere light display program is installed on the vehicle, and the music-based atmosphere light display can be performed according to the music-based atmosphere light display program. The vehicle includes a host IVI, a digital signal processing (DSP) unit, a body controller CCM, and a light controller. The host IVI is used to output the input audio file and beat file to the DSP unit, sample through the DSP unit, and parse the main frequency information and amplitude information according to the sampled audio information. Calculate the sampling window and light effect based on the main frequency information and amplitude information, and output the sampling window, light effect, and related parameters to the body controller CCM. The body controller CCM calculates the light control and outputs the color and brightness to the light controller, and controls the atmosphere light to change the light according to the color and brightness through the light controller, as Figure 3 shown in the overall framework schematic diagram.

[0072] In a specific implementation, the beats are obtained from the audio file. The original audio file extracts the beats of the audio through algorithms such as difference, FFT, differentiation, and peak detection to generate a text file of beats and time. The beat file can be solved by the in-vehicle computer or provided by the music supplier for unified solution, such as Figure 4 The schematic flow chart of the extraction of the beat file shown

[0073] When solving through the in-vehicle computer, the audio file is quantified to obtain the quantified audio spectrum; the time-domain signal of the audio spectrum is converted into a frequency-domain signal through Fourier transform to obtain the converted audio spectrum; the current spectrum in the converted audio spectrum is differentiated from the previous spectrum to obtain the processed audio spectrum; the audio rhythm is detected according to the dynamic threshold to obtain the audio rhythm; the audio rhythm is quantified, and the beat information and the time information corresponding to each beat in the beat information are extracted; a beat file is generated according to the beat information and the time information corresponding to each beat in the beat information, so as to realize the generation of the beat file, facilitate audio sampling according to the beat file, obtain the brightness change and color of the light of the atmosphere lamp, and make the atmosphere lamp more conform to the rhythm of the audio file

[0074] Step S20, sample the audio file according to the time information corresponding to each beat to obtain the amplitude information of each sampling point

[0075] In this embodiment, the audio is sampled and processed from the DSP module according to the time of each beat point of the audio beat file to obtain the main frequency information and amplitude information of the sampling point. The color temperature can be determined by the main frequency information, and the brightness can be determined by the amplitude information. Since sampling is performed according to the beats, the number of samplings is reduced compared with the existing fixed-period sampling, and the load of the DSP is significantly reduced

[0076] Step S30, determine the brightness between the current sampling point and the next sampling point according to the amplitude information

[0077] It should be noted that the amplitude of the sampling point determines the starting brightness and the ending brightness of the current frame. The brightness between the current sampling point and the next sampling point is determined by the amplitude information to determine the brightness attenuation change of the light of the atmosphere lamp between the current sampling point and the next sampling point

[0078] Step S40, control the atmosphere lamp to follow the audio file for rhythm display according to the brightness and the current sampling point

[0079] In this embodiment, when the vehicle plays an audio file, a beat file corresponding to the audio file is obtained, where the beat file includes beat information and time information corresponding to each beat in the beat information; the audio file is sampled according to the time information corresponding to each beat to obtain amplitude information of each sampling point; the brightness between the current sampling point and the next sampling point is determined according to the amplitude information; and the ambient light is controlled to rhythmically display following the audio file according to the brightness and the current sampling point, so as to sample the music according to the beat information instead of sampling at a fixed sampling period, making the beating of the light more "on the beat" and giving the user a better sense of rhythm.

[0080] Referring to Figure 5 , Figure 5 FIG. Figure 5 is a schematic flowchart of the second embodiment of the method for displaying an ambient light based on music according to the present invention. The second embodiment of the present invention is proposed based on the first embodiment. In the second embodiment, the step S30 includes:

[0081] Step S301, obtain the time of the current sampling point and the time of the next sampling point.

[0082] It should be noted that the ambient light decays in brightness within the time window of the current sampling point and the next sampling point, and the time of the current sampling point and the time of the next sampling point can be obtained through the information of the beat and time in the beat file.

[0083] Step S302, obtain a sampling window according to the time of the current sampling point and the time of the next sampling point.

[0084] In a specific implementation, the time of the sampling window is obtained by t2 - t1, where t2 represents the time of the next sampling point and t1 represents the time of the current sampling point, and a sampling window is obtained according to the time of the next sampling point and the time of the current sampling point.

[0085] Continuing as Figure 3 shown, after calculating the sampling window and the light effect, the amplitude, main frequency, window size, music label, and system volume are output to the body controller to solve the light control, where the amplitude is used to determine the brightness, the main frequency is used to determine the color temperature, the window size is used to determine the starting brightness of the decay, the music label is used to determine the emotional type to obtain the main color, and the system volume is used to determine the volume setting for the day's playback. The light is controlled to rhythmically follow the music according to the determined brightness and color based on the amplitude, main frequency, window size, music label, and system volume.

[0086] Step S303, obtain a brightness decay coefficient according to the sampling window.

[0087] In a specific implementation, the brightness attenuation coefficient β is obtained through k(t2 - t1), where t2 represents the time of the next sampling point, t1 represents the time of the current sampling point, and k represents the attenuation constant. The brightness attenuation coefficient β is obtained based on the time of the next sampling point, the time of the current sampling point, and the attenuation constant.

[0088] Step S304, obtain the brightness between the current sampling point and the next sampling point according to the brightness attenuation coefficient, amplitude information, system volume coefficient, and preset brightness state, so as to perform brightness attenuation within the sampling window.

[0089] In this embodiment, the amplitude of the sampling point determines the starting brightness and the ending brightness of the current frame. The brightness determination method is l = αφF - βFt + m, where m represents the minimum brightness state, that is, the preset brightness state, l represents the brightness, α represents the brightness coefficient, φ represents the system sound coefficient, F represents the sampling point amplitude, β represents the brightness attenuation coefficient, and t is the time elapsed after sampling. The atmosphere light is made to flash according to the music rhythm through the sampling window. The atmosphere light uses the time interval between two beat points as the time window and uses the time of the current sampling point as the starting point of change to make a rhythm, that is, according to the brightness coefficient, system sound coefficient, amplitude information, brightness attenuation coefficient, time elapsed after sampling, and preset brightness state, obtain the brightness between the current sampling point and the next sampling point.

[0090] It should be noted that in this embodiment, the minimum brightness state m is added on the basis of the brightness determination method l = αφF - βFt, which ensures that the light will not go out during the brightness attenuation process, thereby improving the driver experience.

[0091] In this embodiment, by obtaining the time of the current sampling point and the time of the next sampling point; according to the time of the current sampling point and the time of the next sampling point, obtain the sampling window; according to the sampling window, obtain the brightness attenuation coefficient; according to the brightness attenuation coefficient, amplitude information, system volume coefficient, and preset brightness state, obtain the brightness between the current sampling point and the next sampling point, so as to perform brightness attenuation within the sampling window. Compared with the attenuation in each sampling period in a fixed manner, the attenuation method proposed in this embodiment is related to the size of the system sound, the size of the music sound, and the time of this small window, solving the discomfort caused by the reduction of the atmosphere light brightness when the system volume is turned down, and the relative jump is more elastic and variable, and more in line with the change of the rhythm.

[0092] Refer to Figure 6 , Figure 6 is a schematic flowchart of the third embodiment of the method for displaying an atmosphere light based on music according to the present invention. The third embodiment of the present invention is proposed based on the first embodiment. In the third embodiment, the step S40 includes:

[0093] Step S401: Obtain the emotional type of the audio file.

[0094] It should be noted that while controlling the brightness of the light, the change of the light color is also determined. Specifically, the color of the light is determined according to the emotional type of the audio file. Generally, green tones are mainly used for a relaxed mood, blue tones for a sad mood, red tones for a passionate mood, and magenta-purple tones for a sexy mood, etc. For example, the color adjustment range for sad music is from light blue to dark blue. Among them, the emotional type can be obtained through the tags of the audio file or by performing emotional analysis on the audio file.

[0095] Step S402: Determine the color range displayed by the atmosphere light according to the emotional type.

[0096] In a specific implementation, the corresponding relationship between the emotional type and the color range is set. When obtaining the emotional type, the corresponding color range is determined according to the emotional type. For example, the color range corresponding to sad music is from light blue to dark blue, as shown in the schematic diagram of the light color distribution. Figure 7 as shown in the schematic diagram of the light color distribution.

[0097] Step S403: Control the atmosphere light to perform a rhythmic display following the audio file starting from the current sampling point according to the brightness and the color corresponding to the color range.

[0098] In this embodiment, the color range is determined according to the emotional type. For example, when the emotional type is sad, the color range is from light blue to dark blue. Thus, on the basis of the brightness attenuation following the music, the display of the light color is also combined to improve the rhythm of the atmosphere light.

[0099] In one embodiment, step S403 includes:

[0100] Obtain the main frequency information of the current sampling point; determine the color temperature in the color range according to the main frequency information; control the atmosphere light to perform a rhythmic display following the audio file starting from the current sampling point according to the brightness and the color corresponding to the color temperature.

[0101] In this embodiment, the atmosphere light adjusts the color and brightness according to the sampling point frequency and amplitude. The main frequency of the sampling point represents the sharpness of the sound on that day. After determining the main color tone, the level of the current color temperature is determined according to the level of the main frequency. The higher the main frequency, the higher the color temperature. Since the color range is determined according to the emotional type and does not take into account the main frequency of the music, the color temperature in the color range can be determined according to the main frequency information, so that the color of the light can change according to the change of the pitch within the main color tone range, increasing the user experience and the richness of the overall light.

[0102] In one embodiment, step S401 includes:

[0103] Obtain the raising or lowering of the fixed tone in the audio file; count the number of times the fixed tone is raised or lowered to obtain the number of changing tones; obtain the note with the highest amplitude and the note with the lowest amplitude in the beat information; obtain the interval difference according to the note with the highest amplitude and the note with the lowest amplitude; obtain the beat speed according to the number of beats and the corresponding time in the beat information; generate an audio feature vector according to the beat information, the number of changing tones, the interval difference, the beat speed, and the amplitude information; identify the audio feature vector through an audio emotion recognition model to obtain the emotion type of the audio file.

[0104] This embodiment is based on the fact that when there is no label information representing the emotion of the audio file, the emotion type can be determined according to the beat information, the number of changing tones, the interval difference, the beat speed, and the amplitude information of the audio file, thereby improving the accuracy of identifying the emotion type of the audio file.

[0105] In one embodiment, obtain the preset label information of the audio file; obtain the emotion type of the audio file according to the preset label information.

[0106] This embodiment determines the emotion type of the audio file based on the preset label information of the audio file. The atmosphere light determines the main color tone style of the light according to the music labels provided by the audio supplier, such as sad or passionate. The music label determines the color range, and the main color tone of the atmosphere light is controlled by the label information of the music, providing a more appropriate sense of atmosphere for the user. The atmosphere light can adjust the main color tone of the atmosphere light according to the music label.

[0107] In one embodiment, step S40 includes:

[0108] Obtain the main color tone configuration information of the atmosphere light; determine the starting color and the ending color of the color range that the atmosphere light needs to display according to the main color tone configuration information; control the atmosphere light to perform a rhythmic display following the audio file starting from the current sampling point according to the brightness and the starting color and the ending color corresponding to the color range.

[0109] This embodiment determines the main color tone to be displayed based on user interaction. The user can configure the main color tone according to their needs, and determine the starting color and the ending color corresponding to the color range according to the user's configuration information. That is, the user can ignore the label of the audio itself and set the main color tone, selecting the starting color and the ending color, thereby improving the flexibility of the light color display.

[0110] The present invention further provides an atmosphere light display device based on music.

[0111] Refer to Figure 8 , Figure 8 which is a schematic diagram of the functional modules of the first embodiment of the atmosphere light display device based on music of the present invention.

[0112] In the first embodiment of the music-based atmosphere light display device of the present invention, the music-based atmosphere light display device includes:

[0113] An acquisition module 10, configured to obtain a beat file corresponding to an audio file when the vehicle plays the audio file, where the beat file includes beat information and time information corresponding to each beat in the beat information;

[0114] A sampling module 20, configured to sample the audio file according to the time information corresponding to each beat to obtain amplitude information of each sampling point;

[0115] The acquisition module 10 is further configured to determine the brightness between the current sampling point and the next sampling point according to the amplitude information;

[0116] A display module 30, configured to control the atmosphere light to perform a rhythm display following the audio file according to the brightness and the current sampling point.

[0117] In this embodiment, by obtaining the time of the current sampling point and the time of the next sampling point; obtaining a sampling window according to the time of the current sampling point and the time of the next sampling point; obtaining a brightness attenuation coefficient according to the sampling window; and obtaining the brightness between the current sampling point and the next sampling point according to the brightness attenuation coefficient, amplitude information, system volume coefficient, and preset brightness state, so as to perform brightness attenuation within the sampling window. Compared with the attenuation in a fixed manner for each sampling period, the attenuation method proposed in this embodiment is related to the system sound size, the music sound size, and the time of this small window, solving the discomfort caused by the reduction of the atmosphere light brightness when the system volume is turned down, and being more elastic and variable relative to the jump, and more in line with the rhythm change.

[0118] Optionally, the acquisition module 10 is further configured to obtain the time of the current sampling point and the time of the next sampling point;

[0119] Obtain a sampling window according to the time of the current sampling point and the time of the next sampling point;

[0120] Obtain a brightness attenuation coefficient according to the sampling window;

[0121] Obtain the brightness between the current sampling point and the next sampling point according to the brightness attenuation coefficient, amplitude information, system volume coefficient, and preset brightness state, so as to perform brightness attenuation within the sampling window.

[0122] Optionally, the display module 30 is further configured to obtain the emotional type of the audio file;

[0123] Determine the color range of the atmosphere light display according to the emotional type;

[0124] According to the brightness and the color corresponding to the color interval, control the ambient light to rhythmically display following the audio file starting from the current sampling point.

[0125] Optionally, the display module 30 is further configured to obtain the main frequency information of the current sampling point;

[0126] Determine the color temperature in the color interval according to the main frequency information;

[0127] According to the brightness and the color corresponding to the color temperature, control the ambient light to rhythmically display following the audio file starting from the current sampling point.

[0128] Optionally, the display module 30 is further configured to obtain the increase or decrease of the fixed tone in the audio file;

[0129] Count the number of increases or decreases of the fixed tone to obtain the number of changing tones;

[0130] Obtain the note with the highest amplitude and the note with the lowest amplitude in the beat information;

[0131] Obtain the pitch interval according to the note with the highest amplitude and the note with the lowest amplitude;

[0132] Obtain the beat speed according to the number of beats and the corresponding time in the beat information;

[0133] Generate an audio feature vector according to the beat information, the number of changing tones, the pitch interval, the beat speed, and the amplitude information;

[0134] Identify the audio feature vector through an audio emotion recognition model to obtain the emotion type of the audio file;

[0135] Or,

[0136] Obtain the preset tag information of the audio file; obtain the emotion type of the audio file according to the preset tag information.

[0137] Optionally, the display module 30 is further configured to obtain the main color tone configuration information of the ambient light;

[0138] Determine the starting color and the ending color of the color interval to be displayed by the ambient light according to the main color tone configuration information;

[0139] According to the brightness and the starting color and the ending color corresponding to the color interval, control the ambient light to rhythmically display following the audio file starting from the current sampling point.

[0140] Optionally, the acquisition module 10 is further configured to quantize the audio file to obtain a quantized audio spectrum;

[0141] Convert the time-domain signal of the audio spectrum into a frequency-domain signal through Fourier transform to obtain the converted audio spectrum;

[0142] Perform differential processing on the current spectrum in the converted audio spectrum and the previous spectrum to obtain the processed audio spectrum;

[0143] Detect the processed audio spectrum according to the dynamic threshold to obtain the audio rhythm;

[0144] Quantize the audio rhythm, and extract the beat information and the time information corresponding to each beat in the beat information;

[0145] Generate a beat file according to the beat information and the time information corresponding to each beat in the beat information.

[0146] In addition, to achieve the above object, the present invention also proposes a music-based atmosphere light display device, and the music-based atmosphere light display device includes: a memory, a processor, and a music-based atmosphere light display program stored on the memory and executable on the processor, and the music-based atmosphere light display program is configured to implement the music-based atmosphere light display method as described above.

[0147] Since the music-based atmosphere light display device adopts all the technical solutions of the above all embodiments, it at least has all the beneficial effects brought by the technical solutions of the above embodiments, and will not be elaborated herein one by one.

[0148] In addition, an embodiment of the present invention also proposes a storage medium, and a music-based atmosphere light display program is stored on the storage medium, and when the music-based atmosphere light display program is executed by a processor, it implements the music-based atmosphere light display method as described above.

[0149] Since this storage medium adopts all the technical solutions of the above all embodiments, it at least has all the beneficial effects brought by the technical solutions of the above embodiments, and will not be elaborated herein one by one.

[0150] It should be noted that in this article, the terms "include", "comprise" or any other variant thereof are intended to cover non-exclusive inclusion, so that a process, method, article or system including a series of elements not only includes those elements, but also includes other elements not expressly listed, or further includes elements inherent to such process, method, article or system. Without further limitation, an element defined by the statement "including one..." does not exclude the existence of additional identical elements in the process, method, article or system including the element.

[0151] The serial numbers of the embodiments of the present invention above are only for description and do not represent the superiority or inferiority of the embodiments.

[0152] Through the description of the above embodiments, those skilled in the art can clearly understand that the above embodiment methods can be implemented by means of software plus a necessary general hardware platform. Of course, they can also be implemented by hardware, but in many cases the former is a better implementation method. Based on such an understanding, the technical solution of the present invention, in essence, or the part that makes a contribution to the prior art can be embodied in the form of a software product. The computer software product is stored in a computer-readable storage medium as described above (such as ROM / RAM, magnetic disk, optical disc), and includes several instructions for causing an intelligent terminal (which can be a mobile phone, a computer, a server, an air conditioner, or a network device, etc.) to execute the methods described in the various embodiments of the present invention.

[0153] The above are only the preferred embodiments of the present invention, and do not limit the patent scope of the present invention accordingly. Any equivalent structure or equivalent process transformation made by using the description of the specification and drawings of the present invention, or directly or indirectly applied in other related technical fields, shall be equally included in the patent protection scope of the present invention.

Claims

1. A method for displaying an ambient light based on music, characterized in that, Applied to a vehicle, the music-based ambient light display method includes: When the vehicle plays an audio file, obtain the beat file corresponding to the audio file, where the beat file includes beat information and time information corresponding to each beat in the beat information; Sample the audio file according to the time information corresponding to each beat to obtain the amplitude information of each sampling point; Determine the brightness between the current sampling point and the next sampling point according to the amplitude information; Control the ambient light to follow the audio file for rhythmic display according to the brightness and the current sampling point; The determining the brightness between the current sampling point and the next sampling point according to the amplitude information includes: Obtain the time of the current sampling point and the time of the next sampling point; Obtain a sampling window according to the time of the current sampling point and the time of the next sampling point; Obtain a brightness attenuation coefficient according to the sampling window; Obtain the brightness between the current sampling point and the next sampling point according to the brightness attenuation coefficient, amplitude information, system volume coefficient, and preset brightness state to perform brightness attenuation within the sampling window.

2. The method for displaying an atmosphere lamp based on music according to claim 1, wherein, The controlling the ambient light to follow the audio file for rhythmic display according to the brightness and the current sampling point includes: Obtain the emotional type of the audio file; Determine the color range for the ambient light display according to the emotional type; Control the ambient light to follow the audio file to perform rhythmic display starting from the current sampling point according to the brightness and the color corresponding to the color range.

3. The method for displaying an atmosphere light based on music according to claim 2, wherein The controlling the ambient light to follow the audio file to perform rhythmic display starting from the current sampling point according to the brightness and the color corresponding to the color range includes: Obtain the main frequency information of the current sampling point; Determine the color temperature in the color range according to the main frequency information; Control the ambient light to follow the audio file to perform rhythmic display starting from the current sampling point according to the brightness and the color corresponding to the color temperature.

4. The method for displaying an atmosphere light based on music according to claim 2, wherein The obtaining the emotional type of the audio file includes: Obtain the increase or decrease of the fixed tone in the audio file; Count the number of increases or decreases of the fixed tone to obtain the number of changing tones; Obtain the note with the highest amplitude and the note with the lowest amplitude in the beat information; Obtain the pitch interval according to the note with the highest amplitude and the note with the lowest amplitude; Obtain the beat speed according to the number of beats and the corresponding time in the beat information; Generate an audio feature vector according to the beat information, the number of changing tones, the pitch interval, the beat speed, and the amplitude information; Identify the emotional type of the audio file by an audio emotion recognition model for the audio feature vector; Or, Obtain the preset tag information of the audio file; obtain the emotional type of the audio file according to the preset tag information.

5. The method for displaying an ambient light based on music according to any one of claims 1 to 4, characterized in that The controlling the ambient light to follow the audio file to perform rhythmic display according to the brightness and the current sampling point further includes: Obtain the main color configuration information of the ambient light; Determine the starting color and the ending color of the color range that the ambient light needs to display according to the main color configuration information; Control the ambient light to rhythmically display starting from the current sampling point following the audio file according to the brightness and the start color and end color corresponding to the color interval.

6. The method for displaying an ambient light based on music according to any one of claims 1 to 4, characterized in that, The obtaining the beat file corresponding to the audio file includes: Quantize the audio file to obtain a quantized audio spectrum; Convert the time-domain signal of the audio spectrum into a frequency-domain signal through Fourier transform to obtain a converted audio spectrum; Perform differential processing on the current spectrum and the previous spectrum in the converted audio spectrum to obtain a processed audio spectrum; Detect the processed audio spectrum according to a dynamic threshold to obtain an audio rhythm; Quantize the audio rhythm and extract beat information and the time information corresponding to each beat in the beat information; Generate a beat file according to the beat information and the time information corresponding to each beat in the beat information.

7. An atmosphere lamp display device based on music, characterized in that, The ambient light display device based on music includes: An obtaining module, configured to obtain a beat file corresponding to an audio file when the vehicle plays the audio file, where the beat file includes beat information and the time information corresponding to each beat in the beat information; A sampling module, configured to sample the audio file according to the time information corresponding to each beat to obtain the amplitude information of each sampling point; The obtaining module is further configured to determine the brightness between the current sampling point and the next sampling point according to the amplitude information; A display module, configured to control the ambient light to rhythmically display following the audio file according to the brightness and the current sampling point; The obtaining module is further configured to obtain the time of the current sampling point and the time of the next sampling point; Obtain a sampling window according to the time of the current sampling point and the time of the next sampling point; Obtain a brightness attenuation coefficient according to the sampling window; Obtain the brightness between the current sampling point and the next sampling point according to the brightness attenuation coefficient, the amplitude information, the system volume coefficient, and the preset brightness state to perform brightness attenuation within the sampling window.

8. An atmosphere light display device based on music, characterized in that, The ambient light display device based on music includes: a memory, a processor, and an ambient light display program based on music stored on the memory and executable on the processor, where the ambient light display program based on music is configured to implement the ambient light display method according to any one of claims 1 to 6.

9. A storage medium, characterized in that, An ambient light display program based on music is stored on the storage medium, and when the ambient light display program based on music is executed by a processor, it implements the ambient light display method according to any one of claims 1 to 6.

Citation Information

Patent Citations

  • Robot dance movement design method and robot

    CN108744542A

  • Light control method and device of vehicle-mounted entertainment system and vehicle-mounted entertainment system

    CN111332197A