Desktop icon processing method and device and medium
By integrating the icon processing unit in the desktop application module, we can read and process the original icon image of the application, continuously recognize and dot matrix processing, and integrate background effects to generate new icon images, we can solve the problem of icons in the existing technology. Replace complex and waste of storage resources, personalization and consistency of icons, simplifying user operations and improving user experience.
Patent Information
- Application Number
- CN202411330108.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-09-23
- Publication Date
- 2025-01-07
AI Technical Summary
The existing desktop icon replacement solution requires modifying the application's source code or using complex graphic editing tools, which is difficult to meet the personalized needs of ordinary users, and it is impossible to effectively achieve icon consistency and storage resource savings.
Provide a desktop icon processing method, by reading the original icon image of the application in the electronic device, performing continuous color block recognition and dot matrix processing, combining background effects integration, generate new icon images, and integrate them into the desktop application module. Automatically update and refresh icons, support user settings and application behavior monitoring, and realize the personalization and unified style of icons.
It realizes the personalization and consistency of icons, saves storage resources, simplifies user operations, improves user experience and icon management efficiency, and avoids the icon update problem caused by mismatch in application names.
Smart Images

Figure CN119271090A_ABST
Abstract
Description
Technical Field
[0001] The present disclosure generally relates to the field of computer software technology. More specifically, the present disclosure relates to an icon processing method, device and medium. Background Art
[0002] With the popularity of mobile devices such as smartphones and tablets, people are increasingly relying on various applications to meet their work and entertainment needs in their daily lives. As an important interactive element between users and applications, the aesthetics and personalization of application icons have become the focus of many users. However, existing solutions often require modifying the source code of the application or using complex graphic editing tools, which is too cumbersome for ordinary users.
[0003] In view of this, there is an urgent need to provide an icon processing solution to solve the above problems. Summary of the invention
[0004] In order to at least solve one or more of the technical problems mentioned above, the present disclosure proposes an icon processing solution in multiple aspects.
[0005] In the first aspect, the present disclosure provides a desktop icon processing method, which is executed by a desktop icon processing unit of an electronic device, and the method includes: reading an original icon image corresponding to an installed application in the electronic device; performing continuous color block recognition on a foreground image of the original icon image to obtain at least one continuous color block; performing color value processing on pixels of each continuous color block according to specific rules to obtain a dotted foreground image; performing color value modification on a background image of the original icon image to obtain a background effect image; integrating the dotted foreground image and the background effect image to obtain a new icon image with a dotted effect.
[0006] In some embodiments, the pixels of the original icon image are described by a first color model, which is represented based on three primary colors. Continuous color block recognition is performed on the original icon image, including: traversing the pixels of the foreground image of the original icon image, converting the first color model value of the pixel into a second color model value, which is represented based on hue value, saturation value and brightness value; dividing the color blocks according to the hue value of the second color model value combined with the pixel coordinate value to obtain at least one continuous color block.
[0007] In some embodiments, each continuous color block is determined by a target rectangular area, and color value processing of pixels is performed on each continuous color block according to a specific rule to obtain a dotted foreground image, including: determining the origin coordinate information of the target rectangular area corresponding to each continuous color block; taking the origin coordinate information as a starting point, determining a first direction pixel group and a second direction pixel group in the target rectangular area, wherein the first direction and the second direction are perpendicular to each other; performing interval sampling and value assignment on the pixels in the first direction pixel group and the second direction pixel group, respectively, to obtain a first dotted pixel group corresponding to the first direction pixel group and a second dotted pixel group corresponding to the second direction pixel group, wherein two adjacent sampled pixels in the first dotted pixel group and the second dotted pixel group are set to the same first color value, and the pixels between the two adjacent sampled pixels are set to the same first color value. The point is set to a second color value, and the first color value and the second color value are different; the pixel points on the diagonal of the target rectangular area are processed with the same color assignment to obtain a third dotted pixel group, and the pixel points in the third dotted pixel group are set to the first color value; in the first direction pixel group or the second direction pixel group, the reference pixel point is determined according to the step size; with the reference pixel point as the starting point, the pixel points on the line segment parallel to the diagonal are determined as the pixel group to be processed; the pixel points in the pixel group to be processed are processed with the same color assignment to obtain a fourth dotted pixel group, and the color value of the pixel points in the fourth dotted pixel group is the same as the color value of the reference pixel point; the step size is updated, and the step of determining the reference pixel point group according to the step size in the first direction pixel group or the second direction pixel group is returned, and the subsequent steps are executed in sequence until all the pixel points in the target rectangular area are processed.
[0008] In some embodiments, after reading the original icon image corresponding to the installed application in the electronic device, the method also includes: segmenting the foreground and background of the original icon image to obtain a foreground image and a background image; when performing continuous color block recognition on the foreground image of the original icon image, the method also includes: synchronously performing edge detection processing on the foreground image of the original icon image to obtain an edge processing result image; synthesizing the edge processing result image and the rasterized foreground image to obtain an optimized rasterized effect image; synthesizing the optimized rasterized effect image and the background effect to obtain a new icon image.
[0009] In some embodiments, the desktop icon processing unit is integrated in the desktop application module, and the desktop application module includes a user setting unit. The method also includes: when it is determined that the effect startup configuration parameter of the user setting unit is in the on state, reading the original icon image corresponding to the installed application in the electronic device, including: reading the application icon information in the desktop operation database; when it is determined that the application icon information indicates that it has not been processed by the desktop icon processing unit, reading the original icon image corresponding to the application icon information stored in the desktop operation database; after obtaining a new icon image with a dotted effect, the method also includes: automatically writing the new icon image to the desktop operation database; executing the desktop data loading logic, and updating the new icon image to the desktop memory cache area; executing the desktop icon refresh display operation.
[0010] In some embodiments, the method also includes: when the electronic device starts the desktop application module, when it is detected that the effect startup configuration parameter configured via the user setting unit is in the on state, automatically triggering the reading of the original icon image corresponding to the installed application in the electronic device, and performing subsequent operations; or, after the electronic device starts the desktop application module, receiving a startup operation input for the effect startup configuration parameter of the user setting unit; in response to the startup operation, determining that when the effect startup configuration parameter is in the on state, triggering the reading of the original icon image corresponding to the installed application in the electronic device, and performing subsequent operations.
[0011] In some embodiments, the desktop icon processing unit is integrated in the desktop application module, and the desktop application module includes a user setting unit and an application behavior monitoring unit. The method also includes: obtaining an application change event monitored by the application behavior monitoring unit; when the application change event is a new installation of an application or an application version update, and the effect startup configuration parameter of the user setting unit is in the on state, reading the original icon image corresponding to the installed application in the electronic device, including: reading the icon image corresponding to the newly installed application as the original icon image of the newly installed application, or reading the updated icon image corresponding to the updated version of the application as the original icon image corresponding to the updated version of the application.
[0012] In some embodiments, the method also includes: the desktop icon processing unit also includes a universal input and output interface, and an algorithm for performing raster processing on the original icon image is obtained through the input and output interface. The raster processing algorithm includes: performing continuous color block recognition on the foreground image of the original icon image to obtain at least one continuous color block; performing pixel color value processing on each continuous color block according to specific rules to obtain a rasterized foreground image; performing color value modification on the background image of the original icon image to obtain a background effect image; integrating the rasterized foreground image and the background effect image to obtain a new icon image with a rasterized effect.
[0013] In a second aspect, the present disclosure provides an electronic device, comprising: a processor; and a memory storing computer instructions for executing a desktop icon processing method, wherein when the computer instructions are executed by the processor, the electronic device executes the method described in the first aspect.
[0014] In a third aspect, the present disclosure provides a computer-readable storage medium comprising program instructions for executing desktop icon processing operations. When the program instructions are executed by a processor, the method described in the first aspect is implemented.
[0015] Through the desktop icon processing method, device and medium provided above, the method is executed by the desktop icon processing unit of the electronic device, and the method includes: reading the original icon image corresponding to the installed application in the electronic device; performing continuous color block recognition on the foreground image of the original icon image to obtain at least one continuous color block; performing color value processing on the pixel points of each continuous color block according to specific rules to obtain a dotted foreground image; modifying the color value of the background image of the original icon image to obtain a background effect image; integrating the dotted foreground image and the background effect image to obtain a new icon image with a dotted effect. By performing dotted processing on the icon, the style of the original icon can be retained to the greatest extent, the consistency of the icon is enhanced, and the user experience is effectively improved. BRIEF DESCRIPTION OF THE DRAWINGS
[0016] By reading the detailed description below with reference to the accompanying drawings, the above and other objects, features and advantages of the exemplary embodiments of the present disclosure will become readily understood. In the accompanying drawings, several embodiments of the present disclosure are shown in an exemplary and non-limiting manner, and the same or corresponding reference numerals represent the same or corresponding parts, wherein:
[0017] Figure 1 A schematic diagram showing the structure of a desktop application module according to an embodiment of the present disclosure is shown;
[0018] Figure 2 An exemplary flow chart of a desktop icon processing method 200 according to some embodiments of the present disclosure is shown;
[0019] Figure 3 An exemplary flow chart of a desktop icon processing method 300 according to some embodiments of the present disclosure is shown;
[0020] Figure 4 An exemplary flow chart of a desktop icon processing method 400 according to some embodiments of the present disclosure is shown;
[0021] Figure 5 An exemplary flow chart of a desktop icon processing method 500 according to some embodiments of the present disclosure is shown;
[0022] Figure 6 An exemplary flow chart of an image processing method 600 according to some embodiments of the present disclosure is shown;
[0023] Figure 7a A schematic diagram showing the processing of a local color block of a desktop icon in some embodiments of the present disclosure is shown;
[0024] Figure 7b A schematic diagram showing desktop icon processing results in some embodiments of the present disclosure is shown;
[0025] Figure 8 An exemplary structural block diagram of an electronic device 800 according to an embodiment of the present disclosure is shown. DETAILED DESCRIPTION
[0026] The following will be combined with the drawings in the embodiments of the present disclosure to clearly and completely describe the technical solutions in the embodiments of the present disclosure. Obviously, the described embodiments are part of the embodiments of the present disclosure, not all of the embodiments. Based on the embodiments in the present disclosure, all other embodiments obtained by those skilled in the art without creative work are within the scope of protection of the present disclosure.
[0027] It should be understood that the terms "include" and "comprising" used in the specification and claims of the present disclosure indicate the presence of described features, integers, steps, operations, elements and / or components, but do not exclude the presence or addition of one or more other features, integers, steps, operations, elements, components and / or collections thereof.
[0028] It should also be understood that the terms used in this disclosure are only for the purpose of describing specific embodiments and are not intended to limit the disclosure. As used in this disclosure and claims, the singular forms of "a", "an", and "the" are intended to include the plural forms unless the context clearly indicates otherwise. It should also be further understood that the term "and / or" used in this disclosure and claims refers to any combination of one or more of the associated listed items and all possible combinations, including these combinations.
[0029] As used in this specification and claims, the term "if" may be interpreted as "when" or "upon" or "in response to determining" or "in response to detecting," depending on the context. Similarly, the phrase "if it is determined" or "if [described condition or event] is detected" may be interpreted as meaning "upon determination" or "in response to determining" or "upon detection of [described condition or event]" or "in response to detecting [described condition or event]," depending on the context.
[0030] The specific implementation of the present disclosure is described in detail below with reference to the accompanying drawings.
[0031] In the related art, the icon package application provided by the Android application store is used to replace the desktop icons to meet the user's personalized and diversified needs for desktop icons. The implementation principle is to use the application name (i.e., package name) of the application to match and replace. After the application name is matched, the icon resources displayed on the mobile phone desktop are replaced with the icons preset in the icon package.
[0032] However, there are currently a large number of applications, and the above-mentioned method of downloading icon packages for replacement cannot completely cover all applications on the market. Furthermore, the method that relies on the application name of the application developer cannot continue to match and replace the original application icon after the application developer modifies the application name. The current method of replacing desktop icons cannot achieve icon consistency well.
[0033] Based on this, the present disclosure proposes a desktop icon processing method that can effectively solve the above problems and effectively save the storage resources required for icon processing.
[0034] Figure 1 FIG. 2 shows a schematic diagram of the structure of the desktop application module of the embodiment of the present disclosure. Figure 1 As shown, the desktop application module may include a desktop icon processing unit, a user setting unit, an application behavior monitoring unit, a storage management unit, a desktop application data loading management unit, and a desktop display unit.
[0035] Among them, the desktop icon processing unit is configured to execute the developed and customized image processing flow and image processing algorithm. The desktop icon processing unit is integrated into the mobile phone desktop application. After the desktop application is started, the integrated image processing algorithm is run at a specific time and triggering condition to directly process and store the application icons installed by the user, so as to achieve a unified desktop application icon style and meet the personalized needs of users. The desktop icon processing unit is decoupled from other units, and the desktop icon processing unit also includes a universal input / output interface. The desktop icon processing unit supports the extension of third-party desktop beautification application developers through the universal input / output interface. For example, a third-party desktop beautification application developer can implement a unique third-party provided image effect processing algorithm based on the interface definition of the unit.
[0036] Among them, the user setting unit is configured to dynamically configure the effect startup configuration parameter. The effect startup configuration parameter refers to an on state or an off state. When the effect startup configuration parameter is configured to the on state, it indicates that the desktop icon processing unit performs image processing on the desktop icon. When the effect startup configuration parameter is configured to the off state, it indicates that the desktop icon processing unit does not perform image processing on the desktop icon. The user setting unit can also set factory preset options, such as setting "glass filter" and "dot matrix" effects. Third-party desktop beautification application developers can configure their own effect options according to predefined rules, and dynamically load the effect options provided by the third-party desktop beautification application developers in the user setting unit.
[0037] The application behavior monitoring unit is configured to monitor the status and events of the application programs on the desktop.
[0038] The storage management unit is configured to manage the desktop operation database and the desktop memory cache.
[0039] The desktop application data loading management unit is configured to obtain desktop data from a desktop operation database or other data storage and load the desktop data to the desktop display unit.
[0040] The desktop display unit is configured to display a desktop background, desktop icons, and the like.
[0041] The disclosed embodiment solves the problem of desktop icons being unable to be updated due to application name mismatch by integrating the desktop icon processing unit into the desktop application module, and effectively saves storage space on the electronic device without downloading icon data to the electronic device.
[0042] Figure 2 An exemplary flow chart of a desktop icon processing method 200 of some embodiments of the present disclosure is shown. The method is executed by a desktop icon processing unit of an electronic device, and the desktop icon processing unit is integrated in a desktop application module, and the desktop application module also includes a user setting unit.
[0043] like Figure 2 As shown, in step S201, the original icon image corresponding to the application installed in the electronic device is read.
[0044] In step S202, continuous color blocks are identified on the foreground image of the original icon image to obtain at least one continuous color block.
[0045] In step S203, the color value of each pixel of each continuous color block is processed according to a specific rule to obtain a dot matrix foreground image.
[0046] In step S204, the color value of the background image of the original icon image is modified to obtain a background effect image.
[0047] In step S205, the dot matrix foreground image and the background effect image are integrated to obtain a new icon image with a dot matrix effect.
[0048] In the above steps, in the graphical user interface (GUI), the desktop icons can be divided into a "foreground image" and a "background image" to present different layers. In the present disclosure, the iconic design used to embody the theme of the application is regarded as the foreground image, and the area outside the foreground image where the desktop icons are placed is regarded as the background image. Figure 7b As shown, the original desktop icon is on the left. The foreground image in the original desktop icon includes red dots and black image areas, and the background image is a white area. The foreground image of the exemplary desktop icon is the main part of the desktop icon, which can intuitively reflect the application and facilitate user identification. For example, the desktop icon of a chat application, the pattern part is used to identify the application, and the design style of the application icon reflects the main intention of the application. For another example, the main body of the desktop icon corresponding to some applications is Chinese characters. The background image of the desktop icon is a fixed color.
[0049] In some embodiments, the edges and contours of the foreground image are found in the original icon image through a contour extraction and segmentation method, and then the foreground and background are divided based on the attributes of the contour (such as area, perimeter, etc.).
[0050] After obtaining the foreground image and the background image, one or more continuous color blocks are obtained by performing continuous color block recognition processing on the foreground image, and then each continuous color block is subjected to dot matrix processing. The pixels of the original icon image can be described by a first color model, wherein the first color model is represented based on three primary colors, for example, it can be an ARGB color model or an RGB color model. Performing continuous color block recognition on the original icon image can include: traversing the pixels of the foreground image of the original icon image, converting the first color model value of the pixel into a second color model value, wherein the second color model value is represented based on hue value, saturation value and brightness value; dividing the color blocks according to the hue value of the second color model value combined with the pixel coordinate value, to obtain one or more continuous color blocks. The second color model can be an HSB color model, an HSV color model, or an HSL color model.
[0051] By performing the color model conversion process on the pixel points, the accuracy of color block division can be effectively improved.
[0052] Processing the color values of the pixels of each continuous color block according to a specific rule to obtain a dot matrix foreground image may include traversing the pixels of each continuous color block, modifying the color values of some pixels in each continuous color block to be transparent, and obtaining a dot matrix foreground image. By performing dot matrix processing on the color blocks, the design style of the original icon can be maintained to a great extent, and the personalized needs of users for uniformly modifying icons can be met.
[0053] The embodiments provided in the present disclosure can obtain desktop icons with a consistent style by performing a unified dot matrix image effect processing on the original desktop icon images, thereby meeting the personalized needs of users.
[0054] Figure 3 An exemplary flow chart of a desktop icon processing method 300 of an embodiment of the present disclosure is shown. The method is executed by a desktop icon processing unit of an electronic device, and the desktop icon processing unit is integrated in a desktop application module, and the desktop application module also includes a user setting unit.
[0055] like Figure 3 As shown, in step S301, the original icon image corresponding to the application installed in the electronic device is read.
[0056] In step S302, foreground and background segmentation processing is performed on the original icon image to obtain a foreground image and a background image.
[0057] In step S303, continuous color blocks are identified on the foreground image of the original icon image to obtain at least one continuous color block.
[0058] In step S304, the color value of each pixel of each continuous color block is processed according to a specific rule to obtain a dot matrix foreground image.
[0059] In the above steps, each continuous color block is determined by a target rectangular area, and the color value of the pixel points of each continuous color block is processed according to a specific rule to obtain a dotted foreground image, which may include: determining the origin coordinate information of the target rectangular area corresponding to each continuous color block; taking the origin coordinate information as the starting point, determining a first direction pixel group and a second direction pixel group in the target rectangular area, wherein the first direction and the second direction are perpendicular to each other; performing interval sampling and value assignment on the pixel points in the first direction pixel group and the second direction pixel group, respectively, to obtain a first dotted pixel group corresponding to the first direction pixel group and a second dotted pixel group corresponding to the second direction pixel group, wherein two adjacent sampling pixel points in the first dotted pixel group and the second dotted pixel group are set to the same first color value, and the image between the two adjacent sampling pixel points is The pixel point is set to a second color value, and the first color value and the second color value are different; the pixel points on the diagonal of the target rectangular area are processed with the same color assignment to obtain a third dotted pixel group, and the pixel points in the third dotted pixel group are set to the first color value; in the first direction pixel group or the second direction pixel group, the reference pixel point is determined according to the step size; with the reference pixel point as the starting point, the pixel points on the line segment parallel to the diagonal are determined as the pixel group to be processed; the pixel points in the pixel group to be processed are processed with the same color assignment to obtain a fourth dotted pixel group, and the color value of the pixel points in the fourth dotted pixel group is the same as the color value of the reference pixel point; the step size is updated, and the step of determining the reference pixel point group according to the step size in the first direction pixel group or the second direction pixel group is returned, and the subsequent steps are executed in sequence until all the pixel points in the target rectangular area are processed.
[0060] like Figure 7a As shown, the first direction and the second direction can be the direction of the row or column in the pixel matrix. For example, when the first direction is the row, the second direction is the column. The pixel can be represented by a small rectangular box. The target rectangular area can be a large rectangular box. The red circle is Figure 7b In the part of the original icon image shown, the rectangular area corresponding to the red circle is the target rectangular area corresponding to the first color block.
[0061] The first direction pixel group is a set of pixels in the first row or first column of the target matrix area corresponding to each color block. The second direction pixel group is a set of pixels in the first column or first row of the target matrix area corresponding to each color block. Figure 7a As shown, the first row of pixels in the target rectangular area corresponding to the first color block is a first direction pixel group, and the first column of pixels in the target rectangular area corresponding to the first color block is a second direction pixel group.
[0062] Performing interval sampling and assigning values to pixel points in the first direction pixel group or the second direction pixel group may include performing interval sampling on the pixel points in the first direction pixel group or the second direction pixel group to obtain a plurality of sampling point pixels; and performing value assignment processing on the plurality of sampling point pixels to obtain a plurality of assigned sampling point pixels.
[0063] In the first direction pixel group or the second direction pixel group, other pixel points other than the processed sampling point pixel are assigned values to obtain other pixel points after the assignment.
[0064] The sampling point pixel after the assignment is set to the first color value, and the other pixel points after the assignment are set to the second color value, and the first color value and the second color value are presented alternately, such as Figure 7a , as shown in 7b.
[0065] The reference pixel point is a pixel point determined according to the step size among the pixel points in the first direction pixel group or the second direction pixel group.
[0066] By performing dot matrix processing on the foreground image in the above manner, the design style of the original icon can be maintained to the greatest extent, thereby improving user satisfaction.
[0067] In step S305, when continuous color blocks are recognized on the foreground image of the original icon image, edge detection processing is synchronously performed on the foreground image of the original icon image to obtain an edge processing result image.
[0068] In step S306, the edge processing result image and the rasterized foreground image are synthesized to obtain an optimized rasterized effect image.
[0069] In the above steps, edge detection processing is performed on the foreground image of the original icon image. The contour of the foreground image can be identified by the edge detection algorithm to obtain the contour coordinate information of the foreground image as the edge processing result image, such as Figure 7a As shown in the figure, after being processed by the edge detection algorithm, the edge coordinate information of the red circle can be obtained.
[0070] The edge processing result image and the rasterized foreground image are synthesized to obtain an optimized rasterized effect image, which may include determining, after determining a set of pixels to be assigned in the foreground image, whether each pixel in the pixel set needs to be assigned based on edge coordinate information contained in the edge processing result image.
[0071] When the target rectangular area corresponding to the color block is rasterized, a set of pixels to be assigned can be obtained. According to the relationship between the coordinate information of each pixel in the set of pixels to be assigned and the edge coordinate information of the color block, it is determined whether the pixel to be assigned needs to be assigned.
[0072] like Figure 7a As shown, after determining the coordinate information of the pixel points on the diagonal line of the target rectangular area (i.e., determining the set of pixel points to be assigned), each pixel point is assigned a value judgment one by one, i.e., judging whether the coordinate information of the pixel point is within the edge of the red color block. If so, the color of the pixel point is assigned to the color value of the origin pixel point; if not, the pixel point is not assigned a value.
[0073] By performing edge detection on the foreground image, the rasterization result can be further optimized, making the edges of the original rasterized icon image smoother. The effect will be more significant as the pixel data increases. The edge detection result can further reduce the workload of pixel assignment processing, effectively improving the efficiency of icon processing.
[0074] In step S307, the color value of the background image of the original icon image is modified to obtain a background effect image.
[0075] In step S308, the optimized dot matrix effect image and the background effect are synthesized to obtain a new icon image with a dot matrix effect.
[0076] In the above steps, after the foreground image and the background image of the desktop icon are segmented, the foreground image is subjected to the dot matrix effect processing. The dot matrix effect of the foreground image includes continuous color block recognition processing and color block dot matrix processing. Figure 2 The relevant processing steps are the same as in , and will not be repeated here.
[0077] In some embodiments, for the dot matrix effect processing of the foreground image, the coordinate information of the target rectangular area corresponding to the continuous color blocks can be obtained by a continuous color block recognition algorithm. For example, the longest width and height of the continuous color block can be used as the target matrix area, and the target matrix area is used as the dot matrix processing area. Figure 7a As shown, a target rectangular area corresponding to the first color block, a target rectangular area corresponding to the second color block, and a target rectangular area corresponding to the third color block can be obtained.
[0078] Taking the target rectangular area corresponding to the first color block as an example, starting from the origin pixel of the target rectangular area corresponding to the first color block, the first row and the first column of pixels of the target rectangular area corresponding to the first color block are marked with alternate color assignments. The first pixel is assigned red, the second pixel is assigned transparent, and so on, to complete the color assignment marking of all pixels in the first row and the first column.
[0079] All pixel points on the diagonal line ac of the target rectangular area corresponding to the first color block are determined, and their color values are assigned to be the same color value as the origin pixel point, for example, red.
[0080] Determine the reference pixel in the first row of pixels. Assume that the reference pixel is determined with a step size of 1 pixel. Then, obtain the pixels on all line segments parallel to the diagonal line ac in turn. Assign the color values of these pixels to the color values of the reference pixel in the first row of pixels. After the processing in the x-axis direction is completed, the pixels in the y-axis direction are processed in the same way.
[0081] Assuming that the coordinates of the four vertices of the target rectangular area corresponding to the first color block are a(x1,y1), b(x2,y1), c(x2,y2), and d(x1,y2), all pixels on the diagonal ac of the target rectangular area corresponding to the first color block can be processed as follows: calculate the coordinate information of all pixels on the diagonal ac (that is, find the coordinates of all pixels on the line segment between points a(x1,y1) and c(x2,y2)), and then assign all pixels on the diagonal ac the same color value as the origin pixel.
[0082] The coordinate information of all pixels on the diagonal line ac can be calculated in the following manner: Assuming that there is a point p(x, y) on the diagonal line ac, its coordinate value can be expressed in two-point form as follows:
[0083] y-y1=K(x-x1) (1)
[0084] Where K is the slope value corresponding to the straight line determined by point a and point c, which can be expressed as:
[0085]
[0086] Substituting the slope value K into the two-point formula, we can find
[0087]
[0088] According to the above formula (3), within the range of x value 0≤x≤(x2-x1), assuming that x increases by 1 each time, all the pixel points on the line segment ac can be obtained.
[0089] In some embodiments, after all the pixels on the line segment ac are obtained, the pixel points that are not within the edge detection range are discarded and not processed in combination with the edge detection result, thereby reducing the amount of data processing. The remaining pixel points within the edge detection range have their color values assigned to be the same as the color value of the pixel point a(x1, y1).
[0090] In the first row of pixels, the reference pixel is determined. Then the coordinates of the pixels on the line segment parallel to the diagonal ac along the x-axis are calculated. Assuming that the reference pixel is A1(x1+t,y1), the pixel C1(x2,y2-t) can be determined based on the relationship of being parallel to the diagonal ac, thereby obtaining the pixel on the line segment A1C1 parallel to the diagonal ac. Among them, the value range of the step size t is 0≤t≤(x2-x1), and the step size t can be updated in a unit increment, for example, the unit is 1 pixel. In the same way as obtaining all the pixels on the diagonal ac, all the pixels on the line segment A1C1 can be obtained. Similarly, the pixels that are not within the edge detection range are discarded and not processed. For the remaining pixels on the line segment A1C1 within the edge detection range, the colors of these pixels are assigned to the same color value as the pixel A1(x1+1,y1); and so on, the color values of all the pixels are processed cyclically along the x-axis.
[0091] In the first column of pixels, the reference pixel is determined, and then the coordinates of the pixels on the line segment parallel to the diagonal ac along the y-axis are calculated. Assuming that the reference pixel is A2(x1,y1+t), the pixel C2(x2-t,y2) can be determined based on the relationship of being parallel to the diagonal ac, thereby obtaining the pixel on the line segment A2C2 parallel to the diagonal ac, where the step size t has a value range of 0≤t≤(y2-y1), and the step size t can be updated in increments of units, for example, the unit is 1 pixel. In the same way as obtaining all the pixels on the diagonal ac, all the pixels on the line segment A2C2 can be obtained. Similarly, the pixels that are not within the edge detection range are discarded and not processed. For the remaining pixels on the line segment A2C2 within the edge detection range, the colors of these pixels are assigned the same color value as the pixel A2(x1+1,y1); and so on, the color values of all the pixels are processed cyclically along the y-axis.
[0092] After the pixel set is processed, the pixel set is drawn into a picture, that is, a dotted effect picture is obtained.
[0093] The embodiments of the present disclosure can also synchronously perform edge detection processing on the foreground image while performing continuous color block recognition processing. For example, the edge of the foreground image is segmented according to the contour segmentation algorithm. For example, the edge of the foreground image can also be detected using Canny edge detection. The Canny edge detection algorithm is a more complex and accurate edge detection method. It includes multiple steps such as Gaussian filtering, derivative operations, non-maximum suppression and edge merging. The Canny algorithm can effectively detect clear and continuous edges and suppress the influence of noise. By synthesizing the edge processing result image with the optimized dot matrix effect image, the edge effect of the foreground image can be further optimized, so that the edge of the processed image is more closely aligned with the irregular curve of the foreground image in the original icon image. Figure 7b As shown, the right side is the icon processed with the dot matrix effect obtained by the above image processing method, which retains the original design style of the desktop icon and has a precise and smooth transition at the edges, retaining the original design concept of the desktop icon to the greatest extent.
[0094] The embodiment provided by the present disclosure performs a dot matrix processing on the foreground image of the original icon image, performs an edge detection processing on the foreground image at the same time, and then synthesizes the edge detection processing result and the dot matrix processing result to obtain a more optimized dot matrix effect image. The edges of the image processed by edge detection are smoother and closer to the design style of the original icon, which effectively improves the user experience.
[0095] Figure 4 An exemplary flow chart of a desktop icon processing method 400 of some embodiments of the present disclosure is shown. The method is executed by a desktop icon processing unit of an electronic device, and the desktop icon processing unit is integrated in a desktop application module, and the desktop application module also includes a user setting unit.
[0096] like Figure 4 As shown, in step S401, when the electronic device starts the desktop application module, the effect startup configuration parameters configured by the user setting unit are read.
[0097] In step S402, the effect startup configuration parameter configured by the user setting unit is determined. When it is determined that the effect startup configuration parameter is in the on state, step S403 is entered. When it is determined that the effect startup configuration parameter is in the off state, the original icon image in the desktop operation database is read, the desktop data loading logic is executed, the original icon image is updated to the desktop memory cache area, and the desktop icon refresh display operation is executed.
[0098] In step S403, the application icon information in the desktop operation database is read.
[0099] In step S404, it is determined whether the original icon image has been processed by the desktop icon processing unit according to the application icon information in the desktop operation database. When it is determined that the application icon information in the desktop operation database indicates that it has not been processed by the desktop icon processing unit, the process proceeds to step S405; when it is determined that the application icon information in the desktop operation database indicates that it has been processed by the desktop icon processing unit, the process proceeds to step S408.
[0100] In step S405, the original icon image corresponding to the application icon information stored in the desktop operation database is read.
[0101] In step S406, continuous color blocks are identified on the foreground image of the original icon image to obtain at least one continuous color block.
[0102] In step S407, the color value of each pixel of each continuous color block is processed according to a specific rule to obtain a dot matrix foreground image.
[0103] In step S408, the color value of the background image of the original icon image is modified to obtain a background effect image.
[0104] In step S409, the dot matrix foreground image and the background effect image are integrated to obtain a new icon image with a dot matrix effect.
[0105] In step S410, the new icon image with dot matrix effect is written into the desktop operation database, the desktop data loading logic is executed, the new icon image with dot matrix effect is updated to the desktop memory cache area, and the desktop icon refresh display operation is executed.
[0106] In the above steps, when the electronic device starts the desktop application module, the desktop icon processing unit reads the effect startup configuration parameters. The desktop icon processing unit determines the desktop icons that need to be loaded in the subsequent startup process according to the effect startup configuration parameters. When the effect startup configuration parameters are set to be turned on, the desktop icon processing unit continues to read the application icon information in the desktop operation database; then, it determines whether the desktop icon has been processed according to the application icon information. For example, when the desktop icon processing unit determines that the application icon information indicates that it has not been processed by the desktop icon processing unit, the original icon image corresponding to the application icon information stored in the desktop operation database is read. Continue to process the original icon image, and after the processing is completed, write the new icon image to the desktop operation database. Then execute the desktop data loading logic to update the new icon image to the desktop memory cache area; perform the operation of refreshing the display of the desktop icon.
[0107] When it is determined that the application icon information has been processed by the desktop icon processing unit, the desktop data loading logic is directly executed and the subsequent process tasks are started normally.
[0108] In some embodiments, the application icon information may be information indicating icon modification. The application icon information is used to indicate whether the original icon image has been modified.
[0109] The embodiment provided by the present disclosure integrates the desktop icon processing unit into the desktop application, eliminating the need for users to obtain icon resources through other channels for replacement, effectively saving the storage space required for processing icons. During the desktop startup process, the desktop icon processing unit can self-check the application icon information to avoid the problem of incorrect display results after the modified icon is loaded.
[0110] Figure 5 An exemplary flow chart of a desktop icon processing method 500 according to an embodiment of the present disclosure is shown. The method is executed by a desktop icon processing unit of an electronic device, and the desktop icon processing unit is integrated in a desktop application module, and the desktop application module also includes a user setting unit.
[0111] like Figure 5 As shown, in step S501, after the electronic device starts the desktop application module, a start operation of inputting the effect start configuration parameter of the user setting unit is received.
[0112] Next, in step S502, in response to the start operation, the original icon image stored in the desktop operation database is triggered to be read.
[0113] In the above steps, the enabling operation is to determine that the effect enabling configuration parameter is in the enabling state.
[0114] Then, in step S503, continuous color blocks are identified on the foreground image of the original icon image to obtain at least one continuous color block.
[0115] In step S504, the color value of each pixel of each continuous color block is processed according to a specific rule to obtain a dot matrix foreground image.
[0116] In step S505, the color value of the background image of the original icon image is modified to obtain a background effect image.
[0117] In step S506, the dot matrix foreground image and the background effect image are integrated to obtain a new icon image with a dot matrix effect.
[0118] In step S507, the new icon image with dot matrix effect is written into the desktop operation database; the desktop data loading logic is executed, and the new icon image with dot matrix effect is updated to the desktop memory cache area; and the operation of refreshing the desktop icon display is executed.
[0119] In the above steps, during the normal use of the electronic device, if the user clicks on the turn-on option through the operation interface of the user setting unit, the effect startup configuration parameter is set to the on state. After the user manually sets the icon processing to start, the processing process of the desktop icon processing unit directly reads the original icon image stored in the desktop operation database, and then performs dot matrix image processing on the original icon image to obtain a new icon image with dot matrix effect, and then writes the new icon image with dot matrix effect into the desktop operation database; executes the desktop data loading logic, and updates the new icon image with dot matrix effect to the desktop memory cache area; and executes the operation of refreshing the desktop icon display.
[0120] In some embodiments, the user setting unit may also include a third-party desktop application beautification developer who can configure his own effect options according to predefined rules, and the user setting unit dynamically loads the effect options provided by the third-party desktop application beautification developer. After the user sets the effect startup configuration parameter to the on state through the user setting unit, the user may continue to select the effect option to determine the image processing algorithm used to process the desktop icon, thereby meeting the user's personalized setting needs.
[0121] According to the embodiments provided by the present disclosure, after the electronic device starts the desktop application module, the user can enter the user setting unit at any time and set the effect startup configuration parameter to the on state, thereby triggering the dot matrix effect processing of the original icon image, realizing one-click processing without the need for users to download, install and other tedious operations, simplifying the operation of modifying desktop icons and improving the user experience.
[0122] Figure 6 An exemplary flow chart of an icon processing method 600 of an embodiment of the present disclosure is shown. The method is executed by a desktop icon processing unit of an electronic device, and the desktop icon processing unit is integrated in a desktop application module, and the desktop application module also includes a user setting unit and an application behavior monitoring unit.
[0123] like Figure 6 As shown, in step S601, an application change event monitored by an application behavior monitoring unit is obtained.
[0124] In the above steps, application change events include newly installed applications, application version updates, application deletions, etc.
[0125] In step S602, an application change event is determined. If the application change event is determined to be a newly installed application or an application version update, the process proceeds to step S603. If the application change event is determined to be a deleted application, the process proceeds to step S608.
[0126] In step S603, the effect start configuration parameter configured by the user setting unit is determined. When it is determined that the effect start configuration parameter is in the on state, the process proceeds to step S604. When it is determined that the effect start configuration parameter is in the off state, the process ends.
[0127] In step S604, when it is determined that the effect startup configuration parameter is in the on state, the icon image corresponding to the newly installed application is read as the original icon image of the newly installed application, or the updated icon image corresponding to the updated application is read as the original icon image corresponding to the updated application.
[0128] In step S605, continuous color blocks are identified on the foreground image of the original icon image to obtain at least one continuous color block.
[0129] In step S606, the color value of each pixel of each continuous color block is processed according to a specific rule to obtain a dot matrix foreground image.
[0130] In step S607, the color value of the background image of the original icon image is modified to obtain a background effect image.
[0131] In step S608, the dot matrix foreground image and the background effect image are integrated to obtain a new icon image with a dot matrix effect.
[0132] In step S609, the new icon image with the dot matrix effect is written into the desktop operation database, and the new icon image with the dot matrix effect is updated to the desktop memory cache area; and the operation of refreshing the desktop icon display is executed.
[0133] In step S610, the control deletes the new icon image corresponding to the deleted application in the desktop running database and the desktop memory cache area.
[0134] In the above steps, the modification of the desktop icons for the newly installed applications and the updated applications is automatically triggered by the application behavior monitoring unit. After the desktop application of the electronic device is started, the application behavior monitoring unit will monitor the behavior status of the application, etc. When a newly installed application or an updated application version is monitored, the desktop icon processing unit first determines whether the effect startup configuration parameter is turned on. When it is turned on, the original icon image of the application is read from the storage location corresponding to the newly installed application, or the icon image of the new version of the updated application is read from the storage location corresponding to the updated application as the original icon image to be processed. Then, the icon processing algorithm is called to process the original icon image to obtain a new icon image. Then, the control is completed to store the new icon image in the desktop operation database; and the data loading logic is executed to perform a refresh display operation on the new icon image, and the new icon image is presented on the desktop. After executing the data loading logic, the new icon image is stored in the desktop memory cache area.
[0135] In some embodiments, after the desktop application module of the electronic device is started, the application behavior monitoring unit monitors the deletion event of the application, and the desktop icon processing unit controls the deletion of the icon data left after the application is deleted and stored in the desktop running database and the desktop memory cache area.
[0136] The embodiments provided by the present disclosure use a desktop icon processing unit and an application behavior monitoring unit to solve the problem that desktop icons cannot adaptively match original icons due to application changes, or that deletion of applications leads to residual data and waste of storage space, thereby effectively improving the management efficiency of desktop icons.
[0137] The user can dynamically configure the effect startup configuration parameter through the user setting unit. The effect startup configuration parameter refers to the on state or off state. For example, in the interface corresponding to the user setting unit, clicking on the effect startup function in the interface means that the effect startup configuration parameter is set to the on state, indicating the desktop icon processing unit to perform image processing on the desktop icon.
[0138] When it is determined that the effect startup configuration parameter is in the on state, the desktop icon processing unit performs image processing on the desktop icon according to the current state of the electronic device. For example, the electronic device starts the driver, desktop application, etc. in sequence during the startup process. When the desktop application is started, the desktop icon processing unit integrated in the desktop application reads the configuration parameter, and then determines whether the effect startup configuration parameter is in the on state. When it is in the on state, the desktop icon processing unit executes the subsequent program to automatically process the desktop icon, and after the processing, continues the desktop data loading logic to refresh the display icon.
[0139] When the user setting unit sets the effect startup configuration parameter to the on state, that is, the user clicks the on option of the user setting unit, the desktop icon processing unit automatically executes subsequent programs after receiving the instruction message sent by the user setting unit to process the desktop icons, and after processing, continues the desktop data loading logic to refresh the display icon.
[0140] In some embodiments, the desktop icon processing unit also includes a universal input and output interface, through which an algorithm for performing dot matrix processing on the original icon image is obtained, and the algorithm for dot matrix processing includes: performing continuous color block recognition on the foreground image of the original icon image to obtain at least one continuous color block; performing color value processing on the pixel points of each continuous color block according to a specific rule to obtain a dot matrix foreground image; performing color value modification on the background image of the original icon image to obtain a background effect image; integrating the dot matrix foreground image and the background effect image to obtain a new icon image with a dot matrix effect. By providing a universal input and output interface, the personalized needs of users can be better met.
[0141] The embodiment provided by the present disclosure automatically implements dot matrix effect processing on desktop icons through a desktop icon processing unit integrated in a desktop application module, thereby effectively improving the processing efficiency of desktop icons and solving the problem of being unable to modify desktop icons due to mismatch of application names.
[0142] In some embodiments, more different visual effects can be obtained through algorithm expansion by third-party desktop beautification application developers.
[0143] Figure 8 FIG. 8 is a schematic block diagram of an electronic device 800 according to an embodiment of the present disclosure. Figure 8 As shown, the electronic device 800 may include a processor 801 and a memory 802. The memory 802 stores computer instructions of a desktop icon processing method implemented by a computer. When the computer instructions are executed by the processor 801, the electronic device 800 executes the method according to the above combined method. Figure 2 to Figure 6 For example, in some embodiments, the electronic device 800 may determine the effect startup configuration parameter configured via the user setting unit; when determining that the effect startup configuration parameter is in the on state, read the original icon image corresponding to the application installed in the electronic device; call the pre-configured image processing algorithm to process the original icon image to obtain a new icon image, etc. Based on this, the electronic device 800 can achieve a consistent visual style by integrating the image processing algorithm in the desktop application to achieve unified processing of the desktop icons.
[0144] The disclosed embodiment also provides a computer program product. When the computer program product is run on a computer, the computer is caused to execute the above-mentioned related steps to implement the desktop icon processing method in the above-mentioned embodiment.
[0145] The disclosed embodiment also provides a computer-readable storage medium, in which computer instructions are stored. When the computer instructions are executed on an electronic device, the electronic device executes the above-mentioned related method steps to implement the desktop icon processing method in the above-mentioned embodiment.
[0146] In addition, the disclosed embodiments also provide a device, which may be a chip, a component or a module, and the device may include a connected processor and a memory; wherein the memory is used to store computer execution instructions, and when the device is running, the processor may execute the computer execution instructions stored in the memory so that the chip executes the desktop icon processing method in the above-mentioned method embodiments.
[0147] Among them, the electronic device, computer-readable storage medium, computer program product or chip provided in this embodiment are all used to execute the corresponding methods provided above. Therefore, the beneficial effects that can be achieved can refer to the beneficial effects in the corresponding methods provided above and will not be repeated here.
[0148] Through the description of the above implementation methods, technical personnel in the relevant field can understand that for the convenience and simplicity of description, only the division of the above-mentioned functional modules is used as an example. In actual applications, the above-mentioned functions can be assigned to different functional modules as needed, that is, the internal structure of the device can be divided into different functional modules to complete all or part of the functions described above.
[0149] In the several embodiments provided in the present disclosure, it should be understood that the disclosed devices and methods can be implemented in other ways. For example, the device embodiments described above are only schematic, for example, the division of modules or units is only a logical function division, and there may be other division methods in actual implementation, such as multiple units or components can be combined or integrated into another device, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be through some interfaces, indirect coupling or communication connection of devices or units, which can be electrical, mechanical or other forms.
[0150] The units described as separate components may or may not be physically separated, and the components shown as units may be one physical unit or multiple physical units, that is, they may be located in one place or distributed in multiple different places. Some or all of the units may be selected according to actual needs to achieve the purpose of the present embodiment.
[0151] In addition, each functional unit in each embodiment of the present disclosure may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit. The above integrated unit may be implemented in the form of hardware or in the form of software functional units.
[0152] Any content of each embodiment of the present disclosure, as well as any content of the same embodiment, can be freely combined. Any combination of the above content is within the scope of the present disclosure.
[0153] If the integrated unit is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a readable storage medium. Based on this understanding, the technical solution of the embodiment of the present disclosure is essentially or the part that contributes to the prior art or all or part of the technical solution can be embodied in the form of a software product, which is stored in a storage medium and includes several instructions to enable a device (which can be a single-chip microcomputer, chip, etc.) or a processor (processor) to perform all or part of the steps of the various embodiments of the present disclosure. The aforementioned storage medium includes: U disk, mobile hard disk, read only memory (ROM), random access memory (RAM), disk or optical disk and other media that can store program code.
[0154] The embodiments of the present disclosure are described above in conjunction with the accompanying drawings, but the present disclosure is not limited to the above-mentioned specific implementation methods. The above-mentioned specific implementation methods are merely illustrative and not restrictive. Under the guidance of the present disclosure, ordinary technicians in this field can also make many forms without departing from the scope of protection of the purpose of the present disclosure and the claims, all of which are within the protection of the present disclosure.
[0155] The steps of the method or algorithm described in conjunction with the disclosure of the embodiments of the present disclosure can be implemented in a hardware manner, or can be implemented by a processor executing a software instruction. The software instruction can be composed of corresponding software modules, and the software module can be stored in a random access memory (Random Access Memory, RAM), a flash memory, a read-only memory (Read Only Memory, ROM), an erasable programmable read-only memory (Erasable Programmable ROM, EPROM), an electrically erasable programmable read-only memory (Electrically EPROM, EEPROM), a register, a hard disk, a mobile hard disk, a read-only compact disk (CD-ROM) or any other form of storage medium known in the art. An exemplary storage medium is coupled to a processor so that the processor can read information from the storage medium and can write information to the storage medium. Of course, the storage medium can also be a component of the processor. The processor and the storage medium can be located in an ASIC.
[0156] Those skilled in the art should be aware that in one or more of the above examples, the functions described in the embodiments of the present disclosure can be implemented using hardware, software, firmware, or any combination thereof. When implemented using software, these functions can be stored in a computer-readable medium or transmitted as one or more instructions or codes on a computer-readable medium. Computer-readable media include computer-readable storage media and communication media, wherein the communication media include any media that facilitates the transmission of a computer program from one place to another. The storage medium can be any available medium that a general or special-purpose computer can access.
[0157] Although multiple embodiments of the present disclosure have been shown and described herein, it will be apparent to those skilled in the art that such embodiments are provided by way of example only. Those skilled in the art may think of many changes, modifications, and alternatives without departing from the thought and spirit of the present disclosure. It should be understood that in the process of practicing the present disclosure, various alternatives to the embodiments of the present disclosure described herein may be adopted. The attached claims are intended to define the scope of protection of the present disclosure, and therefore cover equivalents or alternatives within the scope of these claims.
Claims
1. A desktop icon processing method, the method being executed by a desktop icon processing unit of an electronic device, characterized in that: The method includes: Reading the original icon image corresponding to the application installed in the electronic device; Performing continuous color block recognition on the foreground image of the original icon image to obtain at least one continuous color block; Processing the color value of each pixel of each continuous color block according to a specific rule to obtain a dot matrix foreground image; Modifying the color value of the background image of the original icon image to obtain a background effect image; The dot matrix foreground image and the background effect image are integrated to obtain a new icon image with dot matrix effect.
2. The method according to claim 1, characterized in that: The pixel points of the original icon image are described by a first color model, and the first color model is represented based on three primary colors. The continuous color block recognition of the original icon image includes: Traversing the pixel points of the foreground image of the original icon image, converting the first color model value of the pixel point into a second color model value, where the second color model value is represented based on a hue value, a saturation value, and a brightness value; The color blocks are divided according to the hue value of the second color model value in combination with the pixel coordinate value to obtain the at least one continuous color block.
3. The method according to claim 1, characterized in that: Each of the continuous color blocks is determined by a target rectangular area, and color values of pixels of each of the continuous color blocks are processed according to a specific rule to obtain a dot matrix foreground image, including: Determine the origin coordinate information of the target rectangular area corresponding to each of the continuous color blocks; Taking the origin coordinate information as a starting point, determining a first direction pixel group and a second direction pixel group in the target rectangular area, wherein the first direction and the second direction are perpendicular to each other; Performing interval sampling and value assignment on pixel points in the first direction pixel group and the second direction pixel group respectively, to obtain a first dot matrix pixel group corresponding to the first direction pixel group and a second dot matrix pixel group corresponding to the second direction pixel group, wherein two adjacent sampling pixel points in the first dot matrix pixel group and the second dot matrix pixel group are set to the same first color value, and a pixel point between two adjacent sampling pixel points is set to a second color value, and the first color value and the second color value are different; Performing same-color value assignment processing on pixel points on a diagonal line of the target rectangular area to obtain a third dot-matrix pixel group, wherein the pixel points in the third dot-matrix pixel group are set to the first color value; Determining reference pixel points in the first direction pixel group or the second direction pixel group according to the step size respectively; Taking the reference pixel point as a starting point, determining pixel points on a line segment parallel to the diagonal line as a pixel group to be processed; Performing same-color value assignment processing on the pixel points in the pixel group to be processed to obtain a fourth dotted pixel group, wherein the color value of the pixel points in the fourth dotted pixel group is the same as the color value of the reference pixel point; Update the step size, return to the step of determining the reference pixel point group according to the step size in the first direction pixel group or the second direction pixel group, and execute subsequent steps in sequence until all pixel points in the target rectangular area are processed.
4. The method according to claim 3, characterized in that After reading the original icon image corresponding to the application installed in the electronic device, the method further includes: Segmenting the foreground and background of the original icon image to obtain a foreground image and a background image; When performing continuous color block recognition on the foreground image of the original icon image, the method further includes: synchronously performing edge detection processing on the foreground image of the original icon image to obtain an edge processing result image; The edge processing result image and the dotted foreground image are synthesized to obtain an optimized dotted effect image; The optimized dot matrix effect image and the background effect are synthesized to obtain the new icon image.
5. The method according to claim 1, characterized in that The desktop icon processing unit is integrated in a desktop application module, and the desktop application module includes a user setting unit. The method further includes: When it is determined that the effect startup configuration parameter of the user setting unit is in the on state, reading the original icon image corresponding to the application installed in the electronic device includes: Read the application icon information in the desktop running database; When it is determined that the application icon information is not processed by the desktop icon processing unit, reading an original icon image corresponding to the application icon information stored in the desktop operation database; After obtaining the new icon image with the dot matrix effect, the method further includes: Automatically writing the new icon image into the desktop runtime database; Execute desktop data loading logic and update the new icon image to the desktop memory cache area; Refresh the desktop icons.
6. The method according to claim 5, characterized in that The method further includes: When the electronic device starts the desktop application module, when it is detected that the effect startup configuration parameter configured by the user setting unit is in the on state, it automatically triggers reading the original icon image corresponding to the application installed in the electronic device and performs subsequent operations; or After the electronic device starts the desktop application module, receiving a start operation for inputting an effect start configuration parameter of the user setting unit; In response to the start-up operation, it is determined that when the effect start-up configuration parameter is in the start-up state, triggering reading of the original icon image corresponding to the application installed in the electronic device, and performing subsequent operations.
7. The method according to claim 1, characterized in that The desktop icon processing unit is integrated in a desktop application module, and the desktop application module includes a user setting unit and an application behavior monitoring unit. The method further includes: Acquire application change events monitored by the application behavior monitoring unit; When the application change event is a newly installed application or an application version update, and the effect startup configuration parameter of the user setting unit is in an on state, reading the original icon image corresponding to the installed application in the electronic device includes: An icon image corresponding to a newly installed application is read as the original icon image of the newly installed application, or an updated icon image corresponding to a version-updated application is read as the original icon image corresponding to the version-updated application.
8. The method according to claim 1, characterized in that The method also includes: the desktop icon processing unit also includes a universal input and output interface, and an algorithm for performing raster processing on the original icon image is obtained through the input and output interface. The raster processing algorithm includes: performing continuous color block recognition on the foreground image of the original icon image to obtain at least one continuous color block; performing color value processing on the pixel points of each of the continuous color blocks according to specific rules to obtain a rasterized foreground image; performing color value modification on the background image of the original icon image to obtain a background effect image; integrating the rasterized foreground image and the background effect image to obtain a new icon image with a rasterized effect.
9. An electronic device, characterized in that: include: processor; as well as A memory storing computer instructions for executing the icon processing method, wherein when the computer instructions are executed by the processor, the electronic device executes the method according to any one of claims 1 to 8.
10. A computer-readable storage medium, characterized in that: The program instruction for executing icon processing operation is included, and when the program instruction is executed by a processor, the method according to any one of claims 1-8 is implemented.