CN109901894A - A kind of progress bar image generating method, device and storage medium - Google Patents
A kind of progress bar image generating method, device and storage medium Download PDFInfo
- Publication number
- CN109901894A CN109901894A CN201711286785.3A CN201711286785A CN109901894A CN 109901894 A CN109901894 A CN 109901894A CN 201711286785 A CN201711286785 A CN 201711286785A CN 109901894 A CN109901894 A CN 109901894A
- Authority
- CN
- China
- Prior art keywords
- progress
- image
- referring
- task
- information
- 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.)
- Granted
Links
Abstract
The embodiment of the invention discloses a kind of progress bar image generating method, device and storage mediums;For the embodiment of the present invention using the configuration information for obtaining Task Progress image, which includes the image parameter information of the corresponding current task progress of user identifier and progress bar background image;Corresponding progress bar background image is drawn in painting canvas according to image parameter information, progress bar background image includes progress referring to image;Current task progress is obtained in progress referring to corresponding target progress location information in image;The corresponding Task Progress image of user identifier is obtained referring to corresponding progress mark image is inserted into image in progress according to target progress location information.The program can draw corresponding progress bar image based on the configuration information of progress bar image, avoid synthesizing progress bar image using plurality of pictures, obtain picture without from network side equipment, therefore, can promote the formation efficiency of progress bar image and save flow.
Description
Technical field
The present invention relates to technical field of image processing, and in particular to a kind of progress bar image generating method, device and storage
Medium.
Background technique
Progress bar can show the speed of processing task in computer disposal task with graphic form in real time, complete
Degree, the size of the unfinished task amount of residue, and may need to handle time etc., it is generally shown with strip, is mesh with reference to Fig. 1 a
Preceding common progress bar.
Progress bar can be divided into multiple types, such as downloading Task Progress item, grade progress bar according to task type.
Wherein, downloading task progress bar be used for show downloading task completeness and do not complete degree etc.;Grade progress bar is for display etc.
Grade progress and the unfinished task amount etc. for reaching goal gradient.
The generating mode of progress bar is that the mode based on picture synthesis specifically when needing to show progress bar, obtains at present
The background picture 100 in progress bar background picture such as Fig. 1 a, Fig. 1 b is taken, according to current task progress from preset picture
Content picture 1000 in corresponding progress bar content picture such as Fig. 1 a, Fig. 1 b is chosen, by progress chart background picture and progress bar
Content is synthesized, and is then rendered according to rendering samples pictures to the picture after synthesis, to obtain required progress bar.Its
In, the progress of Fig. 1 a and Fig. 1 b instruction is different.
However, the generating mode needs of progress bar use plurality of pictures at present, carries out synthesis rendering and obtain progress bar, into
The formation efficiency for spending item is lower, and these pictures need to obtain from network side equipment, consume a large amount of flow.
Summary of the invention
The embodiment of the present invention provides a kind of progress bar image generating method, device and storage medium, can promote progress bar
Formation efficiency and save flow.
The embodiment of the present invention provides a kind of progress bar image generating method, comprising:
Obtain the configuration information of Task Progress image, the configuration information include the corresponding current task of user identifier into
The image parameter information of degree and progress bar background image;
Corresponding progress bar background image, the progress bar Background are drawn in painting canvas according to described image parameter information
As including progress referring to image;
The current task progress is obtained in the progress referring to corresponding target progress location information in image;
It is obtained in the progress referring to corresponding progress mark image is inserted into image according to the target progress location information
To the corresponding Task Progress image of the user identifier.
Correspondingly, the embodiment of the invention also provides a kind of progress bar video generation devices, comprising:
Acquiring unit is configured, for obtaining the configuration information of Task Progress image, the configuration information includes user's mark
Know the image parameter information of corresponding current task progress and progress bar background image;
Drawing unit, for drawing corresponding progress bar background image, institute in painting canvas according to described image parameter information
Stating progress bar background image includes progress referring to image;
Position acquisition unit, for obtain the current task progress the progress referring to corresponding target in image into
Spend location information;
Be inserted into unit, for according to the target progress location information the progress referring to be inserted into image accordingly into
Scale knows image, obtains the corresponding Task Progress image of the user identifier.
Correspondingly, the embodiment of the present invention also provides a kind of storage medium, the storage medium is stored with instruction, described instruction
The progress bar image generating method of any offer of the embodiment of the present invention is provided when being executed by processor.
For the embodiment of the present invention using the configuration information for obtaining Task Progress image, configuration information includes that user identifier is corresponding
Current task progress and progress bar background image image parameter information;It is drawn in painting canvas according to image parameter information
Corresponding progress bar background image, progress bar background image include progress referring to image;Current task progress is obtained to join in progress
According to target progress location information corresponding in image;It is corresponding referring to insertion in image in progress according to target progress location information
Progress identifies image, obtains the corresponding Task Progress image of user identifier.The program can be based on the configuration of progress bar image
Information draws corresponding progress bar image, avoids synthesizing progress bar image using plurality of pictures, obtain without from network side equipment
Picture is taken, therefore, the formation efficiency of progress bar image can be promoted and save flow.
Detailed description of the invention
To describe the technical solutions in the embodiments of the present invention more clearly, make required in being described below to embodiment
Attached drawing is briefly described, it should be apparent that, drawings in the following description are only some embodiments of the invention, for
For those skilled in the art, without creative efforts, it can also be obtained according to these attached drawings other attached
Figure.
Fig. 1 a is the schematic diagram of existing progress bar;
Fig. 1 b is another schematic diagram of existing progress bar;
Fig. 2 a is the schematic diagram of a scenario of image generation system provided in an embodiment of the present invention;
Fig. 2 b is the first flow diagram of progress bar image generating method provided in an embodiment of the present invention;
Fig. 2 c is the correspondence diagram of parameter and appearance provided in an embodiment of the present invention;
Fig. 2 d is the first schematic diagram of progress bar background image provided in an embodiment of the present invention;
Fig. 2 e is second of schematic diagram of progress bar background image provided in an embodiment of the present invention;
Fig. 2 f is the third schematic diagram of progress bar background image provided in an embodiment of the present invention;
Fig. 2 g is the first schematic diagram of progress bar image provided in an embodiment of the present invention;
Fig. 2 h is that the position of current schedules provided in an embodiment of the present invention calculates schematic diagram;
Fig. 2 i is second of schematic diagram of progress bar image provided in an embodiment of the present invention;
Fig. 2 j is a kind of animation schematic diagram of progress bar image provided in an embodiment of the present invention;
Fig. 3 a is second of flow diagram provided in an embodiment of the present invention for closing progress bar image generating method;
Fig. 3 b is the 4th kind of schematic diagram of progress bar background image provided in an embodiment of the present invention;
Fig. 3 c is the 5th kind of schematic diagram of progress bar background image provided in an embodiment of the present invention;
Fig. 3 d is that the position of another current schedules provided in an embodiment of the present invention calculates schematic diagram;
Fig. 3 e is the third schematic diagram of progress bar image provided in an embodiment of the present invention;
Fig. 3 f is the 4th kind of schematic diagram of progress bar image provided in an embodiment of the present invention;
Fig. 4 a is the third flow diagram provided in an embodiment of the present invention for closing progress bar image generating method;
Fig. 4 b is that the position of another current schedules provided in an embodiment of the present invention calculates schematic diagram;
Fig. 4 c is the 5th kind of schematic diagram of progress bar image provided in an embodiment of the present invention;
Fig. 4 d is another animation schematic diagram of progress bar image provided in an embodiment of the present invention;
Fig. 5 a is the first structural schematic diagram of progress bar video generation device provided in an embodiment of the present invention;
Fig. 5 b is second of structural schematic diagram of progress bar video generation device provided in an embodiment of the present invention;
Fig. 5 c is the third structural schematic diagram of progress bar video generation device provided in an embodiment of the present invention;
Fig. 5 d is the third structural schematic diagram of progress bar video generation device provided in an embodiment of the present invention;
Fig. 6 is the structural schematic diagram of server provided in an embodiment of the present invention.
Specific embodiment
Following will be combined with the drawings in the embodiments of the present invention, and technical solution in the embodiment of the present invention carries out clear, complete
Site preparation description, it is clear that described embodiments are only a part of the embodiments of the present invention, instead of all the embodiments.It is based on
Embodiment in the present invention, those skilled in the art's every other implementation obtained without creative efforts
Example, shall fall within the protection scope of the present invention.
The embodiment of the present invention provides a kind of image generation system, which includes the progress of any offer of the embodiment of the present invention
Video generation device, the progress bar video generation device can integrate in the equipment such as terminal, which can be mobile phone, flat
Plate computer etc..In addition, the system can also include other equipment, such as server
With reference to Fig. 2 a, the embodiment of the invention provides a kind of image generation systems, comprising: terminal 10 and server 20, eventually
End 10 is connect with server 20 by network 30.It wherein, include router, gateway etc. network entity in network 30, in figure simultaneously
It does not illustrate.Terminal 10 can carry out information exchange by cable network or wireless network and server 20, such as can be from clothes
Be engaged in device 20 downloading application (such as game application) and/or application updated data package and/or to apply relevant data information or business
Information.Wherein, terminal 10 can be to be for mobile phone with terminal 10 for equipment, Fig. 2 a such as mobile phone, tablet computer, laptops
Example.Application needed for various users can be equipped in the terminal 10, for example, have amusement function application (such as Video Applications,
Audio plays application, ocr software), for another example have the application of service function (such as digital map navigation application is purchased by group and applied).
Based on system shown in above-mentioned Fig. 2 a, by taking game application as an example, terminal 10 can be by network 30 from server 20
In as desired download games application and/or game application updated data package and/or data information relevant to game application or
Business information (such as game screen data).Using the embodiment of the present invention, the configuration of the available Task Progress image of terminal 10
Information, configuration information include the image parameter information of the corresponding current task progress of user identifier and progress bar background image;
Corresponding progress bar background image is drawn in painting canvas according to image parameter information, progress bar background image includes progress referring to figure
Picture;Current task progress is obtained in progress referring to corresponding target progress location information in image;According to target progress bit confidence
Breath identifies image referring to corresponding progress is inserted into image in progress, obtains the corresponding Task Progress image of user identifier;Eventually
End 10 can show the corresponding Task Progress image of user identifier.
The example of above-mentioned Fig. 2 a is a system architecture example for realizing the embodiment of the present invention, and the embodiment of the present invention is not
It is limited to system structure shown in above-mentioned Fig. 2 a, is based on the system architecture, proposes each embodiment of the present invention.
In one embodiment, a kind of progress bar image generating method is provided, can be executed by the processor of terminal, is such as schemed
Shown in 2b, which includes:
101, obtain Task Progress image configuration information, configuration information include the corresponding Task Progress of user identifier,
And the image parameter information of progress bar background image.
Wherein, Task Progress image is used to show the status progression situation of task with image format, as current task is complete
Cheng Du, the size for not completing task amount etc..The task may include the corresponding level mission of user identifier, downloading task, upload
Task dispatching etc..
For example, at this point, Task Progress image can be grade progress bar image, being used for when task is level mission
The grade progress for showing user identifier, progress situation as needed for the present level of user identifier, distance objective grade etc.
Deng.
Wherein, grade progress bar image can be applied in various scenes, such as scene of game, social scene, shopping scene
Etc..For example, it applies in scene of game, which is displayed for user identifier (such as game in game
Account) game ratings progress, going game grade, distance objective game ratings such as user identifier (such as game account)
Required progress situation etc..
In another example grade progress bar image is applied in social scene, which is displayed in social activity
Grade (such as membership grade enlivens grade, login time grade) progress, such as user of user identifier (social account)
Progress situation needed for identifying the current social grade of (social account), distance objective game ratings etc..
For another example, grade progress bar image is applied in shopping at network scene, which is displayed for net
Grade (such as membership grade) progress of user identifier (shopping account) in network shopping platform, such as user identifier (shopping account)
Current social grade, progress situation needed for distance objective game ratings etc..
Wherein, the configuration information of Task Progress image is used to indicate the drafting of Task Progress image;The configuration information
It may include: the corresponding current task progress of user identifier, the image parameter information of progress bar background image, goal task progress
Etc..
Wherein, progress bar background image is the background or base image of Task Progress image, can be used as task
The reference image of progress.Task Progress image generally comprises progress bar background image and progress mark image.Progress bar back
Scape image and progress mark image are combined to indicate Task Progress.
The image parameter of the progress bar background image can be the picture appearance parameter of progress bar background image;It can wrap
It includes: shape style information relevant to image shape, image dimension information relevant with image size (as wide high) and image line
The relevant line style information of item (such as image line width information) is in addition, the image parameter can also include color configuration information
Etc..
For example, when progress bar background image is arc-shaped, shape style information relevant to image shape may include:
Arc radius, arc angle information (such as circular arc expanded angle).
By taking progress bar background image is semi-circular shape strip image as an example, which may include: that the wide height of painting canvas is (right
Answer the whole size of progress bar background image), annular radii (corresponding annulus size), annulus line width (thickness of corresponding annulus),
The distance between expanded angle (angle, the degree of annulus expansion of corresponding annulus), inner and outer ring are (between corresponding inside and outside annulus
Gap) etc..With reference to Fig. 2 c, the relationship between each image parameter and progress bar background image appearance is illustrated in figure.
102, corresponding progress bar background image, progress bar background image packet are drawn in painting canvas according to image parameter information
Progress is included referring to image.
Wherein, progress bar background image is the background or base image of Task Progress image, Task Progress image
Generally comprise progress bar background image and progress mark image.Progress bar background image may include progress referring to image, should
For progress referring to the reference that image is Task Progress or referring to image, progress illustrates all possible Task Progress referring to image,
I.e. from initial progress to all Task Progress target progress.Image is identified referring to addition progress in image in progress
To represent current task progress.
In addition, progress bar background image can also include some other images, such as user's head portrait etc..
For example, corresponding progress bar Background can be drawn in painting canvas according to image parameter information and using canvas
Picture.
Html5canvas is used for the drawing image on webpage, and the canvas element of Html5 is using JavaScript in webpage
Upper drawing image.Painting canvas is a rectangular area, can control its each pixel.
Canvas possesses a variety of drawing paths, rectangle, circle, character and the method for adding image.
Wherein, progress bar background image may include progress referring to image;The progress can be a variety of referring to the shape of image,
It for example can be bar graph picture.Strip image is shape image in a strip shape, as rectangle strip image, round strip image,
Circular ring shape strip image, semi-circular shape strip image etc..Wherein, the shape of bar graph can configure according to actual needs, this
When, the image parameter information of progress bar background image may include the form parameter information of strip image.
In the embodiment of the present invention, the expanded angle of semicircular ring strip image can there are many, be not limited only to 180 °, can be with
For the unspecified angle in 0-360 °, such as 45 degree, 50 degree, 60 degree.Also with regard to when say, which is not limited only to the half of annulus
This special circumstances, can also for annulus a quarter, 1/5th etc..
For example, using canvas painting canvas technology, being drawn on rectangle painting canvas according to image parameter information corresponding with reference to Fig. 2 d
Progress bar background image, which includes semicircular ring strip image.
In one embodiment, in order to accurately show Task Progress situation, progress bar background image can also include
Initiating task progress msg (such as initial task amount), current task progress msg (current completed task amount) and target are appointed
It is engaged in progress msg (goal task amount).
For example, by taking game ratings task as an example, initiating task progress msg may include initial leisurely and carefree play class information (such as
Silver IV), current task progress msg may include going game class information (such as silver II) and goal task progress letter
Breath may include target game class information (such as gold IV).In one embodiment, in order to more accurately show task into
Situation is spent, progress bar background image can also include: the mark figure of the mark image of initiating task progress, goal task progress
Picture;At this point, the mark image of initiating task progress, progress are sequentially connected referring to the mark image of image, goal task progress.
Wherein, mark image can configure according to actual needs, for example, can be point, virtual portrait head portrait image, virtual
Images of items etc..At this point, the configuration information of Task Progress image can also include: the mark image of initiating task progress
The image parameter information for identifying image of image parameter information, goal task progress.
For example, by taking task is membership grade task in social platform as an example, with reference to Fig. 2 e, figure middle grade progress bar Background
As 2 include the mark image 21 of sequentially connected initiating task progress, semicircular ring progress referring to image 22 and goal tasks into
The mark image 23 of degree.The mark image 21 is circle, the mark image 23 is five-pointed star image.
In addition, the grade progress bar background image 20 can also include: the corresponding membership grade information of initiating task progress
(in such as Fig. 2 e " silver member "), the corresponding target members class information of goal task progress (" masonry member " in such as Fig. 2 e).
103, current task progress is obtained in progress referring to corresponding target progress location information in image.
For example, with reference to Fig. 2 f, can establish two-dimensional coordinate system can after obtaining progress bar background image as shown in Figure 2 d
To obtain current task progress corresponding progress location information (including abscissa and ordinate) in strip image, such as Fig. 2 f institute
Show, the transverse and longitudinal coordinate of progress location information is (a, b).
104, image is identified referring to corresponding progress is inserted into image in progress according to target progress location information, is used
Family identifies corresponding progress bar image.
Wherein, progress mark image can be arranged according to actual needs, for example, can be user's head portrait, virtual objects figure
Picture or other images.
It can be in the corresponding position of the coordinate when the transverse and longitudinal coordinate for determining progress location information is (a, b) with reference to Fig. 2 g
The upper circular process identification (PID) image of insertion.
It wherein, can also include some text informations in Fig. 2 g, for example, the corresponding membership grade letter of initiating task progress
Cease (in such as Fig. 2 e " silver member "), corresponding target members class information (" the masonry meeting in such as Fig. 2 e of goal task progress
Member ") and the corresponding membership grade information of current task progress (in such as Fig. 2 e " gold member ").In addition, it can include:
The progress msg of distance objective membership grade, and reach interaction results information (e.g., " five foldings caused by target members grade
Buy XXX article " etc.).
Optionally, for increase progress bar scalability and intuitively and accurately reflect Task Progress situation, can into
Degree is finely divided, for example, progress can be subdivided into several small progresses, is reflected in progress bar image, is exactly needed to progress
It is segmented referring to image, each segment indicates a small progress.
In one embodiment, it can be segmented according to goal task progress, then, then obtain target progress bit confidence
Breath.Namely configuration information further includes goal task progress;At this point, step " obtains current task progress in progress referring in image
Corresponding target progress location information " may include:
Progress is divided into the sub- progress of multistage referring to image referring to image according to goal task progress;
The progress ratio between current task progress and goal task progress is obtained,
According to progress ratio and image parameter information, obtain current task progress progress referring to the corresponding target of image into
Spend location information.
Wherein, Task Progress can be indicated by numerical value, for example, goal task progress can be n, current task progress is
M, the n and m are positive integer, and n≤m.Optionally, the sub- progress after division is referring to amount of images and goal task progress numerical value phase
Deng.For example, progress is divided into n cross-talk progress referring to image referring to image.
After segmentation, can with the progress ratio m/n between current task progress m and goal task progress n, according to m/n and
The image parameter information (such as image dimension information, angle information) of progress bar background image, calculates current task progress m and exists
Progress is referring to the location information (such as transverse and longitudinal coordinate value) in image.
For example, when progress reference image is semi-circular shape progress reference image, at this point, the image of progress bar background image is joined
Number information may include: the annular radii of semi-circular shape progress reference image, annulus angle etc.;At this point it is possible to according to target
Semicircular ring progress is divided into the sub- progress of multistage referring to image referring to image by Task Progress, then, obtain current task progress with
Progress ratio between goal task progress is obtained in progress according to progress ratio and annulus angle referring to task in image
The corresponding target progress radian of progress;According to target progress radian and annular radii, the corresponding target of current task progress is obtained
Location information.
For example, can according to goal task progress n by semicircular ring strip image equal portions at n sections, then, be based on progress ratio
M/n and semicircular ring angle, θ obtain the corresponding progress radian d of current task progress m.Such as radian d=(current task progress m/ target
Task Progress) π/180 * 180*.Then, current task progress m is calculated by progress radian d and annular radii r in progress
The transverse and longitudinal coordinate value of background image.Such as abscissa x and ordinate y can be obtained by following formula:
Abscissa x=radius r*cos (π/180 radian d*)+radius r
Ordinate y=radius r*sin (π/180 radian d*)+radius r.
For example, with reference to Fig. 2 h, after obtaining progress bar background image shown in Fig. 2 d, can be incited somebody to action by taking m=2, n=5 as an example
Semicircular ring strip image is divided into 5 equal portions, then, passes through formula: radian d=(current task progress m/ goal task progress) *
π/180 180* calculate the corresponding radian d of current task progress 2, corresponding by the available progress 2 of above-mentioned coordinate value formula
Transverse and longitudinal coordinate value (a1, b1), as shown in fig. 2h, which is the end of the second segmentation
End position.
With reference to Fig. 2 i, image can be identified in the corresponding position insertion progress of transverse and longitudinal coordinate value (a1, b1), such as user's head portrait
Deng.
Optionally, in order to intuitively accurately give expression to Task Progress situation, different subsection fillings can also be directed to
Different color, for example, the configuration information of progress bar image can also include: sub- progress referring to the corresponding color configuration letter of image
Breath;It can also include: according to sub- progress referring to image pair after progress to be divided into the sub- progress of multistage referring to image referring to image
The color configuration information answered carries out color filling referring to image to sub- progress.
For example, color that can be different with subsection filling different in Fig. 2 h, by color come such as game of identification mission progress
Grade reduces learning cost.
Optionally, in order to save resource, the embodiment of the present invention can be in current task progress and initiating task progress not phase
Whens equal, progress division is carried out, it, can be directly in progress referring to image when current task progress is equal with initiating task progress
Initial position is inserted into corresponding progress and identifies image, calculates without carrying out progress division and position, saves terminal resource.
At this point, the configuration information of progress bar background image further includes initiating task progress.
Wherein, initiating task progress can be set according to actual needs, for example, when indicating Task Progress using numerical value,
It is 0,1,2 etc. that initiating task progress value, which can be set,.
By task be game ratings task for, initiating task progress can be set to minimum game ratings or other
Game ratings.
Optionally, in order to promote user experience, progress animation can also be set, which can be slow-action animation,
The animation effect for the target progress position that there is slow-action animation progress mark image to be moved to.Wherein, progress animation can basis
Actual demand configuration, for example, the configuration information of progress bar image can also include that the model information of progress animation and progress are moved
The duration of picture.
In the embodiment of the present invention, each animation can be calculated based on the model information of progress animation and shows that time point is corresponding
Position be then inserted into corresponding progress mark image in the position, a series of progress bar image, root will be obtained in this way
It shows that time point shows corresponding progress bar image according to animation, will generate and be identified image to the movement of target progress position
Animation effect.
Namely step " image is identified referring to corresponding progress is inserted into image in progress according to target progress location information ",
May include:
Initiating task progress is obtained in progress referring to the initial progress location information in image;
According to animation model information, duration, initial progress location information and target progress location information, obtain dynamic
Draw display time point corresponding image insertion position information;
According to image insertion position information in progress referring to being inserted into corresponding progress mark image in image.
Wherein, animation model information may include animation function;The animation function shows the time for calculating each animation
Point corresponding image insertion position information.For example, the animation function formula may include following formula:
The corresponding image insertion position value L=of time point t (the initial progress positional value C of target progress positional value M-) * is current
Time t/ duration T+initial progress positional value C.Wherein, target location value M may include the corresponding position of current task progress
Value is set as included abscissa value, and/or ordinate value;Initial progress positional value may include the corresponding position of initiating task progress
Value is as included abscissa value, and/or ordinate value.General initial progress positional value is 0.
For example, available current animation shows time point t, judge whether t is less than duration T, if being less than, root
Calculate animation according to above-mentioned animation function and show the corresponding image insertion position value of time point t, according to image insertion position value into
Degree identifies image referring to corresponding progress is inserted into image;If being not less than, when being such as equal to duration T, stop calculating.It is obtaining
Each animation shows that time point corresponding progress identifies image, then, shows that time point shows that progress identifies image according to animation,
It will realize that progress identifies the image animation effect mobile to target position, with reference to Fig. 2 j.
The method of the embodiment of the present invention can generate code by progress image in processor load store device and realize, the progress
Image generation code can be used JSON object and carry out unified storage, improve the scope of application of the program.
For the embodiment of the present invention using the configuration information for obtaining Task Progress image, configuration information includes that user identifier is corresponding
Current task progress and progress bar background image image parameter information;It is drawn in painting canvas according to image parameter information
Corresponding progress bar background image, progress bar background image include progress referring to image;Current task progress is obtained to join in progress
According to target progress location information corresponding in image;It is corresponding referring to insertion in image in progress according to target progress location information
Progress identifies image, obtains the corresponding Task Progress image of user identifier;The program can be based on the configuration of progress bar image
Information draws corresponding progress bar image, avoids synthesizing progress bar image using plurality of pictures, obtain without from network side equipment
Picture is taken, therefore, the formation efficiency of progress bar image can be promoted and save flow.
Also, the program can also further segment progress, be such as segmented progress bar image, can make progress
Image intuitively, accuracy show Task Progress state, the scalability of scheme is stronger, and the user experience is improved,
In addition, when user needs to modify progress bar image, user can modify according to actual needs to be matched using the program
Set parameter (such as angle, size) change progress bar image appearance, to generate required progress bar image, can quickly into
A degree image is modified, and modification cost is lowered, and reusability and the scalability for improving scheme are stronger.
In an embodiment, the embodiment of the invention also provides another progress bar image generating methods, as shown in Figure 3a, should
The detailed process of progress bar image generating method is as follows:
201, terminal obtains the configuration information of Task Progress image, and configuration information includes that user identifier is corresponding as predecessor
Business progress, initiating task progress, goal task progress, progress bar background image image parameter information.
Wherein, Task Progress image is used to show the status progression situation of task with image format, as current task is complete
Cheng Du, the size for not completing task amount etc..The task may include the corresponding level mission of user identifier, downloading task, upload
Task dispatching etc..
For example, at this point, Task Progress image can be grade progress bar image, being used for when task is level mission
The grade progress for showing user identifier, progress situation as needed for the present level of user identifier, distance objective grade etc.
Deng.
Wherein, the configuration information of Task Progress image is used to indicate the drafting of Task Progress image.Configuration information packet
Include the corresponding current task progress of user identifier, initiating task progress, goal task progress, the image ginseng of progress bar background image
Number information etc..
Wherein, Task Progress can be indicated by numerical value, for example, current task progress value is m, initiating task progress value is 0
Goal task progress value is n.
The image parameter of the progress bar background image can be the picture appearance parameter of progress bar background image;It can wrap
It includes: shape style information relevant to image shape, image dimension information relevant with image size (as wide high) and image line
The relevant line style information of item (such as image line width information) is in addition, the image parameter can also include color configuration information
Etc..For example, shape style information relevant to image shape may include: circle when progress bar background image is arc-shaped
Arc radius, arc angle information (such as circular arc expanded angle).
By taking progress bar background image is semi-circular shape strip image as an example, which may include: that the wide height of painting canvas is (right
Answer the whole size of progress bar background image), annular radii (corresponding annulus size), annulus line width (thickness of corresponding annulus),
The distance between expanded angle (angle, the degree of annulus expansion of corresponding annulus), inner and outer ring are (between corresponding inside and outside annulus
Gap) etc..With reference to Fig. 2 c, the relationship between each image parameter and progress bar background image appearance is illustrated in figure.
202, whether identical as initiating task progress terminal judges current task progress, if it is not, 203 are thened follow the steps, if
It is, then step 207.
For example, when initial Task Progress value is 0, it can be determined that whether current task progress value is zero.
203, terminal draws corresponding progress bar background image, progress bar Background according to image parameter information in painting canvas
As including being sequentially connected initial progress mark image, progress referring to image, target progress mark image.
Wherein, progress bar background image is the background or base image of Task Progress image, Task Progress image
Generally comprise progress bar background image and progress mark image.Progress bar background image may include progress referring to image, should
For progress referring to the reference that image is Task Progress or referring to image, progress illustrates all possible Task Progress referring to image,
I.e. from initial progress to all Task Progress target progress.Image is identified referring to addition progress in image in progress
To represent current task progress.
For example, corresponding progress bar Background can be drawn in painting canvas according to image parameter information and using canvas
Picture.
Wherein, progress referring to image shape can there are many, for example can be bar graph picture.Strip image is shape
Image in a strip shape, such as rectangle strip image, round strip image, circular ring shape strip image, semi-circular shape strip image
Deng.Wherein, the shape of bar graph can configure according to actual needs, at this point, the configuration information of Task Progress image can wrap
Include the form parameter information of strip image.
In the embodiment of the present invention, semicircular ring progress referring to image expanded angle can there are many, be not limited only to 180 °, also
It can be the unspecified angle in 0-360 °, such as 45 degree, 52 degree, 60 degree.
For example, using canvas painting canvas technology, being drawn on rectangle painting canvas according to image parameter information corresponding with reference to Fig. 3 b
Progress bar background image, which includes sequentially connected initial progress mark image 31, semicircular ring progress
Image 33 is identified referring to image 32 and goal task progress.
Wherein, mark image can configure according to actual needs, for example, can be point, virtual portrait head portrait image, virtual
Images of items etc..At this point, the configuration information of Task Progress image can also include: the image ginseng of initial progress mark image
The image parameter information of number information, goal task progress mark image.For example, with reference to Fig. 3 b, by taking task is level mission as an example,
Initial progress mark image is circle, and goal task progress image is square block diagram.Can also include in image shown in Fig. 3 b
Initial grade and goal gradient.
204, progress is divided into the sub- progress of multistage referring to image referring to image according to goal task progress by terminal.
For example, when progress referring to image is strip image, goal task progress value is n, it can be by strip image equal portions at n
Cross-talk strip image.With reference to Fig. 3 c, it is assumed that n=5, at this point it is possible to by semi-circular shape strip image equal portions at 5 cross-talk strip images
320。
205, terminal obtains the progress ratio between current task progress and goal task progress, according to progress ratio and figure
As parameter information, current task progress is obtained in progress referring to corresponding target progress location information in image.
Wherein, target progress location information may include that current task progress is sat in progress referring to transverse and longitudinal corresponding in image
Scale value.
For example, progress is strip image referring to image, after fragmentation, can with current task progress m and goal task into
The progress ratio m/n between n is spent, according to image parameter information (such as image dimension information, angle of m/n and progress bar background image
Spend information etc.), calculate location information (such as transverse and longitudinal coordinate value) of the current task progress m in strip image.
By taking progress is semicircular ring strip image referring to image as an example, according to goal task progress n by semicircular ring strip image etc.
Part is at n sections, then, obtains the corresponding progress radian d of current task progress m based on progress ratio m/n and semicircular ring angle, θ.Such as
Radian d=(current task progress m/ goal task progress) π/180 * 180*.Then, by progress radian d and annular radii r come
Current task progress m is calculated in the transverse and longitudinal coordinate value of progress bar background image.Abscissa x can be such as obtained by following formula
With ordinate y:
Abscissa x=radius r*cos (π/180 radian d*)+radius r
Ordinate y=radius r*sin (π/180 radian d*)+radius r.
For example, with reference to Fig. 3 d, after obtaining progress bar background image shown in Fig. 3 c, can be incited somebody to action by taking m=3, n=5 as an example
Semicircular ring strip image is divided into 5 equal portions, then, passes through formula: radian d=(current task progress m/ goal task progress) *
π/180 180* calculate the corresponding radian d of current task progress 3, corresponding by the available progress 3 of above-mentioned coordinate value formula
Transverse and longitudinal coordinate value (a2, b2), as shown in Figure 3d, the corresponding position of transverse and longitudinal coordinate value (a2, b2) be third segmentation end
End position.
206, terminal draws progress and identifies image, and according to target progress location information progress referring to be inserted into image into
Scale knows image.
Terminal can draw progress mark image offline, and progress mark image can be arranged according to actual needs, for example, can
Think user's head portrait, virtual objects image or other images.
With reference to Fig. 3 e, can be segmented according to the transverse and longitudinal coordinate value (a2, b2) of the corresponding position of goal task progress in third
Terminal position insertion progress identify image, here progress mark image can be corner block.It wherein, further include current in Fig. 3 e
Class information.It in other embodiments, can also include other information relevant to progress in the progress bar image.
207, terminal draws corresponding progress bar background image, progress bar Background according to image parameter information in painting canvas
As including being sequentially connected initial progress mark image, progress referring to image, target progress mark image.
The drawing process of progress bar background image can refer to above-mentioned introduction, and details are not described herein again.
208, terminal draws progress and identifies image, and identifies image referring to the initial position insertion progress of image in progress.
For example, with reference to Fig. 3 f, can the progress shown in Fig. 3 d referring to the initial position insertion progress of image identify image,
It is a corner block that the progress, which identifies image,.
Optionally, in order to promote user experience, progress animation can also be set, which can be slow-action animation,
The animation effect for the target progress position that there is slow-action animation progress mark image to be moved to.Wherein, progress animation can basis
Actual demand configuration, for example, the configuration information of progress bar image can also include that the model information of progress animation and progress are moved
The duration of picture.It is specifically as follows:
Initiating task progress is obtained in progress referring to the initial progress location information in image;
According to animation model information, duration, initial progress location information and target progress location information, obtain dynamic
Draw display time point corresponding image insertion position information;
According to image insertion position information in progress referring to being inserted into corresponding progress mark image in image;
Show that time point shows corresponding progress bar image according to animation, to realize progress animation.
Wherein, animation model information may include animation function;The animation function shows the time for calculating each animation
Point corresponding image insertion position information.For example, the animation function formula may include following formula:
The corresponding image insertion position value L=of time point t (the initial progress positional value C of target progress positional value M-) * is current
Time t/ duration T+initial progress positional value C.Wherein, target location value M may include the corresponding position of current task progress
Value is set as included abscissa value, and/or ordinate value;Initial progress positional value may include the corresponding position of initiating task progress
Value is as included abscissa value, and/or ordinate value.General initial progress positional value is 0.
For example, available current animation shows time point t, judge whether t is less than duration T, if being less than, root
Calculate animation according to above-mentioned animation function and show the corresponding image insertion position value of time point t, according to image insertion position value into
Degree identifies image referring to corresponding progress is inserted into image;If being not less than, when being such as equal to duration T, stop calculating.It is obtaining
Each animation shows that time point corresponding progress identifies image, then, shows that time point shows that progress identifies image according to animation,
It will realize that progress identifies the image animation effect mobile to target position, with reference to Fig. 2 j.
The method of the embodiment of the present invention can generate code by progress image in processor load store device and realize, the progress
Image generation code can be used JSON object and carry out unified storage, improve the scope of application of the program.
For the embodiment of the present invention using the configuration information for obtaining Task Progress image, configuration information includes that user identifier is corresponding
Current task progress and progress bar background image image parameter information;It is drawn in painting canvas according to image parameter information
Corresponding progress bar background image, progress bar background image include progress referring to image;Current task progress is obtained to join in progress
According to target progress location information corresponding in image;It is corresponding referring to insertion in image in progress according to target progress location information
Progress identifies image, obtains the corresponding progress bar image of user identifier;The program can be based on the configuration information of progress bar image
Corresponding progress bar image is drawn, avoids synthesizing progress bar image using plurality of pictures, scheme without being obtained from network side equipment
Therefore piece can promote the formation efficiency of progress bar image and save flow.Also, the program can also be to progress into one
Step subdivision, such as progress bar image is segmented, can make progress bar image intuitively, accuracy display Task Progress shape
The scalability of state, scheme is stronger, and the user experience is improved,
In addition, when user needs to modify progress bar image, user can modify according to actual needs to be matched using the program
Set parameter (such as angle, size) change progress bar image appearance, to generate required progress bar image, can quickly into
A degree image is modified, and modification cost is lowered, and reusability and the scalability for improving scheme are stronger.
In one embodiment, by taking task is level mission, progress bar is semicircular ring progress bar as an example, this hair is discussed in detail
The method of bright offer.A kind of grade progress bar generation method, with reference to Fig. 4 a, detailed process is as follows:
401, terminal obtains the configuration information of grade progress bar image, and configuration information includes that user identifier is corresponding current etc.
Grade progress value, initial grade progress, goal task progress and semicircular ring strip image image parameter information.
Wherein, grade progress bar image, for showing the grade progress of user identifier, such as user identifier is current
Progress situation needed for grade, distance objective grade etc..
Wherein, grade progress bar image can be applied in various scenes, such as scene of game, social scene, shopping scene
Etc., at this point, grade may include game ratings, social grade, shopping grade etc..For example, it applies in scene of game, it should
Grade progress bar image is displayed for the game ratings progress of user identifier in game (such as game account), such as user
Progress situation needed for identifying the going game grade of (such as game account), distance objective game ratings etc..
Wherein, image parameter may include: the wide height of painting canvas, annular radii, annulus line width, expanded angle, between inner and outer ring
Distance etc..With reference to Fig. 2 c, the relationship between each image parameter and semicircular ring strip picture appearance is illustrated in figure.
In the embodiment of the present invention, the expanded angle of semicircular ring strip can there are many, be not limited only to 180 °, can also be 0-
Unspecified angle in 360 °, such as 45 degree, 52 degree, 60 degree.
Wherein, grade progress can be indicated by numerical value, for example, present level progress value be m, initial grade progress value be 0,
Goal gradient progress value is n.
The corresponding initial grade of initial grade progress and the corresponding goal gradient of goal gradient progress can be according to practical need
Setting is asked, such as in some game, the corresponding initial grade of initial grade progress can be silver IV, and goal gradient progress is corresponding
Goal gradient can be for gold IV etc..
402, whether identical as initial grade progress terminal judges present level progress, if it is not, 403 are thened follow the steps, if
It is to then follow the steps 40.
For example, when initial grade progress value is 0, it can be determined that whether present level progress value is zero.
403, terminal draws sequentially connected initial grade progress mark image, half according to image parameter information in painting canvas
Annulus strip image and goal gradient progress identify image.
For example, terminal can use canvas painting canvas technology, drawn on rectangle painting canvas according to image parameter information corresponding
Image.
Wherein, mark image can configure according to actual needs, for example, can be point, virtual portrait head portrait image, virtual
Images of items etc..At this point, the configuration information of grade progress bar image can also include: the figure of initial grade progress mark image
As parameter information, the image parameter information of goal gradient progress mark image.
404, terminal is according to goal gradient progress by the sub- strip image of semicircular ring strip image equal portions multistage.
For example, according to goal gradient progress n by semicircular ring strip image equal portions at n sections.
In an embodiment, terminal can also according to the corresponding color configuration information of sub- strip image, to sub- strip image into
Row color filling enriches the color of grade progress bar image, identifies grade convenient for user.At this point, grade progress bar image is matched
Confidence breath can also include the color configuration information of sub- strip image after dividing.
405, terminal obtains the progress ratio between present level progress and goal gradient progress, according to progress ratio and half
Annulus expanded angle calculates the corresponding progress radian of present level progress, is calculated currently according to progress radian and annular radii
Target progress location information of the grade progress in semicircular ring strip image.
For example, obtaining the corresponding progress radian d of present level progress m based on progress ratio m/n and semicircular ring angle, θ.Such as
Radian d=(present level progress m/ goal gradient progress) π/180 * 180*.Then, by progress radian d and annular radii r come
Present level progress m is calculated in the transverse and longitudinal coordinate value of progress bar background image.Abscissa x can be such as obtained by following formula
With ordinate y:
Abscissa x=radius r*cos (π/180 radian d*)+radius r
Ordinate y=radius r*sin (π/180 radian d*)+radius r.
It,, can will half after drawing image with reference to Fig. 4 b for grade is game ratings for example, with m=1, n=5
Annulus strip image is divided into 5 equal portions, then, passes through formula: radian d=(present level progress m/ goal gradient progress) *
π/180 180* calculate the corresponding radian d of present level progress 1, corresponding by the available progress 1 of above-mentioned coordinate value formula
Transverse and longitudinal coordinate value (a3, b3), as shown in Figure 4 b, which is the end of the first segmentation
End position.
406, terminal draws progress and identifies image, and progress mark is inserted into strip image according to target progress location information
Know image.
For example, terminal can draw progress mark image offline, progress mark image can be arranged according to actual needs, than
It such as, can be user's head portrait, virtual objects image or other images.
After the progress of drafting mark image, progress can be identified to the corresponding position of image insertion target progress location information
It sets, refers to, Fig. 4 c is inserted into the terminal position of the first segmentation.
With reference to Fig. 4 c, grade progress bar image can also include: the corresponding initial grade information of initial grade progress (as swum
Play grade " gold IV "), the corresponding goal gradient information of goal gradient progress (such as game ratings " platinum V "), present level into
Spend corresponding class information (such as game ratings " gold III ").
In addition, in some embodiments, grade progress bar image can also include: present level distance objective grade into
Information is spent, and reaches the associated result output information of goal gradient, for example, with reference to Fig. 4 c, in game ratings progress bar image
In further include going game Rank distance target game grade progress msg " win again 5 to platinum V ", result output information packet
Include " obtaining XXX skin ".
407, terminal draws sequentially connected initial grade progress mark image, half according to image parameter information in painting canvas
Annulus strip image and goal gradient progress identify image.
The drawing process of progress bar background image can refer to above-mentioned introduction, and details are not described herein again.
408, terminal draws progress and identifies image, and in the initial position of semicircular ring strip image insertion progress mark figure
Picture.
For example, with reference to Fig. 3 f, the initial position insertion progress of the strip image shown in Fig. 3 d identifies image, should be into
It is a corner block that scale, which knows image,.
Optionally, in order to promote user experience, progress animation can also be set, which can be slow-action animation,
The animation effect for the target progress position that there is slow-action animation progress mark image to be moved to.Wherein, progress animation can basis
Actual demand configuration, for example, the configuration information of progress bar image can also include that the animation function of progress animation and progress are moved
The duration of picture.It is specifically as follows:
The animation function shows time point corresponding image insertion position information for calculating each animation.For example, this is dynamic
Drawing function formula may include following formula:
The corresponding image insertion position value L=of time point t (the initial progress positional value C of target progress positional value M-) * is current
Time t/ duration T+initial progress positional value C.Wherein, target location value M may include the corresponding position of present level progress
Value is set as included abscissa value, and/or ordinate value;Initial progress positional value may include the corresponding position of initial grade progress
Value is as included abscissa value, and/or ordinate value.General initial progress positional value is 0.
For example, available current animation shows time point t, judge whether t is less than duration T, if being less than, root
Animation is calculated according to above-mentioned animation function and shows the corresponding image insertion position value of time point t, according to image insertion position value in item
Corresponding progress mark image is inserted into shape image;If being not less than, when being such as equal to duration T, stop calculating.Obtain it is each
Animation shows that time point corresponding progress identifies image, then, shows that time point shows that progress identifies image according to animation, will
Realization progress identifies the image animation effect mobile to target position, with reference to Fig. 4 d.
The method of the embodiment of the present invention can generate code by progress image in processor load store device and realize, the progress
Image generation code can be used JSON object and carry out unified storage, improve the scope of application of the program.
The present invention implements offer scheme can be to the length and width of progress bar, radius, angle, line width, starting point, progress color matching etc.
Variable is parameterized, and JSON object has been used to carry out unified storage, by the way of the drafting of Canvas code, is being drawn
It is drawn on cloth according to configuration variables parameter, to change the apparent size pattern of progress bar, without using picture.It can pass through
The mode of configuration parameter changes the appearance of progress bar, if having the change such as appearance demand size color, can according to need
Relevant parameter is modified to meet, production replacement picture is not needed, saves flow.
In addition, the present invention extends progress bar, subdivision can be carried out to progress bar, utilize simple arc
To indicate various states.Comparison traditional technology needs are illustrated on text, have used patterned technology by complicated letter
Breath is simplified, and user cognition is further improved, and the user experience is improved.
For the ease of better implementation progress bar image generating method provided in an embodiment of the present invention, in one embodiment also
Provide a kind of progress bar video generation device.Wherein the meaning of noun is identical with above-mentioned progress bar image generating method, tool
Body realizes that details can be with reference to the explanation in embodiment of the method.
In one embodiment, a kind of progress bar video generation device is additionally provided, as shown in Figure 5 a, the pass progress bar image
Generating means may include: configuration acquiring unit 501, drawing unit 502, position acquisition unit 503 and insertion unit 504;
Acquiring unit 501 is configured, for obtaining the configuration information of Task Progress image, the configuration information includes user
Identify the image parameter information of corresponding current task progress and progress bar background image;
Drawing unit 502, for drawing corresponding progress bar background image in painting canvas according to described image parameter information,
The progress bar background image includes progress referring to image;
Position acquisition unit 503, for obtaining the current task progress in the progress referring to corresponding mesh in image
Mark progress location information;
It is inserted into unit 504, for corresponding referring to insertion in image in the progress according to the target progress location information
Progress identify image, obtain the corresponding Task Progress image of the user identifier.
In one embodiment, the configuration information can also include: goal task progress;With reference to Fig. 5 b, position acquisition list
Member 503 may include: to divide subelement 5031, ratio acquisition subelement 5032 and position acquisition subelement 5033;
Subelement 5031 is divided, for the progress to be divided into the sub- progress of multistage referring to image according to goal task progress
Referring to image;
Ratio obtain subelement 5032, for obtain between the current task progress and the goal task progress into
Ratio is spent,
Position acquisition subelement 5033, for working as described in acquisition according to the progress ratio and described image parameter information
Preceding Task Progress is in the progress referring to the corresponding target progress location information of image.
In one embodiment, the progress is semi-circular shape progress referring to image referring to image;Described image parameter information
It include: annular radii, annulus angle of the semi-circular shape progress referring to image;At this point, position acquisition subelement 5033 can be used for:
According to the progress ratio and the annulus angle, obtain in progress Task Progress referring to described in image
Corresponding target progress radian;
According to the target progress radian and the annular radii, the corresponding target position of the current task progress is obtained
Information.
In one embodiment, the configuration information further include: sub- progress is referring to the corresponding color configuration information of image;With reference to
Fig. 5 c, the progress bar video generation device can also include color filling unit 505;
The color filling unit 505, is used for: the progress being divided into multistage referring to image dividing subelement 5031
After sub- progress reference image, according to the sub- progress referring to the corresponding color configuration information of image, to the sub- progress reference
Image carries out color filling.
In one embodiment, the configuration information further include: initiating task progress;
The division subelement 5031 is used for when the current task progress and the initiating task progress are unequal,
The progress is divided into the sub- progress of multistage referring to image referring to image according to goal task progress
The insertion unit 504 is also used to when the current task progress is equal with the initiating task progress, in institute
It states progress and is inserted into corresponding progress mark image referring to the initial position of image.
In one embodiment, the configuration information further include: the animation model information of progress animation and progress animation
Duration;
The insertion unit 504, is used for:
The initiating task progress is obtained in the progress referring to the initial progress location information in image;
According to the animation model information, the duration, the initial progress location information and the target into
Location information is spent, animation is obtained and shows time point corresponding image insertion position information;
According to described image insertion position information in the progress referring to being inserted into corresponding progress mark image in image.
Optionally, with reference to Fig. 5 d, progress bar video generation device can also include display unit 506;For according to animation
Show that time point shows that corresponding progress identifies image, to realize progress animation.
When it is implemented, above each unit can be used as independent entity to realize, any combination can also be carried out, is made
It is realized for same or several entities, the specific implementation of above each unit can be found in the embodiment of the method for front, herein not
It repeats again.
The text animation realization device specifically can integrate terminal, for example be integrated in the terminal in the form of client, should
Terminal can be the equipment such as mobile phone, tablet computer.
From the foregoing, it will be observed that progress bar video generation device of the embodiment of the present invention using configuration acquiring unit 501 obtain task into
The configuration information of an image is spent, configuration information includes the corresponding current task progress of user identifier and progress bar background image
Image parameter information;Draw corresponding progress bar background image in painting canvas according to image parameter information by drawing unit 502,
Progress bar background image includes progress referring to image;Current task progress is obtained in progress referring to figure by position acquisition unit 503
The corresponding target progress location information as in;By insertion unit 504 according to target progress location information in progress referring in image
It is inserted into corresponding progress mark image, obtains the corresponding Task Progress image of user identifier.The program can be based on progress bar
The configuration information of image draws corresponding progress bar image, avoids synthesizing progress bar image using plurality of pictures, without from net
Network side apparatus obtains picture, therefore, can promote the formation efficiency of progress bar image and save flow.
With reference to Fig. 6, it may include one or more than one processing core that the embodiment of the invention provides a kind of terminals 600
The processor 601 of the heart, the memory 602 of one or more computer readable storage mediums, radio frequency (Radio
Frequency, RF) components such as circuit 603, power supply 604, input unit 605 and display unit 606.Those skilled in the art
It is appreciated that the restriction of terminal structure shown in Fig. 6 not structure paired terminal, may include than illustrating more or fewer portions
Part perhaps combines certain components or different component layouts.Wherein:
Processor 601 is the control centre of the terminal, using the various pieces of various interfaces and the entire terminal of connection,
By running or execute the software program and/or module that are stored in memory 602, and calls and be stored in memory 602
Data, execute terminal various functions and processing data, thus to terminal carry out integral monitoring.Optionally, processor 601 can
Including one or more processing cores;Preferably, processor 601 can integrate application processor and modem processor, wherein
The main processing operation system of application processor, user interface and application program etc., modem processor mainly handles channel radio
Letter.It is understood that above-mentioned modem processor can not also be integrated into processor 601.
Memory 602 can be used for storing software program and module, and processor 601 is stored in memory 602 by operation
Software program and module, thereby executing various function application and data processing.
During RF circuit 603 can be used for receiving and sending messages, signal is sended and received.
Terminal further includes the power supply 604 (such as battery) powered to all parts, it is preferred that power supply can pass through power supply pipe
Reason system and processor 601 are logically contiguous, to realize management charging, electric discharge and power managed by power-supply management system
Etc. functions.
The terminal may also include input unit 605, which can be used for receiving the number or character letter of input
Breath, and generation keyboard related with user setting and function control, mouse, operating stick, optics or trackball signal are defeated
Enter.
The terminal may also include display unit 606, which can be used for showing information input by user or mention
The information of user and the various graphical user interface of terminal are supplied, these graphical user interface can be by figure, text, figure
Mark, video and any combination thereof are constituted.Specifically in the present embodiment, the processor 601 in terminal is understood according to following instruction,
The corresponding executable file of the process of one or more application program is loaded into memory 602, and by processor
601 run storage application program in the memory 602, thus realize various functions, it is as follows:
Obtain the configuration information of Task Progress image, the configuration information include the corresponding current task of user identifier into
The image parameter information of degree and progress bar background image;According to described image parameter information drawn in painting canvas accordingly into
A background image is spent, the progress bar background image includes progress referring to image;Obtain the current task progress it is described into
Degree is referring to corresponding target progress location information in image;According to the target progress location information in the progress referring to image
The middle corresponding progress of insertion identifies image, obtains the corresponding Task Progress image of the user identifier.
The introduction of progress bar image generating method detailed step can refer to the description of above method example, no longer superfluous here
It states.
From the foregoing, it will be observed that the configuration information of the available Task Progress image of the terminal of that embodiment of the invention, configuration information packet
Include the image parameter information of the corresponding current task progress of user identifier and progress bar background image;Believed according to image parameter
Breath draws corresponding progress bar background image in painting canvas, and progress bar background image includes progress referring to image;It obtains as predecessor
Business progress is in progress referring to corresponding target progress location information in image;According to target progress location information in progress referring to figure
It is inserted into corresponding progress mark image as in, obtains the corresponding Task Progress image of user identifier.The program can based on into
The configuration information for spending an image draws corresponding progress bar image, avoids synthesizing progress bar image using plurality of pictures, without
Picture is obtained from network side equipment, therefore, the formation efficiency of progress bar image can be promoted and save flow.
Those of ordinary skill in the art will appreciate that all or part of the steps in the various methods of above-described embodiment is can
It is completed with instructing relevant hardware by program, which can be stored in a computer readable storage medium, storage
Medium may include: read-only memory (ROM, Read Only Memory), random access memory (RAM, Random
Access Memory), disk or CD etc..
A kind of progress bar image generating method, device and storage medium is provided for the embodiments of the invention above to carry out
It is discussed in detail, used herein a specific example illustrates the principle and implementation of the invention, above embodiments
Illustrate to be merely used to help understand method and its core concept of the invention;Meanwhile for those skilled in the art, according to this
The thought of invention, there will be changes in the specific implementation manner and application range, in conclusion the content of the present specification is not answered
It is interpreted as limitation of the present invention.
Claims (14)
1. a kind of progress bar image generating method characterized by comprising
Obtain Task Progress image configuration information, the configuration information include the corresponding current task progress of user identifier,
And the image parameter information of progress bar background image;
Corresponding progress bar background image, the progress bar background image packet are drawn in painting canvas according to described image parameter information
Progress is included referring to image;
The current task progress is obtained in the progress referring to corresponding target progress location information in image;
Institute is obtained referring to corresponding progress mark image is inserted into image in the progress according to the target progress location information
State the corresponding Task Progress image of user identifier.
2. progress bar image generating method as described in claim 1, which is characterized in that the configuration information further include: target
Task Progress;
The current task progress is obtained in the progress referring to corresponding target progress location information in image, comprising:
The progress is divided into the sub- progress of multistage referring to image referring to image according to goal task progress;
The progress ratio between the current task progress and the goal task progress is obtained,
According to the progress ratio and described image parameter information, the current task progress is obtained in the progress referring to image
Corresponding target progress location information.
3. progress bar image generating method as claimed in claim 2, which is characterized in that the progress is semicircular ring referring to image
Shape progress is referring to image;Described image parameter information includes: annular radii, annulus angle of the semi-circular shape progress referring to image;
According to the progress ratio and described image parameter information, current task progress corresponding target progress position is obtained
Information, comprising:
According to the progress ratio and the annulus angle, obtain corresponding in progress Task Progress referring to described in image
Target progress radian;
According to the target progress radian and the annular radii, the corresponding target position letter of the current task progress is obtained
Breath.
4. progress bar image generating method as claimed in claim 2, which is characterized in that the configuration information further include: son into
Degree is referring to the corresponding color configuration information of image;
After the progress to be divided into the sub- progress of multistage referring to image referring to image, the method also includes:
According to the sub- progress referring to the corresponding color configuration information of image, color is carried out referring to image to the sub- progress and is filled out
It fills.
5. such as the described in any item progress bar image generating methods of claim 2-4, which is characterized in that the configuration information also wraps
It includes: initiating task progress;
The progress is divided into the sub- progress of multistage referring to image referring to image according to goal task progress, comprising:
When the current task progress and the initiating task progress are unequal, the progress is joined according to goal task progress
The sub- progress of multistage is divided into referring to image according to image;
The method also includes: when the current task progress is equal with the initiating task progress, in the progress reference
The initial position of image is inserted into corresponding progress and identifies image.
6. progress bar image generating method as claimed in claim 5, which is characterized in that the configuration information further include: progress
The animation model information of animation and the duration of progress animation;
According to the target progress location information in the progress referring to being inserted into corresponding progress mark image in image, comprising:
The initiating task progress is obtained in the progress referring to the initial progress location information in image;
According to the animation model information, the duration, the initial progress location information and the target progress bit
Confidence breath obtains animation and shows time point corresponding image insertion position information;
According to described image insertion position information in the progress referring to being inserted into corresponding progress mark image in image.
7. progress bar image generating method as claimed in claim 6, which is characterized in that further include: the time is shown according to animation
Point shows that corresponding progress identifies image, to realize progress animation.
8. a kind of progress bar video generation device characterized by comprising
Acquiring unit is configured, for obtaining the configuration information of Task Progress image, the configuration information includes user identifier pair
The image parameter information of the current task progress and progress bar background image answered;
Drawing unit, for drawing corresponding progress bar background image in painting canvas according to described image parameter information, it is described into
A degree background image includes progress referring to image;
Position acquisition unit, for obtaining the current task progress in the progress referring to corresponding target progress bit in image
Confidence breath;
Be inserted into unit, for according to the target progress location information in the progress referring to being inserted into corresponding progress mark in image
Know image, obtains the corresponding Task Progress image of the user identifier.
9. progress bar video generation device as claimed in claim 8, which is characterized in that the configuration information further include: target
Task Progress;
The position acquisition unit, comprising:
Subelement is divided, for the progress to be divided into the sub- progress of multistage referring to figure referring to image according to goal task progress
Picture;
Ratio obtains subelement, for obtaining the progress ratio between the current task progress and the goal task progress,
Position acquisition subelement, for according to the progress ratio and described image parameter information, obtain the current task into
Degree is in the progress referring to the corresponding target progress location information of image.
10. progress bar video generation device as claimed in claim 9, which is characterized in that the progress is semicircle referring to image
Annular progress is referring to image;Described image parameter information includes: the annular radii of semi-circular shape progress reference image, annulus angle
Degree;
The position acquisition subelement, is specifically used for:
According to the progress ratio and the annulus angle, obtain corresponding in progress Task Progress referring to described in image
Target progress radian;
According to the target progress radian and the annular radii, the corresponding target position letter of the current task progress is obtained
Breath.
11. progress bar video generation device as claimed in claim 9, which is characterized in that the configuration information further include: son into
Degree is referring to the corresponding color configuration information of image;
The progress bar video generation device further includes color filling unit;
The color filling unit, is used for: the progress being divided into the sub- progress reference of multistage referring to image dividing subelement
After image, according to the sub- progress referring to the corresponding color configuration information of image, face is carried out referring to image to the sub- progress
Color filling.
12. such as the described in any item progress bar video generation devices of claim 9-11, which is characterized in that the configuration information is also
It include: initiating task progress;
The division subelement is used for when the current task progress and the initiating task progress are unequal, according to target
The progress is divided into the sub- progress of multistage referring to image referring to image by Task Progress
The insertion unit is also used to when the current task progress is equal with the initiating task progress, in the progress
Corresponding progress mark image is inserted into referring to the initial position of image.
13. progress bar video generation device as claimed in claim 12, which is characterized in that the configuration information further include: into
Spend the animation model information of animation and the duration of progress animation;
The insertion unit, is used for:
The initiating task progress is obtained in the progress referring to the initial progress location information in image;
According to the animation model information, the duration, the initial progress location information and the target progress bit
Confidence breath obtains animation and shows time point corresponding image insertion position information;
According to described image insertion position information in the progress referring to being inserted into corresponding progress mark image in image.
14. a kind of storage medium, which is characterized in that the storage medium is stored with instruction, when described instruction is executed by processor
Realize such as the described in any item progress bar image generating methods of claim 1-7.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201711286785.3A CN109901894B (en) | 2017-12-07 | 2017-12-07 | Progress bar image generation method and device and storage medium |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201711286785.3A CN109901894B (en) | 2017-12-07 | 2017-12-07 | Progress bar image generation method and device and storage medium |
Publications (2)
Publication Number | Publication Date |
---|---|
CN109901894A true CN109901894A (en) | 2019-06-18 |
CN109901894B CN109901894B (en) | 2021-06-08 |
Family
ID=66939489
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201711286785.3A Active CN109901894B (en) | 2017-12-07 | 2017-12-07 | Progress bar image generation method and device and storage medium |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN109901894B (en) |
Cited By (15)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN111324404A (en) * | 2020-01-20 | 2020-06-23 | 北京无限光场科技有限公司 | Information acquisition progress display method and device, electronic equipment and readable medium |
CN111399736A (en) * | 2020-03-17 | 2020-07-10 | 腾讯科技(深圳)有限公司 | Progress bar control method, device and equipment and readable storage medium |
CN111596853A (en) * | 2020-04-29 | 2020-08-28 | 五八有限公司 | Method and device for realizing rolling indicator, electronic equipment and storage medium |
CN112306616A (en) * | 2020-11-23 | 2021-02-02 | 北京百家科技集团有限公司 | Loading display processing method and device, computer equipment and storage medium |
CN112330773A (en) * | 2020-11-30 | 2021-02-05 | 广州博冠信息科技有限公司 | Countdown image generation method and device, electronic equipment and computer medium |
CN112435308A (en) * | 2020-11-30 | 2021-03-02 | 成都新潮传媒集团有限公司 | Drawing method and device of annular progress bar and storage medium |
CN112544675A (en) * | 2020-12-23 | 2021-03-26 | 智锐达仪器科技南通有限公司 | Livestock carcass skin source tracing code spraying method, inkjet printer and control method |
CN112579083A (en) * | 2020-12-09 | 2021-03-30 | 京东数字科技控股股份有限公司 | Image display method and device, electronic equipment and storage medium |
CN112711417A (en) * | 2020-12-30 | 2021-04-27 | 上海铼锶信息技术有限公司 | Manufacturing method of progress bar and electronic equipment |
CN112949249A (en) * | 2021-02-20 | 2021-06-11 | 山东英信计算机技术有限公司 | Method, system and device for determining element placing position |
CN113837019A (en) * | 2021-08-31 | 2021-12-24 | 北京新氧科技有限公司 | Cosmetic progress detection method, device, equipment and storage medium |
CN113961281A (en) * | 2021-08-13 | 2022-01-21 | 叮联信息技术有限公司 | Internet-based task progress display method and device |
CN114071238A (en) * | 2021-11-12 | 2022-02-18 | 北京百度网讯科技有限公司 | Method, apparatus, device, medium and product for generating video progress bar |
US20220215494A1 (en) * | 2019-09-24 | 2022-07-07 | Nova Southeastern University | Systems and methods for mentoring students and facilitating their entry into healthcare professions |
WO2023173728A1 (en) * | 2022-03-16 | 2023-09-21 | 北京字跳网络技术有限公司 | Graphic rendering method and apparatus, and storage medium |
Citations (11)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20100303450A1 (en) * | 2009-05-29 | 2010-12-02 | Nokia Corporation | Playback control |
WO2012106269A1 (en) * | 2011-01-31 | 2012-08-09 | Cbs Interactive, Inc. | Media playback control |
CN103577063A (en) * | 2012-07-23 | 2014-02-12 | Lg电子株式会社 | Mobile tmerinal and control method thereof |
CN104461479A (en) * | 2013-09-13 | 2015-03-25 | 腾讯科技(深圳)有限公司 | Timing method and device |
CN105227830A (en) * | 2015-09-01 | 2016-01-06 | 上海由零网络科技有限公司 | A kind of method for processing video frequency and processing system for video |
CN105306667A (en) * | 2014-07-17 | 2016-02-03 | Lg电子株式会社 | Mobile terminal and controlling method thereof |
CN105472469A (en) * | 2015-12-08 | 2016-04-06 | 小米科技有限责任公司 | Video playing progress adjusting method and apparatus |
CN106935254A (en) * | 2017-02-16 | 2017-07-07 | 珠海格力电器股份有限公司 | The display control method of media player progress bar, system and media player |
CN106990951A (en) * | 2017-02-22 | 2017-07-28 | 福建天泉教育科技有限公司 | The method for drafting and system of a kind of progress bar |
CN107122188A (en) * | 2017-04-26 | 2017-09-01 | 网易(杭州)网络有限公司 | The method and device of project process bar image generation |
CN107436766A (en) * | 2017-07-31 | 2017-12-05 | 北京酷我科技有限公司 | The Processing Algorithm of self-defined shape progress bar under a kind of Mac |
-
2017
- 2017-12-07 CN CN201711286785.3A patent/CN109901894B/en active Active
Patent Citations (11)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20100303450A1 (en) * | 2009-05-29 | 2010-12-02 | Nokia Corporation | Playback control |
WO2012106269A1 (en) * | 2011-01-31 | 2012-08-09 | Cbs Interactive, Inc. | Media playback control |
CN103577063A (en) * | 2012-07-23 | 2014-02-12 | Lg电子株式会社 | Mobile tmerinal and control method thereof |
CN104461479A (en) * | 2013-09-13 | 2015-03-25 | 腾讯科技(深圳)有限公司 | Timing method and device |
CN105306667A (en) * | 2014-07-17 | 2016-02-03 | Lg电子株式会社 | Mobile terminal and controlling method thereof |
CN105227830A (en) * | 2015-09-01 | 2016-01-06 | 上海由零网络科技有限公司 | A kind of method for processing video frequency and processing system for video |
CN105472469A (en) * | 2015-12-08 | 2016-04-06 | 小米科技有限责任公司 | Video playing progress adjusting method and apparatus |
CN106935254A (en) * | 2017-02-16 | 2017-07-07 | 珠海格力电器股份有限公司 | The display control method of media player progress bar, system and media player |
CN106990951A (en) * | 2017-02-22 | 2017-07-28 | 福建天泉教育科技有限公司 | The method for drafting and system of a kind of progress bar |
CN107122188A (en) * | 2017-04-26 | 2017-09-01 | 网易(杭州)网络有限公司 | The method and device of project process bar image generation |
CN107436766A (en) * | 2017-07-31 | 2017-12-05 | 北京酷我科技有限公司 | The Processing Algorithm of self-defined shape progress bar under a kind of Mac |
Cited By (21)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20220215494A1 (en) * | 2019-09-24 | 2022-07-07 | Nova Southeastern University | Systems and methods for mentoring students and facilitating their entry into healthcare professions |
CN111324404B (en) * | 2020-01-20 | 2023-11-24 | 北京有竹居网络技术有限公司 | Information acquisition progress display method and device, electronic equipment and readable medium |
CN111324404A (en) * | 2020-01-20 | 2020-06-23 | 北京无限光场科技有限公司 | Information acquisition progress display method and device, electronic equipment and readable medium |
CN111399736B (en) * | 2020-03-17 | 2021-09-21 | 腾讯科技(深圳)有限公司 | Progress bar control method, device and equipment and readable storage medium |
CN111399736A (en) * | 2020-03-17 | 2020-07-10 | 腾讯科技(深圳)有限公司 | Progress bar control method, device and equipment and readable storage medium |
CN111596853A (en) * | 2020-04-29 | 2020-08-28 | 五八有限公司 | Method and device for realizing rolling indicator, electronic equipment and storage medium |
CN112306616A (en) * | 2020-11-23 | 2021-02-02 | 北京百家科技集团有限公司 | Loading display processing method and device, computer equipment and storage medium |
CN112306616B (en) * | 2020-11-23 | 2023-09-29 | 北京百家科技集团有限公司 | Loading display processing method and device, computer equipment and storage medium |
CN112435308A (en) * | 2020-11-30 | 2021-03-02 | 成都新潮传媒集团有限公司 | Drawing method and device of annular progress bar and storage medium |
CN112435308B (en) * | 2020-11-30 | 2023-11-14 | 成都新潮传媒集团有限公司 | Drawing method and device of annular progress bar and storage medium |
CN112330773A (en) * | 2020-11-30 | 2021-02-05 | 广州博冠信息科技有限公司 | Countdown image generation method and device, electronic equipment and computer medium |
CN112579083A (en) * | 2020-12-09 | 2021-03-30 | 京东数字科技控股股份有限公司 | Image display method and device, electronic equipment and storage medium |
CN112544675A (en) * | 2020-12-23 | 2021-03-26 | 智锐达仪器科技南通有限公司 | Livestock carcass skin source tracing code spraying method, inkjet printer and control method |
CN112711417A (en) * | 2020-12-30 | 2021-04-27 | 上海铼锶信息技术有限公司 | Manufacturing method of progress bar and electronic equipment |
CN112949249A (en) * | 2021-02-20 | 2021-06-11 | 山东英信计算机技术有限公司 | Method, system and device for determining element placing position |
CN112949249B (en) * | 2021-02-20 | 2023-06-02 | 山东英信计算机技术有限公司 | Method, system and device for determining element placement position |
CN113961281A (en) * | 2021-08-13 | 2022-01-21 | 叮联信息技术有限公司 | Internet-based task progress display method and device |
CN113837019A (en) * | 2021-08-31 | 2021-12-24 | 北京新氧科技有限公司 | Cosmetic progress detection method, device, equipment and storage medium |
CN114071238A (en) * | 2021-11-12 | 2022-02-18 | 北京百度网讯科技有限公司 | Method, apparatus, device, medium and product for generating video progress bar |
WO2023173728A1 (en) * | 2022-03-16 | 2023-09-21 | 北京字跳网络技术有限公司 | Graphic rendering method and apparatus, and storage medium |
EP4270321A4 (en) * | 2022-03-16 | 2024-02-28 | Beijing Zitiao Network Technology Co Ltd | Graphic rendering method and apparatus, and storage medium |
Also Published As
Publication number | Publication date |
---|---|
CN109901894B (en) | 2021-06-08 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN109901894A (en) | A kind of progress bar image generating method, device and storage medium | |
CN107294838B (en) | Animation generation method, device and system for social application and terminal | |
Mackenzie | Wirelessness: Radical empiricism in network cultures | |
US10482660B2 (en) | System and method to integrate content in real time into a dynamic real-time 3-dimensional scene | |
CN109885367B (en) | Interactive chat implementation method, device, terminal and storage medium | |
CN108269110A (en) | Item recommendation method, system and user equipment based on community's question and answer | |
CN108525305A (en) | Image processing method, device, storage medium and electronic equipment | |
CN108702382A (en) | System and method for determining position | |
KR20230022983A (en) | Messaging system with external-resource dock and drawer | |
US20140253553A1 (en) | Visualization of three-dimensional models of objects in two-dimensional environment | |
CN109062779A (en) | Test control method, main control device, controlled device and test macro | |
KR20230125310A (en) | Avatar customization system | |
CN106512401A (en) | User interaction system | |
KR20230044213A (en) | Motion Expressions for Articulating Animation | |
KR20230031915A (en) | Third-Party Fixes to the Camera User Interface | |
CN113630557B (en) | Image processing method, apparatus, device, storage medium, and computer program product | |
WO2017190213A1 (en) | Dynamic motion simulation methods and systems | |
JP7004825B2 (en) | Methods and equipment for visualization of public welfare activities | |
CN111167119A (en) | Game development display method, device, equipment and storage medium | |
KR20240008902A (en) | VR-based connection portal shopping | |
KR20230079169A (en) | Turn-Based Collaborative Playlist | |
KR20230075508A (en) | QR Generation System for Augmented Reality Continuity | |
CN112270733A (en) | AR expression package generation method and device, electronic equipment and storage medium | |
JP2017010252A (en) | Information processing system, information processing device, program, and information processing device control method | |
CN112799552A (en) | Method and device for sharing promotion pictures and storage medium |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
GR01 | Patent grant | ||
GR01 | Patent grant |