Method for determining and controlling atmosphere lamp color based on picture color extraction algorithm

Through the ambient light adjustment technology based on the picture color extraction algorithm, the problem of ambient light adjustment in the existing technology relying on user manual settings is solved, and dynamic calculation and adjustment of the ambient light color is realized to meet the user's personalized needs and provide an immersive cockpit experience.

CN119078652APending Publication Date: 2024-12-06CHINA FAW CO LTD +1

Patent Information

Application Number
CN202411200400.7
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-08-29
Publication Date
2024-12-06

AI Technical Summary

Technical Problem

The existing ambient light adjustment technology relies on manual settings for users, cannot be dynamically calculated, cannot accurately fit the color atmosphere of the current visual effect of the cockpit, and cannot meet the personalized needs of users.

Method used

Using a picture-based color extraction algorithm, in response to user instructions, select pictures that match the current scene from the preset picture source, extract the main style colors through color analysis, and convert them into the ambient light control signal, dynamically adjust the ambient light color to coordinate and The current scene is consistent with the visual elements.

Benefits of technology

It realizes dynamic calculation and adjustment of the ambient light color, unify the cockpit visual elements, and provides users with a personalized and immersive cockpit experience to meet users' personalized needs.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119078652A_ABST
    Figure CN119078652A_ABST
Patent Text Reader

Abstract

The invention relates to the technical field of vehicles, and discloses a method and system for determining and controlling the color of an atmosphere lamp based on a picture color extraction algorithm, electronic equipment, a storage medium and a vehicle, and the method comprises the steps: responding to a user instruction, and based on a current scene, selecting a picture conforming to the current scene atmosphere from a preset picture source; performing color analysis on the picture based on a picture color extraction algorithm, and extracting at least one group of colors capable of representing the main style of the picture according to preset preference setting; in response to the extracted color, converting the color into an atmosphere lamp control signal; and in response to the analyzed color information of the atmosphere lamp control signal, dynamically adjusting the light emitting color of the atmosphere lamp so as to enable the current scene to be coordinated and consistent with the current visual element. According to the method, the color of the atmosphere lamp can be dynamically calculated and adjusted, main visual elements including a screen and a lamp effect in the cabin are unified, immersive cabin experience is provided for a user, and the individual requirements of the user are met.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of vehicle technology, and in particular to a method, system, electronic device, storage medium and vehicle for determining and controlling the color of an ambient light based on a picture color extraction algorithm. Background Art

[0002] At present, with the continuous iteration of smart cockpit technology and the continuous improvement of entertainment functions, users' demand for personalization and immersion in addition to basic driving and entertainment scenarios is also increasing. The existing technical solutions for ambient light effects include various designs such as user manual customization of ambient light colors, ambient light effect linkage with weather, and effect linkage with sound rhythm.

[0003] The prior art has the following problems:

[0004] 1. It relies on manual settings by the user and cannot perform dynamic calculations;

[0005] 2. It is impossible to provide a color atmosphere that accurately matches the current visual effects of the cockpit.

[0006] Therefore, the present application provides a method for determining and controlling the color of an ambient light based on an image color extraction algorithm to solve the above technical problems. Summary of the invention

[0007] The purpose of the present invention is to provide a method, system, electronic device, storage medium and vehicle for determining and controlling the color of ambient lights based on a picture color extraction algorithm, so as to solve the technical problem in the prior art that the color atmosphere of ambient lights cannot meet the personalized needs of users.

[0008] In order to solve the above technical problems, the present invention provides a method for determining and controlling the color of an atmosphere light based on a picture color extraction algorithm, comprising:

[0009] In response to a user instruction, based on the current scene, a picture that matches the atmosphere of the current scene is selected from a preset picture source;

[0010] In response to the selected picture, based on a picture color extraction algorithm, color analysis is performed on the picture, and at least one group of colors that can represent the main style of the picture is extracted according to a preset preference setting;

[0011] In response to the extracted color, converting into an ambient light control signal, wherein the conversion process includes taking the color value of the color as raw data and encoding the raw data so that the ambient light control signal can be received and parsed;

[0012] In response to the color information of the resolved ambient light control signal, the luminous color of the ambient light is dynamically adjusted to make the current scene consistent with the current visual element.

[0013] In some specific embodiments, in response to a user instruction, based on the current scene, selecting a picture that matches the atmosphere of the current scene from a preset picture source further includes:

[0014] Determining the type of picture to be input according to the current scene set by the user, wherein the scene includes a driving mode, an entertainment mode, and a rest mode;

[0015] Based on the determined picture type, selecting a picture that matches the current scene from the preset picture source, wherein the picture source includes a wallpaper library, a music player cover library, and a video playback frame buffer;

[0016] The selected image is loaded and the integrity and format compatibility of the image are verified.

[0017] In some specific embodiments, in response to the selected picture, based on the picture color extraction algorithm, color analysis is performed on the picture, and at least one group of colors that can represent the main style of the picture is extracted according to preset preference settings, further comprising:

[0018] Initialize the color extraction process;

[0019] Performing color analysis on the selected image, and adjusting color extraction parameters according to the preset preference settings, wherein the preference settings include color vividness, quantity limit, and color extraction area;

[0020] Executing the image color extraction algorithm to calculate a set of main style colors from the image;

[0021] Verify and screen the colors of the main styles to ensure that they meet the color requirements of ambient light control.

[0022] In some specific embodiments, in response to the extracted color, the color is converted into an ambient light control signal, wherein the conversion process includes taking the color value of the color as raw data and encoding the raw data so that the ambient light control signal can be received and parsed, further comprising:

[0023] Converting the extracted color value from the algorithm output format into an internal data format that complies with the ambient light control;

[0024] Splitting the color value into independent components of red, green and blue, and calculating the value of each of the components;

[0025] Based on the communication protocol and signal requirements of the atmosphere lamp, encoding and packaging the components to form an independent control signal;

[0026] Verify the integrity and correctness of each of the control signals.

[0027] In some specific embodiments, in response to the color information of the resolved ambient light control signal, dynamically adjusting the luminous color of the ambient light so that the current scene is consistent with the current visual element further includes:

[0028] Based on the communication interface, the control signal is sent to the atmosphere light domain controller, wherein the communication interface includes CAN and LIN buses;

[0029] Analyzing the control signal to extract the corresponding color information;

[0030] Based on the color information, the color display of the atmosphere light is dynamically adjusted by the atmosphere light domain controller.

[0031] In some specific embodiments, it also includes:

[0032] Set the atmosphere light color service to receive setting values, trigger calculation actions and image input instructions;

[0033] In response to the received service instruction, triggering an ambient light control process;

[0034] In response to the user's interface or voice, the parameters and conditions for the color tracking of the ambient light are customized.

[0035] Based on the same concept, the present invention also provides a system for determining and controlling the color of an atmosphere light based on a picture color extraction algorithm, comprising:

[0036] A picture matching module, configured to select a picture that matches the atmosphere of the current scene from a preset picture source based on the current scene in response to a user instruction;

[0037] a color extraction module configured to, in response to the selected image, perform color analysis on the image based on an image color extraction algorithm, and extract at least one group of colors that can represent the main style of the image according to a preset preference setting;

[0038] A signal conversion module, configured to convert the extracted color into an ambient light control signal in response to the extracted color, wherein the conversion process includes taking the color value of the color as raw data and encoding the raw data so that the ambient light control signal can be received and parsed;

[0039] The dynamic adjustment module is configured to dynamically adjust the luminous color of the atmosphere light in response to the color information of the analyzed atmosphere light control signal so as to make the current scene consistent with the current visual element.

[0040] Based on the same concept, the present invention also provides an electronic device, including: a processor, a communication interface, a memory and a communication bus, wherein the processor, the communication interface and the memory communicate with each other through the communication bus; a computer program is stored in the memory, and when the computer program is executed by the processor, the processor executes the steps of a method for determining and controlling the color of an atmosphere light based on a picture color extraction algorithm.

[0041] Based on the same concept, the present invention also provides a computer-readable storage medium, which stores a computer program that can be executed by an electronic device. When the computer program runs on the electronic device, the electronic device executes the steps of a method for determining and controlling the color of an atmosphere light based on a picture color extraction algorithm.

[0042] Based on the same concept, the present invention also provides a vehicle, which is provided with the system for determining and controlling the color of the ambient light based on the picture color extraction algorithm as described above.

[0043] Compared with the prior art, the invention has the following beneficial effects:

[0044] The present invention discloses a method, system, electronic device, storage medium and vehicle for determining and controlling the color of ambient lights based on a picture color extraction algorithm. The method can dynamically calculate and adjust the color of ambient lights, unify the main visual elements inside the cabin including screens and lighting effects, provide users with an immersive cabin experience, and meet their personalized needs. BRIEF DESCRIPTION OF THE DRAWINGS

[0045] Figure 1 It is a flowchart of a method for determining and controlling the color of an atmosphere light based on a picture color extraction algorithm in some specific embodiments of the present invention;

[0046] Figure 2 It is a schematic diagram of the architecture of the ambient light control in the prior art;

[0047] Figure 3 It is a schematic diagram of color configuration in some applications of a method for determining and controlling the color of an atmosphere light based on a picture color extraction algorithm of the present invention;

[0048] Figure 4 It is a schematic diagram of the architecture of a method for determining and controlling the color of an atmosphere light based on a picture color extraction algorithm in some applications of the present invention;

[0049] Figure 5 It is a flow chart of a method for determining and controlling the color of an atmosphere light based on a picture color extraction algorithm in some applications of the present invention;

[0050] Figure 6It is a structural schematic diagram of some specific embodiments of a system for determining and controlling the color of an atmosphere light based on a picture color extraction algorithm of the present invention;

[0051] Figure 7 It is a schematic diagram of the structure of an electronic device in some specific embodiments of the present invention. DETAILED DESCRIPTION

[0052] In order to make the purpose, technical solutions and advantages of the present application clearer, the present application will be further described in detail below in conjunction with the accompanying drawings. Obviously, the described embodiments are only part of the embodiments of the present application, rather than all the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field without making creative work are within the scope of protection of the present application.

[0053] The terms used in the embodiments of the present application are only for the purpose of describing specific embodiments, and are not intended to limit the present application. The singular forms "a", "said" and "the" used in the embodiments of the present application and the appended claims are also intended to include plural forms, unless the context clearly indicates other meanings, and "multiple" generally includes at least two.

[0054] It should be understood that the term "and / or" used in this article is only a description of the association relationship of associated objects, indicating that there can be three relationships. For example, A and / or B can represent: A exists alone, A and B exist at the same time, and B exists alone. In addition, the character " / " in this article generally indicates that the associated objects before and after are in an "or" relationship.

[0055] It should be understood that although the terms first, second, third, etc. may be used to describe in the embodiments of the present application, these descriptions should not be limited to these terms. These terms are only used to distinguish the descriptions. For example, without departing from the scope of the embodiments of the present application, the first may also be referred to as the second, and similarly, the second may also be referred to as the first.

[0056] As used herein, the words "if" and "if" may be interpreted as "at the time of" or "when" or "in response to determining" or "in response to detecting", depending on the context. Similarly, the phrases "if it is determined" or "if (stated condition or event) is detected" may be interpreted as "when it is determined" or "in response to determining" or "when detecting (stated condition or event)" or "in response to detecting (stated condition or event)", depending on the context.

[0057] It should also be noted that the term "includes", "comprising" or any other variation thereof is intended to cover non-exclusive inclusion, so that a commodity or device including a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such commodity or device. In the absence of more restrictions, the elements defined by the sentence "comprising a ..." do not exclude the existence of other identical elements in the commodity or device including the elements.

[0058] It should be particularly noted that any symbols and / or numbers in the specification that are not marked in the accompanying drawings are not drawing marks.

[0059] Reference Figure 1 , a method for determining and controlling the color of an atmosphere light based on a picture color extraction algorithm, comprising:

[0060] S101, in response to a user instruction, selecting a picture that matches the atmosphere of the current scene from a preset picture source based on the current scene;

[0061] In some of these applications, in response to user instructions, based on the current scene, pictures that match the atmosphere of the current scene are selected from preset picture sources; based on the current scene set by the user, the type of picture to be input is determined, and the scenes include driving mode, entertainment mode, and rest mode; based on the determined picture type, pictures that match the current scene are selected from preset picture sources, and the picture sources include wallpaper library, music player cover library, and video playback frame cache; the selected picture is loaded, and the integrity and format compatibility of the picture are verified.

[0062] It is understandable that this application responds to user instructions, selects pictures that match the atmosphere from the preset picture sources according to the current scene, and verifies the integrity and format compatibility for subsequent extraction and control of the atmosphere light color.

[0063] The user inputs a command through the user interface of the vehicle system (such as a touch screen, voice control, etc.) to specify the current scene. According to the user setting, the current scene is identified as one of the driving mode, entertainment mode or rest mode. For example, if the user says "switch to entertainment mode" through voice, the current scene is determined to be entertainment mode.

[0064] According to the determined scene, the type of picture to be input is further determined. The preset corresponding relationship is as follows:

[0065] Driving Mode: Select images with dynamic, clear sight lines to enhance concentration while driving.

[0066] Entertainment mode: Choose colorful and visually impactful pictures, such as popular covers or dynamic wallpapers for music players, to enhance the entertainment atmosphere.

[0067] Rest mode: Select soft and peaceful pictures, such as natural scenery, starry sky, etc. to create a relaxing rest environment.

[0068] Taking the entertainment mode as an example, determine that the type of picture to be input is "popular cover of music player".

[0069] According to the determined image type, retrieve and select an image that matches the current scene atmosphere from the preset image sources. The preset image sources include:

[0070] Wallpaper library: Contains high-definition wallpapers of various styles, which can be used to create the atmosphere of different scenes.

[0071] Music player cover library: stores popular covers of the music player, related to entertainment mode.

[0072] Video playback frame buffer: As a possible extension source, it is used for ambient light color extraction in video-related scenes.

[0073] Taking the entertainment mode as an example, a colorful and dynamic popular cover is retrieved and selected from the music player cover library as the input image.

[0074] Load the selected image into memory or the specified processing module and perform the following verification steps:

[0075] Integrity verification: Check whether the image file is intact by calculating the file checksum and comparing it with the pre-stored checksum. For example, calculate the MD5 checksum of the current image and compare it with the corresponding MD5 value stored in the library to ensure that the image has not been tampered with or damaged.

[0076] Format compatibility verification: Confirm that the image format (such as JPEG, PNG, etc.) is supported by the system, and that the image's resolution, color depth and other parameters meet the requirements of the color extraction algorithm. For example, the image format is required to be JPEG, the resolution is not less than 1080p, and the color depth is 24 bits. If the selected image does not meet these requirements, an alternative image is automatically selected.

[0077] S102, in response to the selected picture, performing color analysis on the picture based on a picture color extraction algorithm, and extracting at least one group of colors that can represent the main style of the picture according to preset preference settings;

[0078] In some of the applications, in response to a selected picture, based on a picture color extraction algorithm, a color analysis is performed on the picture, and at least one group of colors that can represent the main style of the picture is extracted according to preset preference settings to initialize the color extraction process; a color analysis is performed on the selected picture, and color extraction parameters are adjusted according to preset preference settings, and the preference settings include color vividness, quantity limit, and color extraction area; the picture color extraction algorithm is executed to calculate a group of main style colors from the picture; and the main style colors are verified and screened to ensure that they meet the color requirements of atmosphere lighting control.

[0079] It can be understood that this application responds to the picture selected by the user, uses the picture color extraction algorithm to perform color analysis on the picture, and extracts the color group that can represent the main style of the picture according to the user's preference settings, and finally verifies and screens these colors to ensure that they meet the color requirements of the atmosphere light control.

[0080] Initialize the color extraction process. Ensure that subsequent color analysis can be performed under a unified framework and interface, facilitating cross-platform implementation and subsequent optimization and upgrades.

[0081] For example, determine whether the EyeDropper API is currently supported:

[0082] if('EyeDropper' in window){

[0083] console.log;

[0084] }else{

[0085] console.log;

[0086] }

[0087] Create an EyeDropper object:

[0088] const eyeDropper=new EyeDropper();

[0089] Call the open method to start color picking:

[0090] The color picking process is started by calling the open method of the EyeDropper object. The open method returns a Promise object. After picking a color, the Promise resolves and returns an object containing the color information, for example:

[0091] const btn=document.getElementById('btn');

[0092] btn.addEventListener('click',async()=>{

[0093] try{

[0094] const result=await eyeDropper.open();

[0095] console.log(result);

[0096] const colorHexValue=result.sRGBHex;

[0097] console.log(colorHexValue);

[0098] }catch(e){

[0099] console.log

[0100] }

[0101] });

[0102] Add the Palette API support library. Depending on the type of library used by the project (support library or androidx library), add the corresponding dependency in the project's build.gradle file, for example:

[0103] / / support

[0104] implementation'com.android.support:palette-v7:28.0.0'

[0105] / / androidx

[0106] implementation'androidx.palette:palette:1.0.0'

[0107] Initialize the Palette object:

[0108] Instantiate a Palette.Builder object through the Bitmap and use it to configure and generate the palette.

[0109] For example:

[0110] Bitmap bitmap=BitmapFactory.decodeResource(getResources(),R.drawable.your_image);

[0111] Palette.Builder paletteBuilder=Palette.from(bitmap);

[0112] Palette palette=paletteBuilder.generate();

[0113] Get the color:

[0114] The Palette object provides a variety of methods to obtain different styles of colors, such as vibrant colors (Vibrant), muted colors (Muted), etc.

[0115] For example:

[0116] Palette.Swatch vibrantSwatch=palette.getVibrantSwatch();

[0117] if (vibrantSwatch!= null) {

[0118] int vibrantColor=vibrantSwatch.getRgb();

[0119] }

[0120] The user selects a picture through the picture selector or file browser of the vehicle system and loads the picture into the processing area in the memory. In order to improve the efficiency and accuracy of color extraction, the picture is preprocessed, such as resizing, cropping, denoising, etc.

[0121] Adjust color extraction parameters based on user preferences. Preferences include but are not limited to:

[0122] Color Vibrance: Users can choose whether the extracted colors are bright or soft. For example, if the vividness threshold is set to 70%, the algorithm will prioritize extracting colors with a saturation higher than 70%.

[0123] Quantity limit: The user can specify the number of colors they want to extract. For example, if it is set to 3 colors, the algorithm will output the 3 most representative colors in the image.

[0124] Color extraction area: Users can select or specify a specific area in the image for color extraction through the interface to obtain more accurate color results. For example, the user is only interested in the sky part of the image, so he specifies this area as the color extraction range.

[0125] Execute the image color extraction algorithm to perform color analysis on the image according to the preset preference parameters. The algorithm involves color space conversion (such as from RGB to HSV), color clustering, and color quantization to calculate a set of main style colors from the image.

[0126] Verify and screen the extracted colors to ensure they meet the color requirements for ambient light control. The verification process includes:

[0127] Color compatibility check: Ensures that the extracted colors are within the achievable color gamut of the ambient light to avoid selecting colors that cannot be accurately displayed.

[0128] Evaluation of the rationality of color matching: Based on the basic principles of color matching (such as contrasting colors, adjacent colors, etc.), evaluate whether the extracted color combination is harmonious and beautiful.

[0129] Deduplication and sorting: Remove duplicates from a color set and sort the colors based on corresponding criteria (such as vividness, proportion in the image, etc.).

[0130] For example, a user selects a picture containing a sunset, sea, and beach, and sets the preference parameter to "color vividness 80%, limited to 3 colors". After executing the color extraction algorithm, the following three colors are extracted from the picture:

[0131] Orange-red (representing sunset): HSV value is (10°, 100%, 85%);

[0132] Blue (representing the sea surface): HSV value is (200°, 100%, 70%);

[0133] Yellow (representing the afterglow on the beach): HSV value is (40°, 100%, 90%).

[0134] S103, in response to the extracted color, converting into an atmosphere light control signal, wherein the conversion process includes taking the color value of the color as raw data and encoding the raw data so that the atmosphere light control signal can be received and parsed;

[0135] In some of the applications, in response to the extracted color, it is converted into an ambient light control signal, and the conversion process includes taking the color value of the color as raw data, encoding the raw data so that the ambient light control signal can be received and parsed, converting the extracted color value from the algorithm output format into an internal data format that conforms to the ambient light control; splitting the color value into independent components of red, green and blue, and calculating the value of each component; encoding and packaging each component based on the communication protocol and signal requirements of the ambient light to form an independent control signal; and verifying the integrity and correctness of each control signal.

[0136] It can be understood that this application converts the color values ​​extracted from the picture into signals suitable for ambient light control, including steps such as color value format conversion, component splitting, encoding packaging, and signal verification.

[0137] Convert the color value obtained from the image color extraction algorithm from the algorithm output format (such as HSV, HEX, etc.) to the data format required for internal processing of the ambient light control system. The ambient light control system uses the RGB color space, so the color value needs to be converted to RGB format.

[0138] For example, the color value output by the algorithm is in HSV format, specifically orange-red (HSV value is 10°, 100%, 85%). Through the HSV to RGB conversion formula, the corresponding RGB value is (255, 90, 0).

[0139] The converted RGB color value is split into three independent components: red (R), green (G) and blue (B), and the specific value of each component is calculated. These values ​​will be directly used to control the brightness of the corresponding color LED beads in the atmosphere light.

[0140] For example, continuing with the above example, the color with RGB value (255,90,0) is split into R=255, G=90, B=0.

[0141] Based on the communication protocol and signal requirements of the ambient light, the split color components are encoded and packaged to form independent control signals.

[0142] For example, the ambient light control system uses a serial communication protocol, each color component occupies 8 bits (i.e., one byte), and the control signal uses specific start and stop bits as frame boundaries. Then, for the RGB value (255, 90, 0), it can be encoded as three consecutive bytes: 0xFF, 0x5A, 0x00, and the start and stop bits are added before and after for packaging.

[0143] Before sending the control signal, the integrity and correctness of the signal are verified, including checking whether the signal format meets the specifications, whether the check bit is correct, and whether the signal contains the expected start bit and stop bit.

[0144] For example, the packaged control signal is verified through a built-in verification algorithm (such as CRC verification) to ensure that the signal has not been damaged or tampered with during transmission. If the verification fails, the encoding and packaging process is repeated until the correct control signal is generated.

[0145] In another embodiment, calculating the specific value of each component further includes:

[0146] Enter a color value, which is a number representing a color; determine the number of bits of the color value, which is the number of binary bits contained in the color value; divide the number of bits of the color value by 3 to get the number of bits for each color component; split the color value into three independent components based on the number of bits of each color component; calculate the value of each independent component separately:

[0147] Convert the binary representation of the red component to a decimal value;

[0148] Convert the binary representation of the green component to a decimal value;

[0149] Convert the binary representation of the blue component to a decimal value;

[0150] Outputs the calculated values ​​for the red, green, and blue components.

[0151] The color value includes a 24-bit ARGB color value, where A represents the Alpha channel, R, G, and B represent the red, green, and blue components, respectively, and the number of bits of the color value is 8, 16, or 32. The binary representation of the color value is divided into three equal parts from right to left, each part represents a color component; the binary number of each part is converted to a decimal number to obtain the corresponding color component value. For each color component, the highest bit of its binary representation is shifted left to the highest bit to eliminate any leading zeros; the left-shifted binary number is converted to a decimal number to obtain the final color component value.

[0152] S104, in response to the analyzed color information of the ambient light control signal, dynamically adjusting the luminous color of the ambient light to make the current scene consistent with the current visual element.

[0153] In some of the applications, in response to the color information of the parsed ambient light control signal, the luminous color of the ambient light is dynamically adjusted to make the current scene consistent with the current visual elements. Based on the communication interface, the control signal is sent to the ambient light domain controller, and the communication interface includes CAN and LIN buses; the control signal is parsed to extract the corresponding color information; based on the color information, the color display of the ambient light is dynamically adjusted through the ambient light domain controller.

[0154] It can be understood that this application transmits the control signal to the atmosphere light domain controller through the communication interface based on the color information in the parsed atmosphere light control signal, and the domain controller dynamically adjusts the luminous color of the atmosphere light to achieve coordination and consistency between the current scene and the visual elements.

[0155] The resolved ambient light control signal is sent to the ambient light domain controller through a preset communication interface. The communication interface includes but is not limited to the CAN (Controller Area Network) bus and the LIN (Local Interconnect Network) bus, which are widely used in internal automotive communications and are characterized by high speed and reliability.

[0156] For example, the CAN bus is used as the communication interface, and the control signal is encapsulated into a CAN frame and sent to the ambient light domain controller via the CAN bus. The CAN frame contains all the information of the ambient light control signal, including color information.

[0157] After receiving the control signal, the ambient light domain controller analyzes the signal to extract the color information. The color information is expressed in the form of RGB values, corresponding to the brightness levels of red, green and blue respectively.

[0158] For example, the ambient light domain controller parses the CAN frame and extracts RGB color values, such as (200, 100, 50), which indicates that the color of the ambient light needs to be adjusted to a specific orange tone.

[0159] Based on the extracted color information, the ambient light domain controller dynamically adjusts the luminous color of the ambient light through its internal logic and driving circuits to produce the desired color effect.

[0160] For example, the ambient light domain controller adjusts the brightness of the red, green, and blue LED beads in the ambient light according to the RGB color value (200, 100, 50), so that the ambient light finally presents an orange hue that matches the color extracted from the picture. This adjustment is performed in real time to ensure that the color of the ambient light is always coordinated with the current scene and visual elements.

[0161] Some of these applications also include an atmosphere light color setting service for receiving setting values, triggering calculation actions, and image input instructions; triggering the atmosphere light control process in response to received service instructions; and customizing the parameters and conditions for the atmosphere light color tracking in response to the user through an interface or voice.

[0162] It is understandable that the built-in atmosphere light color service is responsible for receiving setting values ​​from users or other system components, triggering calculation actions and picture input instructions. The instructions are transmitted through predefined interfaces or protocols to ensure the correctness and efficiency of the service.

[0163] The ambient light color service continuously listens for commands from the user interface, voice control system, or other applications, including setting the base color of the ambient light, enabling / disabling the color tracking function, specifying a picture as the color source, etc.

[0164] When receiving a valid service command, the ambient light color service parses the command content and triggers the corresponding ambient light control process according to the command type. For example, if the command is to set the base color to blue, the service will call the color setting interface to adjust the color of the ambient light to blue.

[0165] Allow users to customize the parameters and conditions of the ambient light color tracking through the interface or voice to meet the user's personalized needs.

[0166] Interface customization:

[0167] Users can intuitively set the color tracking parameters through the graphical user interface (GUI) on the display screen of the vehicle system. For example, users can select the sensitivity of color tracking (i.e. the speed and amplitude of color change), color preference (such as preference for warm or cool colors), and whether to enable specific color filtering rules.

[0168] For example, the user can set the color tracking sensitivity to "medium", the color preference to "cool tone", and enable a color filter rule to exclude overly bright colors through the interface. In this way, when receiving new picture input, the color tracking function will adjust the color of the atmosphere light according to these customized parameters and conditions.

[0169] Voice customization:

[0170] Users can also use voice commands to set the parameters and conditions of color tracking. Users only need to say the corresponding voice command, and the system will automatically recognize and perform the corresponding operation.

[0171] For example, if the user says "set the sensitivity of the ambient light color tracking to high and prefer blue tones", after receiving the voice command, the color tracking parameters will be automatically adjusted to make the color changes of the ambient light more sensitive and tend to be blue.

[0172] Combine the following Figures 2 to 5 The following describes some examples of the method for determining and controlling the color of an ambient light based on a picture color extraction algorithm in some applications:

[0173] like Figure 2 As shown, in the conventional ambient light control architecture, the user actively sets the color, which can meet personalized needs, but needs to be improved in flexibility and convenience, and is a static input design. The solution of converting audio signals into rhythm signals can enhance the rhythm of the entertainment scene ambient light, but it is impossible to obtain user-customized color information.

[0174] The goal of this embodiment is to solve the problem that the existing ambient light adjustment solution relies on manual user input and cannot accurately fit the overall visual effect of the cockpit. At present, the algorithm for extracting the main style color according to the input picture has become the standard configuration of the intelligent cockpit system. Using such an algorithm to perform real-time dynamic analysis and calculation of the user interface and apply the results to the ambient light settings can unify the main visual elements inside the cockpit, including the screen and lighting effects, and provide users with a more extreme immersive cockpit experience. At the same time, the solution has good scalability and can apply dynamic color schemes to other visual hardware with color elements.

[0175] This embodiment includes the following:

[0176] Step 1: According to different scenarios of system design, use the specified image as input. The image format can refer to the input requirements of the algorithm in step 2, such as Bitmap format.

[0177] Step 2: Use the standard color extraction API of the car system or other algorithm libraries with similar functions to calculate a set of main style colors based on the input image. Taking the Android system as an example, the Palette API can be used to extract the color of the image:

[0178] Use the from(Bitmap bitmap) method to generate a Palette instance. First, create a Palette.Builder based on the Bitmap. The sample code is as follows:

[0179] / / Generate palette synchronously and return it.

[0180] public Palette createPaletteSync(Bitmap bitmap){

[0181] Palette p=Palette.from(bitmap).generate();

[0182] return p;

[0183] }

[0184] Use the parameter interface of Palette.Builder to set the preferences for generated colors. You can set the available colors, maximum number of colors, color range, result rules, etc., corresponding to the addFilter(), maximumColorCount(), setRegion(), and addTarget() methods.

[0185] like Figure 3As shown, by getting the color configuration interface get <profile>Color() gets the corresponding color. Palette provides the following typical color profiles:

[0186] Light Vibrant

[0187] Vibrant

[0188] Dark Vibrant

[0189] Light Muted

[0190] Muted

[0191] Dark Muted

[0192] Step 3: The vehicle system formats the color information in a standardized format, converts it into a color signal, and sends it to the MCU. For example, the color format obtained in step 2 using the Palette library is an RGB value stored in a Java integer int. The ambient light signal needs to split the integer into corresponding red, green, and blue independent signals: ColorCmd_Red, ColorCmd_Green, and ColorCmd_Blue.

[0193] Step 4: MCU sends the color signal to the ambient light domain controller through the CAN / LIN network.

[0194] Step 5: The ambient light domain controller controls the ambient light display color directly or indirectly according to the color signal based on its own implementation.

[0195] Step 6: Repeat the above process according to the needs of different scenarios.

[0196] like Figure 4 As shown, this embodiment adds an ambient light color service to the vehicle system, which is used to receive setting values ​​from various parties, trigger calculation actions and image input. Possible image input sources include, but are not limited to, the current wallpaper of the vehicle, the current video display, the music cover, the current system display frame, the current game display frame, etc. Possible setting values ​​include, but are not limited to, the ambient light display screen color following, the ambient light desktop color following, the ambient light media playback color following, the ambient light game playback color following, etc. Possible triggering conditions include, but are not limited to, screen display refresh, wallpaper switching, media playback status, game start status, etc. Based on the above input, the ambient light color service module appropriately calls the system standard library or the third-party library to extract the style color of the currently displayed picture, and sends the extracted information to the CAN service. The CAN service converts the color information into a signal format suitable for transmission and forwards it to the MCU. The MCU sends the color signal to the vehicle CAN / LIN network. The ambient light domain controller receives the color signal and applies the signal for direct or indirect color display control.

[0197] This embodiment is described below in conjunction with application scenarios:

[0198] like Figure 5 As shown,

[0199] Implementation scenario 1: The user turns on the synchronization of the ambient light and the system wallpaper desktop. The car system uses the current desktop wallpaper as the input image for color extraction and calculates a set of colors that match the image style as output: 0xFFA494, 0xDE837B, 0x203A08, 0xBD7273. This set of colors is sent to the MCU through the system signal service, and is divided into the following four groups of signals:

[0200] LightVibrantColor{

[0201] Message: IVI_ALU LIN signal: ColorCmd_Red Signal value: 0xFF

[0202] Message: IVI_ALU LIN signal: ColorCmd_Green Signal value: 0xA4

[0203] Message: IVI_ALU LIN signal: ColorCmd_Blue Signal value: 0x94}

[0204] VibrantColor{

[0205] Message: IVI_ALU LIN signal: ColorCmd_Red Signal value: 0xDE

[0206] Message: IVI_ALU LIN signal: ColorCmd_Green Signal value: 0x83

[0207] Message: IVI_ALU LIN signal: ColorCmd_Blue Signal value: 0x7B}

[0208] DarkVibrantColor{

[0209] Message: IVI_ALU LIN signal: ColorCmd_Red Signal value: 0x20

[0210] Message: IVI_ALU LIN signal: ColorCmd_Green Signal value: 0x3A

[0211] Message: IVI_ALU LIN signal: ColorCmd_Blue Signal value: 0x08}

[0212] LightMutedColor{

[0213] Message: IVI_ALU LIN signal: ColorCmd_Red Signal value: 0xBD

[0214] Message: IVI_ALU LIN signal: ColorCmd_Green Signal value: 0x72

[0215] Message: IVI_ALU LIN signal: ColorCmd_Blue Signal value: 0x73}

[0216] The MCU transmits the color signaling to the ambient light domain controller via the CAN / LIN network, directly or indirectly controlling the current ambient light color display. The above process is repeated when the wallpaper is changed.

[0217] Implementation scenario two: The user turns on the synchronization of the ambient light and video playback. After detecting that the application has entered the video playback, the car system starts the real-time color extraction calculation. After every fixed time interval (such as 1s), the car system captures the current video display screen and calculates a set of colors that match the style of the picture as output. This set of colors is standardized in instructions and formats through the system signal service and sent to the MCU. The MCU transmits the color signaling to the ambient light domain controller through the CAN / LIN network, directly or indirectly controlling the current ambient light color display. This achieves real-time synchronization between the ambient light display effect and the video visual effect.

[0218] Implementation scenario three: The user turns on the synchronization of the ambient light and music playback. After detecting that the application has entered the music playback, the car system starts the real-time color extraction calculation. Every time a song switch is detected, the car system intercepts the album cover of the current music as input and calculates a set of colors that match the style of the picture as output. This set of colors is standardized in instructions and formats through the system signal service and sent to the MCU. The MCU transmits the color signaling to the ambient light domain controller through the CAN / LIN network, directly or indirectly controlling the current ambient light color display. This achieves real-time synchronization between the ambient light display effect and the music player visual effect.

[0219] In the above embodiment, the main style color information of the picture or the vehicle computer interface is extracted to control the vehicle ambient light; the vehicle computer system automatically controls the ambient light to change color following the screen display through corresponding design.

[0220] For the method steps disclosed in the above embodiments, the method steps are described as a series of action combinations for the purpose of simple description, but those skilled in the art should know that the embodiments of the present invention are not limited by the order of the actions described, because according to the embodiments of the present invention, some steps can be performed in other orders or simultaneously. Secondly, those skilled in the art should also know that the embodiments described in the specification are all preferred embodiments, and the actions involved are not necessarily required by the embodiments of the present invention.

[0221] like Figure 6 As shown, the present invention also provides a system for determining and controlling the color of an atmosphere light based on a picture color extraction algorithm, comprising:

[0222] The picture matching module 201 is configured to select a picture that matches the atmosphere of the current scene from a preset picture source based on the current scene in response to a user instruction;

[0223] The color extraction module 202 is configured to, in response to the selected picture, perform color analysis on the picture based on a picture color extraction algorithm, and extract at least one group of colors that can represent the main style of the picture according to a preset preference setting;

[0224] A signal conversion module 203 is configured to convert the extracted color into an ambient light control signal in response to the color, wherein the conversion process includes taking the color value of the color as raw data and encoding the raw data so that the ambient light control signal can be received and parsed;

[0225] The dynamic adjustment module 204 is configured to dynamically adjust the luminous color of the ambient light in response to the color information of the analyzed ambient light control signal, so as to make the current scene consistent with the current visual element.

[0226] It is worth noting that although only some basic functional modules are disclosed in the embodiments of the present invention, it does not mean that the composition of the present system is limited to the above basic functional modules. On the contrary, what the present embodiment wants to express is that on the basis of the above basic functional modules, those skilled in the art can arbitrarily add one or more functional modules in combination with the prior art to form an infinite number of embodiments or technical solutions. In other words, the present system is open rather than closed. Just because the present embodiment only discloses individual basic functional modules, it cannot be considered that the protection scope of the claims of the present invention is limited to the disclosed basic functional modules. At the same time, for the convenience of description, the above devices are described in terms of functions and are described separately in various units and modules. Of course, when implementing the present invention, the functions of each unit and module can be implemented in the same or one or more software and / or hardware.

[0227] like Figure 7 As shown, the present invention also provides an electronic device, comprising: a processor, a communication interface, a memory and a communication bus, wherein the processor, the communication interface and the memory communicate with each other through the communication bus; a computer program is stored in the memory, and when the computer program is executed by the processor, the processor executes the steps of a method for determining and controlling the color of an atmosphere light based on a picture color extraction algorithm.

[0228] Figure 7 Schematic diagram of the structure of an electronic device provided by an embodiment of the present invention. Figure 7 The electronic device provided in the embodiment of the present invention includes: one or more processors 710 and a storage device 720; the processor 710 in the electronic device may be one or more, Figure 7 A processor 710 is taken as an example; the storage device 720 is used to store one or more programs; the one or more programs are executed by the one or more processors 710, so that the one or more processors 710 implement the method for determining and controlling the color of the atmosphere light based on the image color extraction algorithm as described in any one of the embodiments of the present invention.

[0229] The electronic device may further include: an input device 730 and an output device 740 .

[0230] The processor 710, storage device 720, input device 730 and output device 740 in the electronic device can be connected via a bus or other means. Figure 7 The example of connecting through bus is taken in the following.

[0231] The storage device 720 in the electronic device is a computer-readable storage medium that can be used to store one or more programs, which can be software programs, computer executable programs and modules, such as the program instructions / modules corresponding to the method for determining and controlling the color of the atmosphere light based on the picture color extraction algorithm provided in the embodiment of the present invention. The processor 710 executes various functional applications and data processing of the electronic device by running the software programs, instructions and modules stored in the storage device 720, that is, the method for determining and controlling the color of the atmosphere light based on the picture color extraction algorithm in the above method embodiment is implemented.

[0232] The storage device 720 may include a program storage area and a data storage area, wherein the program storage area may store an operating system, an application required for at least one function; the data storage area may store data created according to the use of the electronic device, etc. In addition, the storage device 720 may include a high-speed random access memory, and may also include a non-volatile memory, such as at least one disk storage device, a flash memory device, or other non-volatile solid-state storage device. In some instances, the storage device 720 may further include a memory remotely arranged relative to the processor 710, and these remote memories may be connected to the device via a network. Examples of the above-mentioned network include, but are not limited to, the Internet, an intranet, a local area network, a mobile communication network, and combinations thereof.

[0233] The input device 730 may be used to receive input digital or character information and generate key signal input related to user settings and function control of the electronic device. The output device 740 may include a display device such as a display screen.

[0234] The present invention also provides a computer-readable storage medium storing a computer program executable by an electronic device. When the computer program runs on the electronic device, the electronic device executes the steps of a method for determining and controlling the color of an ambient light based on a picture color extraction algorithm.

[0235] Specifically, the computer storage medium of the embodiment of the present invention can adopt any combination of one or more computer-readable media. The computer-readable medium can be a computer-readable signal medium or a computer-readable storage medium. The computer-readable storage medium can be, for example, but not limited to, an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, device or device, or any combination of the above. More specific examples (non-exhaustive list) of computer-readable storage media include: an electrical connection with one or more wires, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the above. In the present embodiment, the computer-readable storage medium can be any tangible medium containing or storing a program, which can be used by an instruction execution system, device or device or used in combination with it.

[0236] The present invention also provides a vehicle, wherein the vehicle is provided with the system for determining and controlling the color of the ambient light based on the picture color extraction algorithm as described above.

[0237] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention, rather than to limit it. Although the present invention has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that they can still modify the technical solutions described in the aforementioned embodiments, or replace some or all of the technical features therein with equivalents. However, these modifications or replacements do not cause the essence of the corresponding technical solutions to deviate from the scope of the technical solutions of the embodiments of the present invention.< / profile>

Claims

1. A method for determining and controlling the color of an atmosphere light based on a picture color extraction algorithm, characterized in that: include: In response to a user instruction, based on the current scene, a picture that matches the atmosphere of the current scene is selected from a preset picture source; In response to the selected picture, based on a picture color extraction algorithm, color analysis is performed on the picture, and at least one group of colors that can represent the main style of the picture is extracted according to a preset preference setting; In response to the extracted color, converting into an ambient light control signal, wherein the conversion process includes taking the color value of the color as raw data and encoding the raw data so that the ambient light control signal can be received and parsed; In response to the color information of the resolved ambient light control signal, the luminous color of the ambient light is dynamically adjusted to make the current scene consistent with the current visual element.

2. The method for determining and controlling the color of an atmosphere light based on a picture color extraction algorithm according to claim 1, characterized in that: In response to a user instruction, based on the current scene, selecting a picture that matches the atmosphere of the current scene from a preset picture source, further comprising: Determining the type of picture to be input according to the current scene set by the user, wherein the scene includes a driving mode, an entertainment mode, and a rest mode; Based on the determined picture type, selecting a picture that matches the current scene from the preset picture source, wherein the picture source includes a wallpaper library, a music player cover library, and a video playback frame buffer; The selected image is loaded and the integrity and format compatibility of the image are verified.

3. The method for determining and controlling the color of an atmosphere light based on a picture color extraction algorithm according to claim 1, characterized in that: In response to the selected picture, based on a picture color extraction algorithm, color analysis is performed on the picture, and at least one group of colors that can represent the main style of the picture is extracted according to a preset preference setting, further comprising: Initialize the color extraction process; Performing color analysis on the selected image, and adjusting color extraction parameters according to the preset preference settings, wherein the preference settings include color vividness, quantity limit, and color extraction area; Executing the image color extraction algorithm to calculate a set of main style colors from the image; Verify and screen the colors of the main styles to ensure that they meet the color requirements of ambient light control.

4. The method for determining and controlling the color of an atmosphere light based on a picture color extraction algorithm according to claim 1, characterized in that: In response to the extracted color, converting into an ambient light control signal, wherein the conversion process includes taking the color value of the color as raw data and encoding the raw data so that the ambient light control signal can be received and parsed, further comprising: Converting the extracted color value from the algorithm output format into an internal data format that complies with the ambient light control; Splitting the color value into independent components of red, green and blue, and calculating the value of each of the components; Based on the communication protocol and signal requirements of the atmosphere lamp, encoding and packaging the components to form an independent control signal; Verify the integrity and correctness of each of the control signals.

5. The method for determining and controlling the color of an atmosphere light based on a picture color extraction algorithm according to claim 1, characterized in that: In response to the color information of the resolved atmosphere light control signal, dynamically adjusting the light color of the atmosphere light so that the current scene is consistent with the current visual element, further comprising: Based on the communication interface, the control signal is sent to the atmosphere light domain controller, wherein the communication interface includes CAN and LIN buses; Analyzing the control signal to extract the corresponding color information; Based on the color information, the color display of the atmosphere light is dynamically adjusted by the atmosphere light domain controller.

6. The method for determining and controlling the color of an atmosphere light based on a picture color extraction algorithm according to any one of claims 1 to 5, characterized in that: Also includes: Set the atmosphere light color service to receive setting values, trigger calculation actions and image input instructions; In response to the received service instruction, triggering an ambient light control process; In response to the user's interface or voice, the parameters and conditions for the color tracking of the ambient light are customized.

7. A system for determining and controlling the color of an atmosphere light based on an image color extraction algorithm, characterized in that: include: A picture matching module, configured to select a picture that matches the atmosphere of the current scene from a preset picture source based on the current scene in response to a user instruction; a color extraction module configured to, in response to the selected image, perform color analysis on the image based on an image color extraction algorithm, and extract at least one group of colors that can represent the main style of the image according to a preset preference setting; A signal conversion module, configured to convert the extracted color into an ambient light control signal in response to the extracted color, wherein the conversion process includes taking the color value of the color as raw data and encoding the raw data so that the ambient light control signal can be received and parsed; The dynamic adjustment module is configured to dynamically adjust the luminous color of the atmosphere light in response to the color information of the analyzed atmosphere light control signal so as to make the current scene consistent with the current visual element.

8. An electronic device, characterized in that: include: A processor, a communication interface, a memory and a communication bus, wherein the processor, the communication interface and the memory communicate with each other via the communication bus; a computer program is stored in the memory, and when the computer program is executed by the processor, the processor executes the steps of the method described in any one of claims 1 to 6.

9. A computer-readable storage medium, characterized in that: It stores a computer program executable by an electronic device, and when the computer program runs on the electronic device, the electronic device executes the steps of the method described in any one of claims 1 to 6.

10. A vehicle, characterized in that: The vehicle is provided with a system for determining and controlling the color of the ambient light based on the picture color extraction algorithm as described in claim 7.

Citation Information

Patent Citations

  • Environmental atmosphere lamp system and control method thereof

    CN101859511A

  • Control method and device of vehicle-mounted atmosphere lamp, storage medium and vehicle-mounted atmosphere lamp

    CN109743819A

  • Atmosphere lamp control system and method based on intelligent driving commercial vehicle

    CN117002375A

  • Vehicle-mounted equipment function fusion control method, device, equipment and storage medium

    CN118205508A

  • In-vehicle atmosphere lamp control method, electronic equipment, storage medium and computer program product

    CN118488633A

Cited By

  • Cabin light control system and method and vehicle

    CN120751558A

  • Control method and device for cabin lighting equipment

    CN122002674A

  • Control method and device for cabin lighting equipment

    CN122002674B