CN104915971A - Method and terminal for obtaining color values - Google Patents

Method and terminal for obtaining color values Download PDF

Info

Publication number
CN104915971A
CN104915971A CN201510289792.3A CN201510289792A CN104915971A CN 104915971 A CN104915971 A CN 104915971A CN 201510289792 A CN201510289792 A CN 201510289792A CN 104915971 A CN104915971 A CN 104915971A
Authority
CN
China
Prior art keywords
color
color value
value
unit
pixel number
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN201510289792.3A
Other languages
Chinese (zh)
Inventor
莫天虎
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Shenzhen Jinli Communication Equipment Co Ltd
Original Assignee
Shenzhen Jinli Communication Equipment Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Shenzhen Jinli Communication Equipment Co Ltd filed Critical Shenzhen Jinli Communication Equipment Co Ltd
Priority to CN201510289792.3A priority Critical patent/CN104915971A/en
Publication of CN104915971A publication Critical patent/CN104915971A/en
Pending legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T11/002D [Two Dimensional] image generation
    • G06T11/40Filling a planar surface by adding surface attributes, e.g. colour or texture
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T7/00Image analysis
    • G06T7/90Determination of colour characteristics
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T2207/00Indexing scheme for image analysis or image enhancement
    • G06T2207/10Image acquisition modality
    • G06T2207/10004Still image; Photographic image
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T2207/00Indexing scheme for image analysis or image enhancement
    • G06T2207/10Image acquisition modality
    • G06T2207/10024Color image

Landscapes

  • Engineering & Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Theoretical Computer Science (AREA)
  • Computer Vision & Pattern Recognition (AREA)
  • Image Processing (AREA)

Abstract

The invention discloses a method and a terminal for obtaining color values. The method comprises steps of determining a color collection area that a user selects from a target image, obtaining the total pixel points in the color collection area and the pixel point quantity corresponding to each color value, determining whether a proportional value of the pixel point quantity corresponding to the color value and the total pixel points is greater than a preset threshold value, if yes, storing the color value as an effective color value. The embodiment of the invention can conveniently obtain the needed color value.

Description

A kind of color value acquisition methods and terminal
Technical field
The present invention relates to electronic technology field, be specifically related to a kind of color value acquisition methods and terminal.
Background technology
At present, along with the development of electronic technology, drawing mapping major part can complete in the terminals such as mobile phone, panel computer and notebook, such as, drawn a design by the touch-screen of terminal or the external plotting sheet etc. of terminal, and select corresponding Color pair pattern to fill from color selection plate.Find in practice, the color configured in color selection plate is limited, even if user is by the color needed for the acquisition of adjustable colors value, operates also more loaded down with trivial details.
Summary of the invention
The embodiment of the invention discloses a kind of color value acquisition methods and terminal, required color value can be obtained easily.
The embodiment of the invention discloses a kind of color value acquisition methods, comprising:
Determine the color acquisition region that user chooses from Target Photo;
Obtain total pixel number in described color acquisition region and pixel number corresponding to each color value;
For the pixel number that each color value is corresponding, judge whether the ratio value of the pixel number that described color value is corresponding and described total pixel number is greater than predetermined threshold value, if be greater than, is then stored as effective color value by described color value.
Correspondingly, the embodiment of the invention discloses a kind of terminal, comprising:
First determining unit, for determining the color acquisition region that user chooses from Target Photo;
First acquiring unit, for obtaining total pixel number in described color acquisition region and pixel number corresponding to each color value;
Judging unit, for for pixel number corresponding to each color value, judges whether the ratio value of the pixel number that described color value is corresponding and described total pixel number is greater than predetermined threshold value;
Storage unit, during for judging that at described judging unit the ratio value of the pixel number that described color value is corresponding and described total pixel number is greater than predetermined threshold value, stores described color value as effective color value.
The embodiment of the present invention determines the color acquisition region that user chooses from Target Photo, obtain total pixel number in this color acquisition region and pixel number corresponding to each color value, and for pixel number corresponding to each color value, judge whether the ratio value of the pixel number that color value is corresponding and total pixel number is greater than predetermined threshold value, if be greater than, then color value is stored as effective color value.Visible, the embodiment of the present invention, without the need to adjusting the color value of terminal setting to obtain required color, obtains the color value of required color easily by Target Photo and stores, and avoids the loaded down with trivial details of color value adjustment.
Accompanying drawing explanation
In order to be illustrated more clearly in the technical scheme in the embodiment of the present invention, be briefly described to the accompanying drawing used required in embodiment below, apparently, accompanying drawing in the following describes is only some embodiments of the present invention, for those of ordinary skill in the art, under the prerequisite not paying creative work, other accompanying drawing can also be obtained according to these accompanying drawings.
Fig. 1 is the schematic flow sheet of a kind of color value acquisition methods disclosed in the embodiment of the present invention;
Fig. 2 is the schematic flow sheet of another kind of color value acquisition methods disclosed in the embodiment of the present invention;
Fig. 3 is the structural representation of a kind of terminal disclosed in the embodiment of the present invention;
Fig. 4 is the structural representation of another kind of terminal disclosed in the embodiment of the present invention;
Fig. 5 is the structural representation of the embodiment of the present invention another terminal disclosed.
Embodiment
Below in conjunction with the accompanying drawing in the embodiment of the present invention, be clearly and completely described the technical scheme in the embodiment of the present invention, obviously, described embodiment is the present invention's part embodiment, instead of whole embodiments.Based on the embodiment in the present invention, those of ordinary skill in the art, not making the every other embodiment obtained under creative work prerequisite, belong to the scope of protection of the invention.
The embodiment of the invention discloses a kind of color value acquisition methods and terminal, the color value of required color can be obtained easily.Below be described in detail respectively.
Refer to Fig. 1, Fig. 1 is the schematic flow sheet of a kind of color value acquisition methods disclosed in the embodiment of the present invention.As shown in Figure 1, this color value acquisition methods can comprise the following steps.
S101, terminal determine the color acquisition region that user chooses from Target Photo;
In the embodiment of the present invention, terminal can comprise the equipment such as smart mobile phone, panel computer, notebook and plotting sheet.In the embodiment of the present invention, the color acquisition region that user can be chosen from Target Photo by the touching display screen arranged in terminal, for example, user comprises the color acquisition region of required color on touching display screen with finger delimitation Target Photo, this color acquisition region can show with broken line representation.
As the optional embodiment of one, terminal, before execution above-mentioned steps S101, first can perform following steps:
11), terminal is opened camera, and from surrounding environment, is taken the Target Photo with required color by camera.
In the embodiment of the present invention, after terminal opens camera, exportable Indication message, takes the Target Photo with required color from surrounding environment by camera with indicating user, after terminal photographs Target Photo by camera, can perform step S101.
As the optional embodiment of another kind, terminal, before execution above-mentioned steps S101, first can perform following steps:
21) mass-tone that, terminal has according to picture is sorted out the picture prestored;
22), terminal is with the picture of sorted out mass-tone for prestoring described in benchmark list view;
23), terminal obtains the Target Photo that user selects from the picture of display.
In the embodiment of the present invention, the mass-tone that picture has can occupy the maximum color of pixel number in this picture, can sort out according to respective had mass-tone for the picture prestored in terminal, and show with the mass-tone sorted out the picture prestored, thus make user's select target picture from all kinds of pictures of display.For example, terminal is by step 21) and 22) show with red and blue be two class picture groups of mass-tone, if the color of user's needs is light red, then can from redness be mass-tone picture group select target picture.
S102, terminal obtain total pixel number in this color acquisition region and pixel number corresponding to each color value;
The pixel number that S103, terminal pins are corresponding to each color value, judges that whether the ratio value of the pixel number that color value is corresponding and total pixel number is greater than predetermined threshold value, if be greater than, then stores this color value as effective color value.
In the embodiment of the present invention, the color acquisition region that terminal is obtained by step S101 may comprise other colors, effectively can be extracted the mass-tone in color acquisition region by step S102 and S103, the pixel number that namely this mass-tone is corresponding and the ratio value of total pixel number are greater than predetermined threshold value.
As the optional embodiment of one, the pixel number that in step S103, color value is corresponding and the ratio value of total pixel number are greater than predetermined threshold value, this color value is stored as effective color value, for to be stored as effective color value by color value maximum for the ratio value of pixel number and total pixel number in this picture, thus the follow-up choice for use of user can be supplied.
As the optional embodiment of another kind, terminal is performing pixel number corresponding for each color value in step S103, after judging whether the ratio value of the pixel number that color value is corresponding and total pixel number is greater than predetermined threshold value, can also following steps be performed:
31) terminal exports and displaying ratio value is greater than color corresponding to the color value of predetermined threshold value;
32) terminal obtains user from exporting and the color of object selected the color shown;
Correspondingly, terminal performs in step S103 and is stored as effective color value by color value, can specifically comprise:
33) terminal using color value corresponding for color of object as effective color value;
34) the effective color value of terminal storage.
Visible, when the color acquisition region color comprised needed for multiple color or user is the color that ratio value is relatively little, then can by the rational predetermined threshold value of setting, step 31 by foregoing invention embodiment) to 34) color value of being answered by the Color pair that this ratio value is relatively little stores as effective color value, follow-up for user.
In the embodiment of the present invention, terminal performs step 34) the effective color value of middle storage, can specifically comprise the following steps:
41) terminal receives the mark named effective color value of user's input;
42) terminal by effective color value and this mark corresponding stored in presetting database.
Wherein, this mark can be named, as light red with the color of this effective color value, light blue, navy etc., the region that also often can be used to tint with effective color value is named, as light red is often used to be coated with carnation petal, then and can called after carnation petal.By by effective color value and this mark corresponding stored in presetting database, when can make follow-up use, directly extract from presetting database.
In the method described by Fig. 1, terminal determines the color acquisition region that user chooses from Target Photo, obtain total pixel number in this color acquisition region and pixel number corresponding to each color value, and for pixel number corresponding to each color value, judge whether the ratio value of the pixel number that color value is corresponding and described total pixel number is greater than predetermined threshold value, if be greater than, then color value is stored as effective color value.Visible, the method described by Fig. 1, without the need to adjusting the color value of terminal setting to obtain required color, obtains effective color value of required color easily by Target Photo and stores, thus avoids the loaded down with trivial details of color value adjustment.
Refer to Fig. 2, Fig. 2 is the schematic flow sheet of another kind of color value acquisition methods disclosed in the embodiment of the present invention.As shown in Figure 2, this color value acquisition methods can comprise the following steps.
S201, terminal determine the region that colors in of picture to be colored in, and open suction look pattern;
In the embodiment of the present invention, picture to be colored in can comprise any one in drawing, font, background and wallpaper picture, can by the color in region of color filling corresponding for target color values to the region that colors in drawing, font by step S202 to S206; The color of the background of terminal and wallpaper can also be set to color corresponding to target color values.Wherein, inhale look pattern and refer to the operation obtaining the region required color that colors in.
S202, terminal determine the color acquisition region that user chooses from Target Photo;
S203, terminal obtain total pixel number in color acquisition region and pixel number corresponding to each color value;
The pixel number that S204, terminal pins are corresponding to each color value, judges that whether the ratio value of the pixel number that color value is corresponding and total pixel number is greater than predetermined threshold value, if be greater than, then stores color value as effective color value;
In the embodiment of the present invention, the concrete elaboration of step S202 to S204 with reference to the related content of step S101 to S103 in foregoing invention embodiment, no longer can be described in detail here.
S205, terminal be select target color value from effective color value;
In the embodiment of the present invention, terminal can from the effective color value stored select target color value, the effective color value also step S204 can determined directly as target color values, to perform step S206.
The region that colors in picture to be colored in is set to target color values by S206, terminal.
As the optional embodiment of one, terminal, before execution step S206, can also perform following steps:
51) terminal exports the adjustment bar of the brightness for regulating target color values;
52) terminal obtains the brightness value that user inputs for this adjustment bar;
53) terminal is according to the brightness of this brightness value adjustment aim color value.
Correspondingly, the region that colors in picture to be colored in is set to target color values by terminal, can be specially and will be set to the target color values after adjusting wait the region that colors in the picture that colors in.
Visible, this embodiment can according to the concrete scheme of colour of picture to be colored in, the brightness of the effective color value selected by adjustment, thus more meets the required color of user for picture to be colored in.
As the optional embodiment of another kind, terminal, before execution step S206, can also perform following steps:
61) option value of the transparency of this target color values of terminal Drazin inverse;
62) terminal obtains the transparence value that user selects from described option value;
63) terminal adjusts the transparency of described target color values according to transparence value;
Correspondingly, the region that colors in picture to be colored in is set to target color values by terminal, can be specially and will be set to the target color values after adjusting wait the region that colors in the picture that colors in.
Same, this embodiment also can according to the concrete scheme of colour of picture to be colored in, the brightness of the effective color value selected by adjustment, thus more meets the required color of user for picture to be colored in.As another optional embodiment, terminal can perform step 51 according to the concrete scheme of colour of picture to be colored in) to 53), and step 61) to 62), thus further improve the effect after the picture Fill Color that colors in.
In the method described by Fig. 2, first terminal determines the region that colors in of picture to be colored in, automatically can open and inhale look pattern, terminal and then determine the color acquisition region that user chooses from Target Photo, obtains total pixel number in this color acquisition region and pixel number corresponding to each color value; And for pixel number corresponding to each color value, judge whether the ratio value of the pixel number that color value is corresponding and total pixel number is greater than predetermined threshold value, if be greater than, then color value is stored as effective color value, the region that colors in picture to be colored in as target color values, and is set to target color values by this effective color value of selecting by terminal.Visible, the method described by Fig. 2 under suction look pattern, can perform correlation step so that the region that colors in picture to be colored in is set to target color values, thus effectively can improve color in efficiency and the effect that colors in of picture to be colored in.
Refer to Fig. 3, Fig. 3 is the structural representation of a kind of terminal disclosed in the embodiment of the present invention.Wherein, the terminal shown in Fig. 3 can comprise with lower unit:
First determining unit 301, for determining the color acquisition region that user chooses from Target Photo;
First acquiring unit 302, for obtaining total pixel number in color acquisition region and pixel number corresponding to each color value;
Judging unit 303, for total pixel number of obtaining according to the first acquiring unit 302 and pixel number corresponding to each color value, for the pixel number that each color value is corresponding, judge whether the ratio value of the pixel number that color value is corresponding and total pixel number is greater than predetermined threshold value;
Storage unit 304, during for judging that the ratio value of the pixel number that color value is corresponding and total pixel number is greater than predetermined threshold value at judging unit 303, stores color value as effective color value.
In the embodiment of the present invention, said units can be arranged in the equipment such as smart mobile phone, panel computer, notebook and plotting sheet.
In the embodiment of the present invention, the color acquisition region that the first determining unit 301 is determined can be user comprises required color color acquisition region by the Target Photo that touching display screen finger touch delimited, and this color acquisition region can show with broken line representation.
See also Fig. 4, Fig. 4 is the structural representation of another kind of terminal disclosed in the embodiment of the present invention.Wherein, the terminal shown in Fig. 4 is that terminal is as shown in Figure 3 optimized and obtains.Compared with the terminal shown in Fig. 3, the terminal shown in Fig. 4 can also comprise:
Output unit 305, for the color value that in storage unit ratio value is greater than described predetermined threshold value as before effective color value stores, to export and displaying ratio value is greater than color corresponding to the color value of predetermined threshold value.
In the embodiment of the present invention, judging unit 303 is for number of pixels corresponding to each color value, judge whether the ratio value of the pixel number that color value is corresponding and total pixel number is greater than predetermined threshold value, and trigger output unit 305 and to export and displaying ratio value is greater than color corresponding to the color value of predetermined threshold value.
Second acquisition unit 306, exports and the color of object selected the color shown from output unit 305 for obtaining user;
Accordingly, storage unit 304 as effective color value, and stores this effective color value specifically for color value corresponding to the color of object that obtained by second acquisition unit 306.
In the embodiment of the present invention, when the color acquisition region color comprised needed for multiple color or user is the relatively little color of ratio value, can by the rational predetermined threshold value of setting, to be exported by output unit 305 and displaying ratio value is greater than color corresponding to the color value of predetermined threshold value, and obtain by second acquisition unit 306 color of object that user therefrom selects, follow-up for user.
As the optional embodiment of one, the terminal shown in Fig. 4 can also comprise shooting unit 307,
Shooting unit 307, for opening camera, and being taken the Target Photo with required color, determining to trigger the first determining unit 301 the color acquisition region that user chooses from Target Photo from surrounding environment by camera.
In the embodiment of the present invention, after shooting unit 307 opens camera, exportable Indication message, from surrounding environment, taken the Target Photo with required color by camera with indicating user, after shooting unit 307 photographs Target Photo by camera, the first determining unit 301 can be triggered and perform corresponding operation.
As the optional embodiment of another kind, the terminal shown in Fig. 4 can also comprise with lower unit:
Sort out unit 308, for the mass-tone had according to picture, the picture prestored is sorted out;
Display unit 309, for sort out the picture of mass-tone for prestoring described in benchmark list view that unit 308 sorts out;
Acquiring unit 310, for obtaining the Target Photo that user selects from the picture that display unit 309 shows, determines to trigger the first determining unit 301 the color acquisition region that user chooses from Target Photo.
In the embodiment of the present invention, the mass-tone that picture has can occupy the maximum color of pixel number in this picture, sort out unit 308 to sort out according to respective had mass-tone for the picture prestored in terminal, and show with the mass-tone sorted out the picture prestored, thus make user's select target picture from all kinds of pictures that display unit 309 shows.For example, terminal by sort out unit 308 and display unit 309 show with red and blue be two class picture groups of mass-tone, if the color that user needs is light red, then can from redness be mass-tone picture group select target picture.
In the embodiment of the present invention, in the terminal shown in Fig. 4, storage unit 304 can specifically comprise following subelement:
Receive subelement 3041, the mark that the color value corresponding to the color of object of second acquisition unit 306 acquisition for receiving user's input is named;
Storing sub-units 3042, for using color value corresponding for color of object as effective color value with receive the mark corresponding stored that receives of subelement 3041 in presetting database.
Wherein, this mark can be named, as light red with the color of this effective color value, light blue, navy etc., the region that colors in that also often can be used to tint with effective color value is named, as light red is often used to be coated with carnation petal, then and can called after carnation petal.By by effective color value and this mark corresponding stored in presetting database, when can make follow-up use, directly extract from presetting database.
In the embodiment of the present invention, the terminal shown in Fig. 4 can also comprise:
Second determining unit 311, for determining the region that colors in of picture to be colored in, and opens suction look pattern;
Selection unit 312, for select target color value in effective color value of storing from storage unit 304;
Setting unit 313, the region that colors in for the picture to be colored in the second determining unit 311 determined is set to the target color values selected by selection unit 312.
In the embodiment of the present invention, inhale look pattern and refer to the operation obtaining the region required color that colors in.Picture to be colored in can comprise any one in drawing, font, background and wallpaper picture.Wherein, the second determining unit 311 after look pattern is inhaled in unlatching, can trigger the first determining unit 301, shooting unit 307 or sort out unit 308 performing corresponding operation; Storage unit 304 can perform corresponding operation by triggering selection unit 312 when storing effective color value.
Visible, the region that colors in picture to be colored under suction look pattern, can be set to target color values by said units, thus effectively can improve color in efficiency and the effect that colors in of picture to be colored in by above-mentioned embodiment.
In the embodiment of the present invention, the terminal shown in Fig. 4 can also comprise:
First output unit 314, for after select target color value, exporting the adjustment bar of the brightness for regulating target color values at selection unit 312 from effective color value that storage unit 304 stores;
First acquiring unit 315, for obtaining the adjustment bar and the brightness value inputted that user exports for the first output unit 314;
First adjustment unit 316, for the brightness of the brightness value adjustment aim color value according to the first acquiring unit 315 acquisition;
Correspondingly, setting unit 313 is set to the target color values after the first adjustment unit adjustment specifically for the region that colors in wait the picture that colors in the second determining unit determined.
Visible, this embodiment can according to the concrete scheme of colour of picture to be colored in, the brightness of the effective color value selected by adjustment, thus more meets the required color of user for picture to be colored in.
In the embodiment of the present invention, the terminal shown in Fig. 4 can also comprise:
Second output unit 317, at selection unit 312 from effective color value that storage unit 304 stores after select target color value, the option value of the transparency of Drazin inverse target color values;
Second acquisition unit 318, for obtaining the transparence value that user selects from the option value that the second output unit 317 exports;
Second adjustment unit 319, for the transparency of transparence value adjustment aim color value obtained according to second acquisition unit 318;
Correspondingly, setting unit 313 is set to the target color values after the second adjustment unit adjustment specifically for the region that colors in wait the picture that colors in the second determining unit determined.
Same, this embodiment also can according to the concrete scheme of colour of picture to be colored in, the brightness of the effective color value selected by adjustment, thus more meets the required color of user for picture to be colored in.As another optional embodiment, terminal according to the concrete scheme of colour of picture to be colored in by the brightness of said units adjustment aim color value or transparency, thus can further improve the effect after the picture Fill Color that colors in.
In the terminal described by Fig. 3 and Fig. 4, first determining unit determines the color acquisition region that user chooses from Target Photo, and obtain total pixel number in color acquisition region and pixel number corresponding to each color value by the first acquiring unit, total pixel number that judging unit obtains according to the first acquiring unit and pixel number corresponding to each color value, judge whether the ratio value of the pixel number that color value is corresponding and total pixel number is greater than predetermined threshold value, the color value that the ratio value of pixel number and total pixel number is greater than predetermined threshold value is stored as effective color value by storage unit.Visible, the terminal described by Fig. 3 and Fig. 4, without the need to adjusting the color value of terminal setting to obtain required color, can obtain required color easily.Further, terminal described by Fig. 4 is by shooting unit or sort out unit, display unit and acquiring unit determination Target Photo, and the region that colors in of picture to be colored in can be determined in the second determining unit, open after inhaling look pattern and perform corresponding operation, the region that colors in picture to be colored in is set to target color values, thus effectively can improves color in efficiency and the effect that colors in of picture to be colored in.
Refer to Fig. 5, the structural representation of Fig. 5 another kind of terminal disclosed in the embodiment of the present invention.As shown in Figure 5, this terminal can comprise: at least one processor 401, such as CPU, input media 402, storer 403, at least one communication bus 404, output unit 405.Wherein, communication bus 404 is for realizing the communication connection between these assemblies.Wherein, output unit 405 can comprise at least two display screens.Storer 403 can be high-speed RAM storer, also can be non-labile storer (non-volatile memory), such as at least one magnetic disk memory.Storer 403 can also be optionally that at least one is positioned at the memory storage away from aforementioned processor 401.Wherein, processor 401 can composition graphs 3 and the terminal described by Fig. 4, stores batch processing code in storer 403, and processor 401 calls the program code stored in storer 403, for performing following operation:
Determine the color acquisition region that user is chosen from Target Photo by input media 402;
Obtain total pixel number in color acquisition region and pixel number corresponding to each color value;
For the pixel number that each color value is corresponding, judge whether the ratio value of the pixel number that color value is corresponding and total pixel number is greater than predetermined threshold value, if be greater than, then color value is stored as effective color value.
In the embodiment of the present invention, the color acquisition region that user can be chosen from Target Photo by input media 402 (as touching display screen), for example, user comprises the color acquisition region of required color on touching display screen with finger touch delimitation Target Photo, this color acquisition region can show with broken line representation.
In the embodiment of the present invention, processor 401 calls the program code in storer 403, using color value as before effective color value stores, can also perform following operation:
To be exported by output unit 405 and displaying ratio value is greater than color corresponding to the color value of predetermined threshold value;
Obtain user from exporting and the color of object selected the color shown;
Correspondingly, color value stores as effective color value by processor, can be specially color value corresponding for color of object as effective color value; Store this effective color value.
This embodiment can when in color acquisition region, the color comprised needed for multiple color or user be ratio value relatively little color, by setting rational predetermined threshold value, the color value of being answered by the Color pair that ratio value is relatively little by aforesaid operations is stored as effective color value, follow-up for user.
As the optional embodiment of one, processor 401 calls the program code in storer 403, before determining the color acquisition region that user chooses from Target Photo, can also perform following operation:
Open camera, and from surrounding environment, taken the Target Photo with required color by this camera.
In this embodiment, after camera opened by processor 401, exportable Indication message, takes the Target Photo with required color from surrounding environment by camera with indicating user, after photographing Target Photo by camera, processor 401 performs corresponding operation again.
As the optional embodiment of another kind, processor 401 calls the program code in storer 403, before determining the color acquisition region that user chooses from Target Photo, can also perform following operation:
The mass-tone had according to picture is sorted out the picture prestored;
With sorted out mass-tone for benchmark shows the picture prestored by output unit 405;
Obtain the Target Photo that user selects from the picture of display.
Wherein, the mass-tone that picture has can occupy the maximum color of pixel number in this picture, can sort out according to respective had mass-tone for the picture prestored in terminal, and show with the mass-tone sorted out the picture prestored, thus make user's select target picture from all kinds of pictures of display.For example, terminal by output unit 405 show with red and blue be two class picture groups of mass-tone, if the color that user needs is light red, then can from redness be mass-tone picture group select target picture.
In the embodiment of the present invention, processor 401 calls the program code in storer 403, stores effective color value, can perform following operation:
Receive the mark that effective color value is named of user's input;
By effective color value and this mark corresponding stored in presetting database.
Wherein, this mark can be named, as light red with the color of this effective color value, light blue, navy etc., the region that also often can be used to tint with effective color value is named, as light red is often used to be coated with carnation petal, then and can called after carnation petal.By by effective color value and this mark corresponding stored in presetting database, when can make follow-up use, directly extract from presetting database.
In the embodiment of the present invention, processor 401 calls the program code in storer 403, can also perform following operation:
Determine the region that colors in of picture to be colored in, and open suction look pattern;
Correspondingly, color value as after effective color value stores, can also be performed following operation by processor 401:
Select target color value from effective color value;
The region that colors in picture to be colored in is set to target color values.
Wherein, picture to be colored in can comprise any one in drawing, font, background and wallpaper picture.
As the optional embodiment of one, processor 401 calls the program code in storer 403, from effective color value after select target color value, can also perform following operation:
Export the adjustment bar of the brightness for regulating target color values;
Obtain the brightness value that user inputs for this adjustment bar;
The brightness of this target color values is adjusted according to this brightness value.
Correspondingly, the region that colors in picture to be colored in is set to target color values by processor 401, can be specially and will be set to the target color values after adjusting wait the region that colors in the picture that colors in.
This embodiment can according to the concrete scheme of colour of picture to be colored in, the brightness of the effective color value selected by adjustment, thus more meets the required color of user for picture to be colored in.
As the optional embodiment of another kind, processor 401 calls the program code in storer 403, from effective color value after select target color value, can also perform following operation:
The option value of the transparency of Drazin inverse target color values;
Obtain the transparence value that user selects from this option value;
The transparency of this target color values is adjusted according to this transparence value;
Correspondingly, the region that colors in picture to be colored in is set to target color values by processor 401, can be specially and will be set to the target color values after adjusting wait the region that colors in the picture that colors in.
Same, this embodiment also can according to the concrete scheme of colour of picture to be colored in, the brightness of the effective color value selected by adjustment, thus more meets the required color of user for picture to be colored in.As another optional embodiment, terminal according to the brightness of the concrete scheme of colour adjustment aim color value of picture to be colored in and transparency, thus can further improve the effect after the picture Fill Color that colors in.
Concrete, the terminal introduced in the present embodiment can implement the part or all of flow process in the color value acquisition methods embodiment of composition graphs 1 of the present invention or Fig. 2 introduction.
Step in embodiment of the present invention method can be carried out order according to actual needs and be adjusted, merges and delete.
Unit in embodiment of the present invention terminal or equipment or subelement can carry out merging, divide and deleting according to actual needs.
One of ordinary skill in the art will appreciate that all or part of step in the various methods of above-described embodiment can carry out the device-dependent hardware of command terminal by program to have come, this program can be stored in a computer-readable recording medium, storage medium can comprise: flash disk, ROM (read-only memory) (Read-Only Memory, ROM), random access device (Random Access Memory, RAM), disk or CD etc.
Above to the embodiment of the invention discloses a kind of color value acquisition methods and terminal is described in detail, apply specific case herein to set forth principle of the present invention and embodiment, the explanation of above embodiment just understands method of the present invention and core concept thereof for helping; Meanwhile, for one of ordinary skill in the art, according to thought of the present invention, all will change in specific embodiments and applications, in sum, this description should not be construed as limitation of the present invention.

Claims (10)

1. a color value acquisition methods, is characterized in that, comprising:
Determine the color acquisition region that user chooses from Target Photo;
Obtain total pixel number in described color acquisition region and pixel number corresponding to each color value;
For the pixel number that each color value is corresponding, judge whether the ratio value of the pixel number that described color value is corresponding and described total pixel number is greater than predetermined threshold value, if be greater than, is then stored as effective color value by described color value.
2. method according to claim 1, is characterized in that, described using described color value as before effective color value stores, described method also comprises:
Export and show described ratio value and be greater than color corresponding to the color value of described predetermined threshold value;
Obtain user's color of object of selecting from described output and the color of display;
Described described color value to be stored as effective color value, comprising:
Using color value corresponding for described color of object as effective color value;
Store described effective color value.
3. method according to claim 2, is characterized in that, before the color acquisition region that the described user of determination chooses from Target Photo, described method also comprises:
Open camera, and from surrounding environment, taken the Target Photo with required color by described camera.
4. method according to claim 2, is characterized in that, before the color acquisition region that the described user of determination chooses from Target Photo, described method also comprises:
The mass-tone had according to picture is sorted out the picture prestored;
With the picture of sorted out mass-tone for prestoring described in benchmark list view;
Obtain the Target Photo that user selects from the picture of described display.
5. method according to claim 2, is characterized in that, the described effective color value of described storage, comprising:
Receive the mark to described effective color value name of user's input;
By described effective color value and described mark corresponding stored in presetting database.
6. a terminal, is characterized in that, comprising:
First determining unit, for determining the color acquisition region that user chooses from Target Photo;
First acquiring unit, for obtaining total pixel number in described color acquisition region and pixel number corresponding to each color value;
Judging unit, for for pixel number corresponding to each color value, judges whether the ratio value of the pixel number that described color value is corresponding and described total pixel number is greater than predetermined threshold value;
Storage unit, during for judging that at described judging unit the ratio value of the pixel number that described color value is corresponding and described total pixel number is greater than predetermined threshold value, stores described color value as effective color value.
7. terminal according to claim 6, is characterized in that, described terminal also comprises:
Output unit, for the color value that in storage unit described ratio value is greater than described predetermined threshold value as before effective color value stores, exports and shows described ratio value and be greater than color corresponding to the color value of described predetermined threshold value;
Second acquisition unit, exports and the color of object selected the color shown from described output unit for obtaining user;
Described storage unit as effective color value, and stores described effective color value specifically for color value corresponding to the color of object that obtained by described second acquisition unit.
8. terminal according to claim 7, is characterized in that, described terminal also comprises:
Shooting unit, for opening camera, and being taken the Target Photo with required color, determining to trigger described first determining unit the color acquisition region that user chooses from Target Photo from surrounding environment by described camera.
9. terminal according to claim 7, is characterized in that, described terminal also comprises:
Sort out unit, for the mass-tone had according to picture, the picture prestored is sorted out;
Display unit, for the picture of mass-tone for prestoring described in benchmark list view sorted out with described classification unit;
Acquiring unit, for obtaining the Target Photo that user selects from the picture that described display unit shows, determines to trigger described first determining unit the color acquisition region that user chooses from Target Photo.
10. terminal according to claim 7, is characterized in that, described storage unit comprises:
Receive subelement, the mark that the color value that the color of object obtained described second acquisition unit for receiving user's input is corresponding is named;
Storing sub-units, for the mark corresponding stored that received as effective color value and described reception subelement by color value corresponding for described color of object in presetting database.
CN201510289792.3A 2015-05-29 2015-05-29 Method and terminal for obtaining color values Pending CN104915971A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201510289792.3A CN104915971A (en) 2015-05-29 2015-05-29 Method and terminal for obtaining color values

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201510289792.3A CN104915971A (en) 2015-05-29 2015-05-29 Method and terminal for obtaining color values

Publications (1)

Publication Number Publication Date
CN104915971A true CN104915971A (en) 2015-09-16

Family

ID=54085008

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201510289792.3A Pending CN104915971A (en) 2015-05-29 2015-05-29 Method and terminal for obtaining color values

Country Status (1)

Country Link
CN (1) CN104915971A (en)

Cited By (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105630287A (en) * 2015-12-21 2016-06-01 天脉聚源(北京)教育科技有限公司 Color acquisition method and apparatus
CN106775374A (en) * 2016-11-17 2017-05-31 广州视源电子科技股份有限公司 Color obtaining method and device based on touch screen
CN107678784A (en) * 2017-09-18 2018-02-09 上海斐讯数据通信技术有限公司 A kind of method and system according to surrounding environment conversion equipment surface color and polish
CN108124140A (en) * 2017-12-05 2018-06-05 广东小天才科技有限公司 Color pickup method and device, electronic brush and storage medium
CN108170363A (en) * 2017-12-29 2018-06-15 努比亚技术有限公司 picture editing method, intelligent terminal and computer readable storage medium
CN111243037A (en) * 2020-01-06 2020-06-05 北京小米移动软件有限公司 Data processing method and device and computer storage medium

Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103176761A (en) * 2011-12-23 2013-06-26 中国移动通信集团公司 Screen background setting method and movable terminal
CN103207778A (en) * 2012-01-13 2013-07-17 青岛海信移动通信技术股份有限公司 Method, device and mobile terminal for modifying icons
CN103903593A (en) * 2012-12-27 2014-07-02 腾讯科技(武汉)有限公司 Adjustment method of display background of page, and terminal
CN104077567A (en) * 2014-06-20 2014-10-01 深圳市金立通信设备有限公司 Color discrimination method and terminal
CN104076928A (en) * 2014-07-15 2014-10-01 深圳市金立通信设备有限公司 Method for adjusting color tone of text display area
CN104360796A (en) * 2014-12-08 2015-02-18 三星电子(中国)研发中心 Method and device for applying colors onto electronic equipment and electronic equipment
CN104391691A (en) * 2014-11-07 2015-03-04 久邦计算机技术(广州)有限公司 Icon and text processing method

Patent Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103176761A (en) * 2011-12-23 2013-06-26 中国移动通信集团公司 Screen background setting method and movable terminal
CN103207778A (en) * 2012-01-13 2013-07-17 青岛海信移动通信技术股份有限公司 Method, device and mobile terminal for modifying icons
CN103903593A (en) * 2012-12-27 2014-07-02 腾讯科技(武汉)有限公司 Adjustment method of display background of page, and terminal
CN104077567A (en) * 2014-06-20 2014-10-01 深圳市金立通信设备有限公司 Color discrimination method and terminal
CN104076928A (en) * 2014-07-15 2014-10-01 深圳市金立通信设备有限公司 Method for adjusting color tone of text display area
CN104391691A (en) * 2014-11-07 2015-03-04 久邦计算机技术(广州)有限公司 Icon and text processing method
CN104360796A (en) * 2014-12-08 2015-02-18 三星电子(中国)研发中心 Method and device for applying colors onto electronic equipment and electronic equipment

Cited By (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105630287A (en) * 2015-12-21 2016-06-01 天脉聚源(北京)教育科技有限公司 Color acquisition method and apparatus
CN105630287B (en) * 2015-12-21 2018-10-26 天脉聚源(北京)教育科技有限公司 A kind of color acquisition methods and device
CN106775374A (en) * 2016-11-17 2017-05-31 广州视源电子科技股份有限公司 Color obtaining method and device based on touch screen
CN107678784A (en) * 2017-09-18 2018-02-09 上海斐讯数据通信技术有限公司 A kind of method and system according to surrounding environment conversion equipment surface color and polish
CN108124140A (en) * 2017-12-05 2018-06-05 广东小天才科技有限公司 Color pickup method and device, electronic brush and storage medium
CN108170363A (en) * 2017-12-29 2018-06-15 努比亚技术有限公司 picture editing method, intelligent terminal and computer readable storage medium
CN111243037A (en) * 2020-01-06 2020-06-05 北京小米移动软件有限公司 Data processing method and device and computer storage medium

Similar Documents

Publication Publication Date Title
CN104915971A (en) Method and terminal for obtaining color values
CN107613202B (en) Shooting method and mobile terminal
CN105957125B (en) A kind of processing method and mobile terminal of icon text
CN105005461A (en) Icon display method and terminal
CN106873863B (en) Method and device for setting interface switching animation
JP7166171B2 (en) INTERFACE IMAGE DISPLAY METHOD, APPARATUS AND PROGRAM
CN106060417B (en) A kind of flash lamp control method and terminal
KR102662873B1 (en) Picture processing methods and apparatus, devices and storage media
US10067646B2 (en) Color selector for desktop publishing
CN110780873A (en) Interface color adaptation method and device, computer equipment and storage medium
US20080317376A1 (en) Automatic image correction providing multiple user-selectable options
CN104239076A (en) Interface color adjusting method and device
CN104486552A (en) Method and electronic device for obtaining images
US11962917B2 (en) Color adjustment method, color adjustment device, electronic device and computer-readable storage medium
CN104267933A (en) Flashlight adjusting method
CN112102441B (en) Color card manufacturing method, device, electronic equipment and storage medium
CN107909569A (en) One kind flower screen detection method, flower screen detection device and electronic equipment
CN111164563B (en) Image color adjusting system and color adjusting method of intelligent terminal
CN106454096A (en) Image processing method and terminal thereof
US9679386B2 (en) Image processing device capable of segmenting an image into plural areas
CN105955754A (en) Method and device for displaying characters of user interface
CN104657037A (en) Terminal interface processing method
CN109410295A (en) Color setting method, device, equipment and computer readable storage medium
CN106022010A (en) File display method and device
CN105488381A (en) Color block sliding based mobile terminal unlocking method and system

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
WD01 Invention patent application deemed withdrawn after publication
WD01 Invention patent application deemed withdrawn after publication

Application publication date: 20150916