Icon replacement method, device, terminal device and computer-readable storage medium

By obtaining the uploaded image for element outline recognition and extraction, the target replacement icon is selected and the icons in the interface are replaced, which solves the problem of unfriendly interface interaction and inconvenient icon replacement, and achieves convenient replacement of icons and personalized expression of interface style.

CN113589985BActive Publication Date: 2024-08-23SHANDONG ENERGY CHAIN HLDG CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202110870205.5
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2021-07-30
Publication Date
2024-08-23
Estimated Expiration
2041-07-30

AI Technical Summary

Technical Problem

The interface interaction in the existing technology is not friendly, icon replacement is inconvenient, and users cannot change application icons by themselves, which limits the personalized expression of the interface style.

Method used

By obtaining the uploaded image, identifying and extracting element outlines, selecting the target replacement icon, and replacing the icon to be replaced in the current interface with the target replacement icon, convenient replacement of icons is achieved.

Benefits of technology

It improves the friendly interactivity of the interface, allows users to conveniently replace application icons according to actual needs, and solves the problems of unfriendly interface interaction and inconvenient icon replacement.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN113589985B
    Figure CN113589985B
Patent Text Reader

Abstract

The present invention discloses an icon replacement method, device, terminal equipment and computer-readable storage medium, wherein the method comprises: obtaining an uploaded image; performing element contour recognition and element extraction on the uploaded image, thereby obtaining element icons corresponding to m elements respectively; performing target selection processing on the m element icons to obtain target replacement icons; and replacing the icon to be replaced in the current interface with the target replacement icon. The present invention can solve the technical problems of unfriendly interface interaction and inconvenient icon replacement in the prior art.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of Internet technology, and in particular to an icon replacement method, device, terminal equipment and computer-readable storage medium. Background Art

[0002] An icon is a computer graphic with a clear meaning. For example, after a user installs an application (APP) on a terminal device, the application icon corresponding to the application will be displayed on the terminal device's screen. At present, the display format and arrangement of application icons are relatively fixed. Users use the same application with basically the same icon display style and method, which is not conducive to improving the friendly interaction of the interface.

[0003] In addition, in the prior art, the application icon can only be modified by modifying the application installation package. However, in actual applications, the application installation package is provided by the application developer, and the application installation package cannot be changed in the terminal device system (such as Android). Therefore, it is urgent to propose an icon replacement method. Summary of the invention

[0004] The embodiments of the present application solve the technical problems of unfriendly interface interaction and inconvenient icon replacement in the prior art by providing an icon replacement method, apparatus, terminal device and computer-readable storage medium, thereby achieving the convenience of icon replacement and improving the friendly interaction of the interface.

[0005] On the one hand, the present application provides an icon replacement method through an embodiment of the present application, and the method includes:

[0006] Get the uploaded image;

[0007] Performing element contour recognition and element extraction on the uploaded image, thereby obtaining element icons corresponding to m elements respectively, where m is a positive integer;

[0008] Performing target selection processing on the m element icons to obtain a target replacement icon;

[0009] Replace the icon to be replaced in the current interface with the target replacement icon.

[0010] Optionally, performing element contour recognition and element extraction on the uploaded image to obtain element icons corresponding to the m elements respectively includes:

[0011] Dividing the uploaded image into at least one sub-region according to pixel color, wherein the pixel color of each sub-region is within the same preset range;

[0012] Contour splicing is performed on at least one adjacent sub-region to obtain element icons corresponding to each of the m elements.

[0013] Optionally, performing element contour recognition and element extraction on the uploaded image to obtain element icons corresponding to the m elements respectively includes:

[0014] An image feature recognition algorithm is used to perform element extraction and image segmentation on the uploaded image to obtain element icons corresponding to each of the m elements.

[0015] Optionally, performing target selection processing on the m element icons to obtain a target replacement icon includes:

[0016] Displaying the m element icons on the terminal interface;

[0017] receiving a target instruction generated from the terminal interface, the target instruction being used to instruct determination or outline re-extraction of an element in a target element icon, the target element icon being at least one of the m element icons;

[0018] In response to the target instruction, the target element icon determined or re-extracted as indicated by the target instruction is processed as the target replacement icon.

[0019] Optionally, performing target selection processing on the m element icons to obtain a target replacement icon includes:

[0020] Selecting n high-quality icons that meet a first preset condition from the m element icons, wherein the first preset condition includes at least one of the following: an icon resolution not less than a first threshold, an icon size not less than a second threshold, and an icon file size not less than a third threshold, where n is a positive integer not exceeding m;

[0021] Displaying the n high-quality icons on the terminal interface;

[0022] receiving a target instruction generated from the terminal interface, the target instruction being used to instruct determination or outline re-extraction of an element in a target element icon, the target element icon being at least one of the n high-quality icons;

[0023] In response to the target instruction, the target element icon determined or re-extracted as indicated by the target instruction is processed as the target replacement icon.

[0024] Optionally, if there is one target element icon, processing the target element icon determined or re-extracted as indicated by the target instruction as the target replacement icon includes:

[0025] Determine the target element icon determined or re-extracted as indicated by the target instruction as the target replacement icon;

[0026] Wherein, the target replacement icon is a static icon.

[0027] Optionally, determining the target element icon determined or re-extracted as indicated by the target instruction as the target replacement icon includes:

[0028] Determine the target element icon determined or re-extracted as indicated by the target instruction as a candidate replacement icon;

[0029] The candidate replacement icon is rendered, shaded or filtered to obtain the target replacement icon.

[0030] Optionally, if there are at least two target element icons, processing the target element icon determined or re-extracted as indicated by the target instruction as the target replacement icon includes:

[0031] Dynamically merge at least two target element icons determined or re-extracted as indicated by the target instruction to obtain the target replacement icon;

[0032] Wherein, the target replacement icon is a dynamic icon.

[0033] Optionally, before performing contour recognition and element extraction on the uploaded image, the method further includes:

[0034] Determining whether the uploaded image meets a second preset condition, wherein the second preset condition is that the uploaded image includes at least one element icon, and the elements included in the element icon are independent and do not overlap each other;

[0035] If yes, continue to execute the steps of performing contour recognition and element extraction on the uploaded image.

[0036] Optionally, the element icon is a static icon or a dynamic icon.

[0037] On the other hand, the present application provides an icon replacement device through an embodiment of the present application, the device includes an acquisition module, an extraction module, a processing module and a replacement module, wherein:

[0038] The acquisition module is used to acquire the uploaded image;

[0039] The extraction module is used to perform element contour recognition and element extraction on the uploaded image, so as to obtain element icons corresponding to m elements respectively, where m is a positive integer;

[0040] The processing module is used to perform target selection processing on the m element icons to obtain a target replacement icon;

[0041] The replacement module is used to replace the icon to be replaced in the current interface with the target replacement icon.

[0042] For the contents not described or introduced in this application, please refer to the relevant introduction in the aforementioned method embodiment, which will not be repeated here.

[0043] On the other hand, the present application provides a terminal device through an embodiment of the present application, and the terminal device includes: a processor, a memory, a communication interface and a bus; the processor, the memory and the communication interface are connected through the bus and communicate with each other; the memory stores executable program code; the processor runs a program corresponding to the executable program code by reading the executable program code stored in the memory, so as to execute the icon replacement method as described above.

[0044] On the other hand, the present application provides a computer-readable storage medium through an embodiment of the present application, wherein the computer-readable storage medium stores a program, and when the program runs on an electronic device, the icon replacement method as described above is executed.

[0045] One or more technical solutions provided in the embodiments of the present application have at least the following technical effects or advantages: the present application obtains an uploaded image, performs element contour recognition and element extraction on the uploaded image to obtain element icons corresponding to each of the m elements, performs target selection processing on the m element icons to obtain a target replacement icon, and replaces the icon to be replaced in the current interface with the target replacement icon. In this way, the application icon can be conveniently replaced according to the actual needs of the user, which is conducive to improving the friendly interactivity of the interface, and also solves the technical problems of unfriendly interface interaction and inconvenient icon replacement in the prior art. BRIEF DESCRIPTION OF THE DRAWINGS

[0046] In order to more clearly illustrate the technical solutions in the embodiments of the present invention, the following briefly introduces the drawings required for use in the description of the embodiments. Obviously, the drawings described below are some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without creative work.

[0047] Figure 1 It is a flowchart of an icon replacement method provided in an embodiment of the present application.

[0048] Figure 2 This is a schematic diagram of element icon extraction provided in an embodiment of the present application.

[0049] Figure 3 This is a schematic diagram of another element icon extraction provided in an embodiment of the present application.

[0050] Figure 4 and Figure 5 It is a schematic diagram of the interface before and after the two icons are replaced according to the embodiment of the present application.

[0051] Figure 6 and Figure 7 It is a schematic diagram of the interface before and after the other two icons are replaced according to the embodiment of the present application.

[0052] Figure 8 It is a structural schematic diagram of an icon replacement device provided in an embodiment of the present application.

[0053] Fig. 9 It is a structural diagram of a terminal device provided in an embodiment of the present application. DETAILED DESCRIPTION

[0054] The embodiment of the present application solves the technical problems of unfriendly interface interaction and inconvenient icon replacement in the prior art by providing an icon replacement method.

[0055] The technical solution of the embodiment of the present application is to solve the above-mentioned technical problems, and the overall idea is as follows: obtain an uploaded image; perform element contour recognition and element extraction on the uploaded image to obtain element icons corresponding to m elements, where m is a positive integer; perform target selection processing on the m element icons to obtain a target replacement icon; replace the icon to be replaced in the current interface with the target replacement icon.

[0056] In order to better understand the above technical solution, the above technical solution will be described in detail below in conjunction with the accompanying drawings and specific implementation methods.

[0057] First of all, the term "and / or" in this article is only a description of the association relationship of the associated objects, indicating that there can be three relationships. For example, A and / or B can mean: 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.

[0058] See also Figure 1 , is a flowchart of an icon replacement method provided in an embodiment of the present application. Figure 1 The method shown includes the following implementation steps:

[0059] S101, obtaining an uploaded image.

[0060] The uploaded image in this application is an image that is customized by the user or the system, and includes one or more elements, and the outlines and boundaries of these elements are clear, independent of each other, and there is no overlap between any two elements. The elements include but are not limited to portraits, flowers, animals, trees, clouds, or other image elements.

[0061] S102: performing element contour recognition and element extraction on the uploaded image, thereby obtaining element icons corresponding to m elements respectively, where m is a positive integer.

[0062] In one embodiment, the present application may divide the uploaded image into at least one sub-region according to pixel color (specifically, color pixel value), each sub-region being a partial image region of the uploaded image, and the pixel color of each sub-region is within the same preset range, for example, the pixel colors are all within the range of 200-256 pixels, etc.

[0063] After extracting and obtaining at least one of the sub-regions, the present application may also perform contour splicing on one or more adjacent sub-regions, thereby obtaining an overall contour map corresponding to each of the m elements, and then obtaining an element icon corresponding to each of the m elements. If there are non-connected sub-regions, the relatively independent non-connected sub-regions are discarded.

[0064] In another embodiment, the present application may use an image feature recognition algorithm to extract elements and segment the uploaded image, thereby obtaining element icons corresponding to each of the m elements. The image feature recognition algorithm is a pre-configured and trained algorithm of the system, which may include but is not limited to a deep learning algorithm, a feature point detection algorithm, a depth-first search algorithm, or other algorithms for element extraction.

[0065] For example, see Figure 2 FIG. 4 is a schematic diagram showing an element icon extraction method. Figure 2 In the figure, this application extracts 3 element icons from the uploaded image, as shown in the dotted box.

[0066] For example, if the element icon is a cartoon character icon, please refer to Figure 3 FIG. 2 is a schematic diagram showing another element icon extraction method of the present application. Figure 3 In the example, the uploaded image only includes an element of a cartoon character. The above element extraction method of the present application can be used to extract the following elements: Figure 3 The element icon shown.

[0067] In an optional embodiment, before step S102, the present application may also determine whether the uploaded image meets a second preset condition, where the second preset condition is a condition set by the system to determine whether the uploaded image meets the image standard. For example, the preset condition is that the image includes at least one element icon, and the elements included in the element icon are independent and do not overlap.

[0068] S103: Perform target selection processing on the m element icons to obtain a target replacement icon.

[0069] In one embodiment, the present application may display the m element icons on the terminal interface for the user to screen and confirm the target element icon, or instruct to re-extract the outline of the element after screening. Specifically, the present application may display the identified m element outlines (or m element icons) to the user to screen the target element (or target element icon), and the target element icon is any one or more of the m element icons. In practical applications, there is generally a large color difference on both sides of the outline boundary. If the user believes that the screened target element basically meets the preset requirements (for example, the outline usually contains an independent main element part, such as a full face image; there is no pixel discontinuity in the outline, etc.), then click to confirm and submit. If the user believes that the screened target element does not meet the preset requirements and there is a certain deviation, then it can be further instructed to re-extract the outline of the target element, etc. For example, when the terminal interface detects or receives a user gesture, the outline of the element can be re-extracted in the manner of step S102 within the range of the gesture sliding.

[0070] In another embodiment, the present application may select n high-quality icons that meet the first preset condition from m element icons according to the first preset condition, where n is a positive integer not exceeding m. The first preset condition is a condition for icon screening set by the system or user, which may specifically include but is not limited to any one or more of the following combinations: the icon resolution is not less than the first threshold, the icon size is not less than the second threshold, the icon file size is not less than the third threshold, or other factors affecting the icon quality. The first threshold, the second threshold, and the third threshold are values ​​set by the system, and may also be empirical values ​​set according to user experience.

[0071] The present application can display n high-quality icons on the terminal interface for the user to screen and confirm the target element icon, or instruct to re-extract the outline of the element after screening. Specifically, the present application can display the identified n high-quality icons (or the outline of the element in the high-quality icon) to the user to screen the target element (or target element icon), and the target element icon is any one or more of the n high-quality icons. In practical applications, there is generally a large color difference on both sides of the outline boundary. If the user believes that the screened target element basically meets the preset requirements (for example, the outline usually contains an independent main element part, such as a full face image; there is no pixel discontinuity in the outline, etc.), click to confirm and submit. If the user believes that the screened target element does not meet the preset requirements and there is a certain deviation, it can be further instructed to re-extract the outline of the target element, etc. For example, when the terminal interface detects or receives a user gesture, it can re-adopt step S102 within the range of the gesture sliding to re-extract the outline of the element.

[0072] Accordingly, the present application may receive a target instruction generated from the terminal interface, the target instruction being used to instruct the determination or outline re-extraction of the target element in the target element icon. In practical applications, the number of the target element icons is not limited, and may be one or more, such as two or three.

[0073] Finally, the present application may respond to the target instruction and process the target element icon after the determination or re-extraction of the outline indicated by the target instruction into the target replacement icon.

[0074] In a specific embodiment, if the target element icon is one, the target instruction is used to indicate the determination of the target element in the target element icon, that is, the user believes that the element outline in the filtered icon basically meets the preset requirements and does not need to be adjusted. In this case, the application responds to the target instruction and directly determines the target element icon confirmed by the target instruction as the target replacement icon. At this time, the target replacement icon is a static icon.

[0075] In another specific embodiment, if the target element icon is one, the target instruction is used to instruct to re-extract the outline of the target element in the target element icon, that is, the user believes that the outline of the element in the filtered icon does not meet the preset requirements and needs to re-extract its outline. In this case, the present application responds to the target instruction, first re-extracts the outline of the target element in the target element icon, and then determines the target element icon after the re-extraction of the outline as the target replacement icon, and the target replacement icon is a static icon at this time.

[0076] In an optional embodiment, when responding to the target instruction, the present application may also determine the target element icon indicated by the target instruction or after the outline is re-extracted as a candidate replacement icon. In order to ensure the image effect of the replacement icon, the present application may also perform image processing such as rendering, coloring or filtering on the candidate replacement icon to obtain the final target replacement icon.

[0077] In another specific embodiment, if there are at least two target element icons, the target instruction is used to indicate the determination of the target element in the target element icon, that is, the user believes that the element outline in the filtered icon basically meets the preset requirements and does not need to be adjusted. In this case, the present application responds to the target instruction and dynamically merges the at least two target element icons confirmed by the target instruction to obtain the target replacement icon, and the target replacement icon is a dynamic icon.

[0078] In another specific embodiment, if there are at least two target element icons, the target instruction is used to instruct to re-extract the outline of the target element in the target element icon, that is, the user believes that the outline of the element in the filtered icon does not meet the preset requirements and needs to re-extract its outline. In this case, the present application responds to the target instruction, first re-extracts the outline of the target element in at least two of the target element icons, and then dynamically merges the at least two target element icons after the re-extraction of the outline to obtain the target replacement icon, and the target replacement icon is a dynamic icon.

[0079] In an optional embodiment, to ensure the icon display effect, the present application may also determine the dynamically merged icon as a candidate dynamic icon, and then perform image processing such as rendering, shading or filtering on the candidate dynamic icon to obtain the final target replacement icon.

[0080] S104: Replace the icon to be replaced in the current interface with the target replacement icon.

[0081] After obtaining the target replacement icon, the present application can replace the icon to be replaced in the current interface with the target replacement icon. For example, see Figure 4 and Figure 5 Schematic diagram of the interface before and after icon replacement is shown. Figure 4 and Figure 5 As shown, the present application can replace the target replacement icon in a human-style with the icon to be replaced "Car Insurance Calculator" in the current interface.

[0082] For another example, see Figure 6 and Figure 7 Schematic diagrams of interfaces before and after the replacement of two other icons provided in the embodiment of the present application are shown. Figure 6As shown, the original icon of the "Auto Insurance Calculator" is a calculator icon as shown in the solid line frame; after using this application to replace the icon, the calculator icon of the "Auto Insurance Calculator" can be replaced with a cartoon character icon (that is, the target replacement icon mentioned above), as shown in FIG. Figure 7 shown.

[0083] By implementing the present application, by acquiring an uploaded image, performing element contour recognition and element extraction on the uploaded image to obtain element icons corresponding to each of the m elements, performing target selection processing on the m element icons to obtain a target replacement icon, and replacing the icon to be replaced in the current interface with the target replacement icon. In this way, the application icon can be conveniently replaced according to the actual needs of the user, which is conducive to improving the friendly interactivity of the interface, and also solves the technical problems of unfriendly interface interaction and inconvenient icon replacement in the prior art.

[0084] See also Figure 8 , is a schematic diagram of the structure of an icon replacement device provided in an embodiment of the present application. Figure 8 The device 50 shown includes: an acquisition module 501, an extraction module 502, a processing module 503 and a replacement module 504, wherein:

[0085] The acquisition module 501 is used to acquire the uploaded image;

[0086] The extraction module 502 is used to perform element contour recognition and element extraction on the uploaded image, so as to obtain element icons corresponding to m elements respectively, where m is a positive integer;

[0087] The processing module 503 is used to perform target selection processing on the m element icons to obtain a target replacement icon;

[0088] The replacement module 504 is used to replace the icon to be replaced in the current interface with the target replacement icon.

[0089] Optionally, the extraction module 502 is specifically used for:

[0090] Dividing the uploaded image into at least one sub-region according to pixel color, wherein the pixel color of each sub-region is within the same preset range;

[0091] Contour splicing is performed on at least one adjacent sub-region to obtain element icons corresponding to each of the m elements.

[0092] Optionally, the extraction module 502 is specifically used for:

[0093] An image feature recognition algorithm is used to perform element extraction and image segmentation on the uploaded image to obtain element icons corresponding to each of the m elements.

[0094] Optionally, the processing module 503 is specifically configured to:

[0095] Displaying the m element icons on the terminal interface;

[0096] receiving a target instruction generated from the terminal interface, the target instruction being used to instruct determination or outline re-extraction of an element in a target element icon, the target element icon being at least one of the m element icons;

[0097] In response to the target instruction, the target element icon determined or re-extracted as indicated by the target instruction is processed as the target replacement icon.

[0098] Optionally, the processing module 503 is specifically configured to:

[0099] Selecting n high-quality icons that meet a first preset condition from the m element icons, wherein the first preset condition includes at least one of the following: an icon resolution not less than a first threshold, an icon size not less than a second threshold, and an icon file size not less than a third threshold, where n is a positive integer not exceeding m;

[0100] Displaying the n high-quality icons on the terminal interface;

[0101] receiving a target instruction generated from the terminal interface, the target instruction being used to instruct determination or outline re-extraction of an element in a target element icon, the target element icon being at least one of the n high-quality icons;

[0102] In response to the target instruction, the target element icon determined or re-extracted as indicated by the target instruction is processed as the target replacement icon.

[0103] Optionally, if there is one target element icon, the processing module 503 is further specifically configured to:

[0104] Determine the target element icon determined or re-extracted as indicated by the target instruction as the target replacement icon;

[0105] Wherein, the target replacement icon is a static icon.

[0106] Optionally, the processing module 503 is further specifically configured to:

[0107] Determine the target element icon determined or re-extracted as indicated by the target instruction as a candidate replacement icon;

[0108] The candidate replacement icon is rendered, shaded or filtered to obtain the target replacement icon.

[0109] Optionally, if there are at least two target element icons, the processing module 503 is specifically configured to:

[0110] Dynamically merge at least two target element icons determined or re-extracted as indicated by the target instruction to obtain the target replacement icon;

[0111] Wherein, the target replacement icon is a dynamic icon.

[0112] Optionally, the device 50 further includes a determination module 505, wherein the determination module 505 is configured to:

[0113] Determining whether the uploaded image meets a second preset condition, wherein the second preset condition is that the uploaded image includes at least one element icon, and the elements included in the element icon are independent and do not overlap each other;

[0114] If yes, continue to execute the steps of the extraction module 502.

[0115] Optionally, the element icon is a static icon or a dynamic icon.

[0116] Please also see Fig. 9 , is a schematic diagram of the structure of another terminal device provided in an embodiment of the present application. Fig. 9 The terminal device 60 shown includes: at least one processor 601, a communication interface 602, a user interface 603 and a memory 604. The processor 601, the communication interface 602, the user interface 603 and the memory 604 can be connected via a bus or other means. The embodiment of the present invention takes the connection via a bus 605 as an example.

[0117] The processor 601 may be a general-purpose processor, such as a central processing unit (CPU).

[0118] The communication interface 602 may be a wired interface (eg, an Ethernet interface) or a wireless interface (eg, a cellular network interface or a wireless local area network interface) for communicating with other terminals or websites. In the embodiment of the present invention, the communication interface 602 is specifically used to obtain uploaded images.

[0119] The user interface 603 may be a touch panel, including a touch screen and a touch screen, for detecting operation instructions on the touch panel, or a physical button or a mouse. The user interface 603 may also be a display screen for outputting and displaying images or data.

[0120] The memory 604 may include a volatile memory, such as a random access memory (RAM); the memory may also include a non-volatile memory, such as a read-only memory (ROM), a flash memory, a hard disk drive (HDD) or a solid-state drive (SSD); the memory 604 may also include a combination of the above-mentioned types of memory. The memory 604 is used to store a set of program codes, and the processor 601 is used to call the program codes stored in the memory 604 to perform the following operations:

[0121] Get the uploaded image;

[0122] Performing element contour recognition and element extraction on the uploaded image, thereby obtaining element icons corresponding to m elements respectively, where m is a positive integer;

[0123] Performing target selection processing on the m element icons to obtain a target replacement icon;

[0124] Replace the icon to be replaced in the current interface with the target replacement icon.

[0125] Optionally, performing element contour recognition and element extraction on the uploaded image to obtain element icons corresponding to the m elements respectively includes:

[0126] Dividing the uploaded image into at least one sub-region according to pixel color, wherein the pixel color of each sub-region is within the same preset range;

[0127] Contour splicing is performed on at least one adjacent sub-region to obtain element icons corresponding to each of the m elements.

[0128] Optionally, performing element contour recognition and element extraction on the uploaded image to obtain element icons corresponding to the m elements respectively includes:

[0129] An image feature recognition algorithm is used to perform element extraction and image segmentation on the uploaded image to obtain element icons corresponding to each of the m elements.

[0130] Optionally, performing target selection processing on the m element icons to obtain a target replacement icon includes:

[0131] Displaying the m element icons on the terminal interface;

[0132] receiving a target instruction generated from the terminal interface, the target instruction being used to instruct determination or outline re-extraction of an element in a target element icon, the target element icon being at least one of the m element icons;

[0133] In response to the target instruction, the target element icon determined or re-extracted as indicated by the target instruction is processed as the target replacement icon.

[0134] Optionally, performing target selection processing on the m element icons to obtain a target replacement icon includes:

[0135] Selecting n high-quality icons that meet a first preset condition from the m element icons, wherein the first preset condition includes at least one of the following: an icon resolution not less than a first threshold, an icon size not less than a second threshold, and an icon file size not less than a third threshold, where n is a positive integer not exceeding m;

[0136] Displaying the n high-quality icons on the terminal interface;

[0137] receiving a target instruction generated from the terminal interface, the target instruction being used to instruct determination or outline re-extraction of an element in a target element icon, the target element icon being at least one of the n high-quality icons;

[0138] In response to the target instruction, the target element icon determined or re-extracted as indicated by the target instruction is processed as the target replacement icon.

[0139] Optionally, if there is one target element icon, processing the target element icon determined or re-extracted as indicated by the target instruction as the target replacement icon includes:

[0140] Determine the target element icon determined or re-extracted as indicated by the target instruction as the target replacement icon;

[0141] Wherein, the target replacement icon is a static icon.

[0142] Optionally, determining the target element icon determined or re-extracted as indicated by the target instruction as the target replacement icon includes:

[0143] Determine the target element icon determined or re-extracted as indicated by the target instruction as a candidate replacement icon;

[0144] The candidate replacement icon is rendered, shaded or filtered to obtain the target replacement icon.

[0145] Optionally, if there are at least two target element icons, processing the target element icon determined or re-extracted as indicated by the target instruction as the target replacement icon includes:

[0146] Dynamically merge at least two target element icons determined or re-extracted as indicated by the target instruction to obtain the target replacement icon;

[0147] Wherein, the target replacement icon is a dynamic icon.

[0148] Optionally, before performing element contour recognition and element extraction on the uploaded image, the processor 601 is further configured to:

[0149] Determining whether the uploaded image meets a second preset condition, wherein the second preset condition is that the uploaded image includes at least one element icon, and the elements included in the element icon are independent and do not overlap each other;

[0150] If yes, continue to execute the steps of performing contour recognition and element extraction on the uploaded image.

[0151] Optionally, the element icon is a static icon or a dynamic icon.

[0152] Since the terminal device introduced in this embodiment is a terminal device used to implement the icon replacement method in the embodiment of the present application, based on the icon replacement method introduced in the embodiment of the present application, a person skilled in the art can understand the specific implementation of the terminal device in this embodiment and its various variations, so how the terminal device implements the method in the embodiment of the present application is not described in detail here. As long as a person skilled in the art implements the terminal device used in the icon replacement method in the embodiment of the present application, it belongs to the scope of protection of this application.

[0153] The technical solution in the above-mentioned embodiment of the present application has at least the following technical effects or advantages: the present application obtains an uploaded image, performs element contour recognition and element extraction on the uploaded image to obtain element icons corresponding to each of the m elements, performs target selection processing on the m element icons to obtain a target replacement icon, and replaces the icon to be replaced in the current interface with the target replacement icon. In this way, the application icon can be conveniently replaced according to the actual needs of the user, which is conducive to improving the friendly interactivity of the interface, and also solves the technical problems of unfriendly interface interaction and inconvenient icon replacement in the prior art.

[0154] Those skilled in the art will appreciate that embodiments of the present invention may be provided as methods, systems, or computer program products. Therefore, the present invention may take the form of a complete hardware embodiment, a complete software embodiment, or an embodiment combining software and hardware. Moreover, the present invention may take the form of a computer program product implemented on one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.

[0155] The present invention is described with reference to flowcharts and / or block diagrams of methods, devices (systems), and computer program products according to embodiments of the present invention. It should be understood that each process and / or block in the flowchart and / or block diagram, as well as the combination of processes and / or blocks in the flowchart and / or block diagram, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, an embedded processor, or other programmable data processing device to produce a machine, so that the instructions executed by the processor of the computer or other programmable data processing device generate instructions for implementing the processes in the flowchart and / or block diagram. Figure 1 A process or multiple processes and / or boxes Figure 1 A device that provides the functions specified in a block or multiple blocks.

[0156] These computer program instructions may also be stored in a computer-readable memory capable of directing a computer or other programmable data processing device to operate in a specific manner, so that the instructions stored in the computer-readable memory produce an article of manufacture comprising an instruction device, which implements the process Figure 1 A process or multiple processes and / or boxes Figure 1 A function specified in one or more boxes.

[0157] These computer program instructions can also be loaded onto a computer or other programmable data processing device so that a series of operating steps are executed on the computer or other programmable device to produce a computer-implemented process, thereby providing instructions for implementing the process. Figure 1 A process or multiple processes and / or boxes Figure 1 A step that specifies a function in one or more boxes.

[0158] Although the preferred embodiments of the present invention have been described, those skilled in the art may make other changes and modifications to these embodiments once they have learned the basic creative concept. Therefore, the appended claims are intended to be interpreted as including the preferred embodiments and all changes and modifications that fall within the scope of the present invention.

[0159] Obviously, those skilled in the art can make various changes and modifications to the present invention without departing from the spirit and scope of the present invention. Thus, if these modifications and variations of the present invention fall within the scope of the claims of the present invention and their equivalents, the present invention is also intended to include these modifications and variations.

Claims

1. An icon replacement method, characterized in that: The method comprises: Get the uploaded image; Performing element contour recognition and element extraction on the uploaded image, so as to obtain element icons corresponding to each of the m elements, including: dividing the uploaded image into at least one sub-region according to pixel color, wherein the pixel color of each sub-region is within the same preset range; performing contour splicing on at least one adjacent sub-region, so as to obtain an overall contour map corresponding to each of the m elements, so as to obtain element icons corresponding to each of the m elements; if there are unconnected sub-regions, discarding the independent unconnected sub-regions; wherein m is a positive integer; Performing target selection processing on the m element icons to obtain a target replacement icon; Replace the icon to be replaced in the current interface with the target replacement icon.

2. The method according to claim 1, characterized in that The performing element contour recognition and element extraction on the uploaded image to obtain element icons corresponding to the m elements respectively includes: An image feature recognition algorithm is used to perform element extraction and image segmentation on the uploaded image to obtain element icons corresponding to each of the m elements.

3. The method according to claim 1, characterized in that The performing target selection processing on the m element icons to obtain a target replacement icon comprises: Displaying the m element icons on the terminal interface; receiving a target instruction generated from the terminal interface, the target instruction being used to instruct determination or outline re-extraction of an element in a target element icon, the target element icon being at least one of the m element icons; In response to the target instruction, the target element icon determined or re-extracted as indicated by the target instruction is processed as the target replacement icon.

4. The method according to claim 1, characterized in that: The performing target selection processing on the m element icons to obtain a target replacement icon comprises: Selecting n high-quality icons that meet a first preset condition from the m element icons, wherein the first preset condition includes at least one of the following: an icon resolution not less than a first threshold, an icon size not less than a second threshold, and an icon file size not less than a third threshold, where n is a positive integer not exceeding m; Displaying the n high-quality icons on the terminal interface; receiving a target instruction generated from the terminal interface, the target instruction being used to instruct determination or outline re-extraction of an element in a target element icon, the target element icon being at least one of the n high-quality icons; In response to the target instruction, the target element icon determined or re-extracted as indicated by the target instruction is processed as the target replacement icon.

5. The method according to claim 3 or 4, characterized in that: If there is one target element icon, processing the target element icon determined or re-extracted as indicated by the target instruction as the target replacement icon includes: Determine the target element icon determined or re-extracted as indicated by the target instruction as the target replacement icon; Wherein, the target replacement icon is a static icon.

6. The method according to claim 5, characterized in that The step of determining the target element icon indicated by the target instruction after determination or re-extraction as the target replacement icon comprises: Determine the target element icon determined or re-extracted as indicated by the target instruction as a candidate replacement icon; The candidate replacement icon is rendered, shaded or filtered to obtain the target replacement icon.

7. The method according to claim 3 or 4, characterized in that: If there are at least two target element icons, processing the target element icon determined or re-extracted as indicated by the target instruction as the target replacement icon includes: Dynamically merge at least two target element icons determined or re-extracted as indicated by the target instruction to obtain the target replacement icon; Wherein, the target replacement icon is a dynamic icon.

8. The method according to claim 1, characterized in that Before performing element contour recognition and element extraction on the uploaded image, the method further includes: Determining whether the uploaded image meets a second preset condition, wherein the second preset condition is that the uploaded image includes at least one element icon, and the elements included in the element icon are independent and do not overlap each other; If yes, continue to execute the steps of performing contour recognition and element extraction on the uploaded image.

9. The method according to claim 1, characterized in that: The element icon is a static icon or a dynamic icon.

10. An icon replacement device, characterized in that: It includes an acquisition module, an extraction module, a processing module and a replacement module, wherein: The acquisition module is used to acquire the uploaded image; The extraction module is used to perform element contour recognition and element extraction on the uploaded image, so as to obtain element icons corresponding to m elements respectively, where m is a positive integer; the extraction module is specifically used to: divide the uploaded image into at least one sub-region according to pixel color, wherein the pixel color of each sub-region is within the same preset range; perform contour splicing on at least one adjacent sub-region, so as to obtain an overall contour map corresponding to the m elements respectively, so as to obtain element icons corresponding to the m elements respectively; if there are unconnected sub-regions, the independent unconnected sub-regions are discarded; The processing module is used to perform target selection processing on the m element icons to obtain a target replacement icon; The replacement module is used to replace the icon to be replaced in the current interface with the target replacement icon.

11. A terminal device, characterized in that: include: Processors, memories, communication interfaces and buses; The processor, the memory and the communication interface are connected via the bus and communicate with each other; The memory stores executable program code; The processor runs a program corresponding to the executable program code by reading the executable program code stored in the memory, so as to execute the icon replacement method as described in any one of claims 1 to 9.

12. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores a program, and when the program is run on an electronic device, the icon replacement method as described in any one of claims 1 to 9 is executed.