CN104952097B - GIF animations real-time control method and system based on multiframe decomposition technique - Google Patents

GIF animations real-time control method and system based on multiframe decomposition technique Download PDF

Info

Publication number
CN104952097B
CN104952097B CN201510321517.5A CN201510321517A CN104952097B CN 104952097 B CN104952097 B CN 104952097B CN 201510321517 A CN201510321517 A CN 201510321517A CN 104952097 B CN104952097 B CN 104952097B
Authority
CN
China
Prior art keywords
frame
time
real
vernier
gif
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.)
Active
Application number
CN201510321517.5A
Other languages
Chinese (zh)
Other versions
CN104952097A (en
Inventor
杨波
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
HONGYOU SOFTWARE Co.,Ltd.
Original Assignee
KARAMAY HONGYOU SOFTWARE CO Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by KARAMAY HONGYOU SOFTWARE CO Ltd filed Critical KARAMAY HONGYOU SOFTWARE CO Ltd
Priority to CN201510321517.5A priority Critical patent/CN104952097B/en
Publication of CN104952097A publication Critical patent/CN104952097A/en
Application granted granted Critical
Publication of CN104952097B publication Critical patent/CN104952097B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Landscapes

  • Processing Or Creating Images (AREA)

Abstract

The invention discloses a kind of GIF animations real-time control methods and system based on multiframe decomposition technique, are related to GIF animations and play control technology field.The present invention is by the way that each frame in GIF animations is separated, and each frame separated continuously is put into according to its reproduction time in different queues, each queue corresponds to a time timer, control the broadcasting speed of each frame in individual queue in real time using time timer, the broadcasting of next frame is led into using the movement for playing vernier, the playing progress rate of control GIF animations in real time, so as to use technical solution provided in an embodiment of the present invention, it can realize the real-time adjustment control played to GIF animations, greatly improve the Experience Degree of user.

Description

GIF animations real-time control method and system based on multiframe decomposition technique
Technical field
Control technology field is played the present invention relates to GIF animations more particularly to a kind of GIF based on multiframe decomposition technique is moved Draw real-time control method and system.
Background technology
GIF animation files are made of numerous independent frames (image), the broadcasting of animation be substantially continuously to each frame into Row displaying, wherein each frame all records the reproduction time of the frame, when the playing interval between two frames is the broadcasting of former frame Between.By the reproduction time for controlling each frame, it is possible to control the playing interval of each frame, and then control broadcasting for entire GIF animations Put speed.
At present, tool image software (Photoshop, Office Picture generally are utilized before the broadcasting of GIF animations Manager the reproduction time of each frame (image)) is reset, so as to which the broadcasting speed of GIF animations be modified or controlled.
But the above method, it is before the broadcasting of GIF animations, it is necessary to the reproduction time of each frame is reset, It could realize the control to GIF animation broadcasting speeds, and GIF animations can not be broadcast according to user in GIF animation playing process The demand for control of speed is put, control adjustment is carried out to the reproduction time of some frame therein or certain frames, i.e., GIF animations are broadcast It puts speed and carries out adjustment control in real time.
In addition, it in the prior art, using tool image software, can only put in order before the broadcasting of GIF animations to frame Or quantity is adjusted, so as to fulfill to GIF animations playing progress rate (such as:The loop play of certain frames exits cycle, plays Pause, retract broadcastings, forward play etc.) adjustment, and GIF animations playing progress rate can not be carried out in real time in playing process Control adjustment.
Due to that in the prior art, can not realize the real-time adjustment control played to GIF animations, therefore, greatly reduce The Experience Degree of user.
Invention content
The purpose of the present invention is to provide a kind of GIF animations real-time control method and system based on multiframe decomposition technique, So as to solve foregoing problems in the prior art.
To achieve these goals, the technical solution adopted by the present invention is as follows:
A kind of GIF animation real-time control methods based on multiframe decomposition technique, include the following steps:
S1 detaches each frame of GIF animations, obtains each frame separated;
S2 reads the reproduction time of each frame separated;
S3 establishes multiple queues, according to putting in order for each frame, according to control frame granule size by it is continuously arranged, broadcast Time identical frame is put to be placed on same or be individually placed in multiple queues
S4 for each queue, sets the timer of reproduction time;
S5 adjusts the reproduction time of timer, completes the real-time control to GIF animation reproduction times in real time.
A kind of GIF animation real-time control methods based on multiframe decomposition technique, include the following steps:
S1 detaches each frame of GIF animations, obtains each frame separated;
S2 reads the reproduction time of each frame separated;
S3 establishes multiple queues, according to putting in order for each frame, according to control frame granule size by it is continuously arranged, broadcast Time identical frame is put to be placed on same or be individually placed in multiple queues;
S4 for each queue, sets the timer of reproduction time;
S5, setting play vernier, play vernier according to the reproduction time of timer and the movement of the tandem of queue, complete Real-time control to GIF animation playing progress rates.
Preferably, it is real to include advance, retrogressing, pause or loop play for the real-time control to GIF animation playing progress rates When control one or more of.
It is highly preferred that the method that the forward play controls in real time, is:Vernier is played from present frame to serial number to be more than currently The frame of frame number moves in real time.
It is highly preferred that described retreat the method for playing and controlling in real time, it is:Vernier is played from present frame to serial number to be less than currently The frame of frame number moves in real time.
It is highly preferred that the pause plays the method controlled in real time, it is:It plays vernier and stops movement.
It is highly preferred that the method that the loop play controls in real time, includes the following steps:
SA1 obtains the start frame and abort frame for needing loop play;
SA2 judges to play whether vernier is located at the abort frame, if it is, going to SA3, otherwise, goes to SA4;
SA3 when broadcasting vernier is located at the abort frame, judges whether to meet cycling condition, if it is, playing vernier Start frame is moved to, and goes to SA4;Otherwise, the next frame that vernier is moved to abort frame is played;
SA4 plays vernier and is moved to abort frame in sequence, and go to SA3.
It is highly preferred that the cycling condition includes one or more of circulation time, mouse action and cycle-index.
A kind of GIF animation real-time control systems based on multiframe decomposition technique, including:
Frame separation processing unit:For each frame of GIF animations to be detached, each frame separated is obtained;It is additionally operable to Read the reproduction time of each frame separated;
Frame queue unit:It, will be even according to control frame granule size according to putting in order for each frame for establishing multiple queues Continuous frame arranging, that reproduction time is identical is placed on same or is individually placed in multiple queues;
Timer unit:For being directed to each queue, the timer of reproduction time is set;
Real-time controlling unit:The reproduction time of adjustment timer in real time, completes the real-time control to GIF animation reproduction times System;It is additionally operable to setting and plays vernier, vernier, completion pair are played according to the reproduction time of timer and the movement of the tandem of queue The real-time control of GIF animation playing progress rates.
The beneficial effects of the invention are as follows:GIF animations provided in an embodiment of the present invention based on multiframe decomposition technique are controlled in real time Method and system processed, by the way that each frame in GIF animations is separated, and when each frame separated is played according to it Between be continuously put into different queues, each queue corresponds to a time timer, and every team is controlled in real time using time timer The broadcasting speed of each frame in row, the broadcasting of next frame is led into using the movement for playing vernier, controls GIF animations in real time Playing progress rate so as to use technical solution provided in an embodiment of the present invention, can realize the real-time adjustment control played to GIF animations System greatly improves the Experience Degree of user.
Description of the drawings
Fig. 1 is the result schematic diagram for separating each frame in GIF animations;
Fig. 2 is GIF animation broadcasting speed real-time control method schematic diagrames;
Fig. 3 is that GIF animations are retreated, advanced, pause plays real-time control method schematic diagram;
Fig. 4 is that GIF animation loops play real-time control method schematic diagram.
Specific embodiment
In order to make the purpose , technical scheme and advantage of the present invention be clearer, below in conjunction with attached drawing, to the present invention into Row is further described.It should be appreciated that the specific embodiments described herein are only used to explain the present invention, it is not used to Limit the present invention.
Embodiment one
As shown in Figs. 1-2, an embodiment of the present invention provides a kind of real-time controlling parties of GIF animations based on multiframe decomposition technique Method includes the following steps:
S1 detaches each frame of GIF animations, obtains each frame separated;
S2 reads the reproduction time of each frame separated;
S3 establishes multiple queues, according to putting in order for each frame, according to control frame granule size by it is continuously arranged, broadcast Time identical frame is put to be placed on same or be individually placed in multiple queues;
S4 for each queue, sets the timer of reproduction time;
S5 adjusts the reproduction time of timer, completes the real-time control to GIF animation reproduction times in real time.
As shown in Figure 1,6 frames of GIF animations are separated, the reproduction time of each frame is obtained, frame one and frame two are broadcast The time is put as 1, the reproduction time of frame three to frame five is 2, and the reproduction time of frame six is 1, then according to the reproduction time of each frame, Continuously arranged and identical reproduction time frame is placed in same queue, herein, two continuous arrangement of frame one and frame, and play Time is identical, therefore, as shown in Fig. 2, frame one and frame two are placed in queue one, frame three to five continuous arrangement of frame, and during broadcasting Between it is identical, therefore, frame three, frame four and frame five are placed in queue two, frame six is placed in queue three.Herein, it should be noted that It is that continuously arranged and identical time frame is placed in same queue, otherwise, is placed in different queues, for example, frame First, frame two and frame six are 1 although reproduction time is identical, due to frame six and frame two be not it is continuously arranged, no Frame six can be placed in queue one, and frame six should be individually placed in queue three.
After each frame is put into different queues, according to the reproduction time of frame in each queue, it is corresponding fixed to set When device, for example, the reproduction time of one corresponding timer of queue is 1, the reproduction time of two corresponding timer of queue is 2, team The reproduction time of three corresponding timer of row is 1.And the reproduction time of timer is can be carried out in fact according to user's actual need When adjust, so, the reproduction time of frame each in queue can be adjusted in real time.For example, user wants to extend frame one and frame Two reproduction time then, can increase the reproduction time of one corresponding timer of queue.
As it can be seen that by using the above method, the real-time control to GIF animation broadcasting speeds is realized.
Embodiment two
As shown in Figs 1-4, the embodiment of the present invention additionally provides a kind of GIF animations based on multiframe decomposition technique and controls in real time Method includes the following steps:
S1 detaches each frame of GIF animations, obtains each frame separated;
S2 reads the reproduction time of each frame separated;
S3 establishes multiple queues, according to putting in order for each frame, according to control frame granule size by it is continuously arranged, broadcast Time identical frame is put to be placed on same or be individually placed in multiple queues;
S4 for each queue, sets the timer of reproduction time;
S5, setting play vernier, play vernier according to the reproduction time of timer and the movement of the tandem of queue, complete Real-time control to GIF animation playing progress rates.
Wherein, it is real-time to include advance, retrogressing, pause or loop play for the real-time control to GIF animation playing progress rates One or more of control.
In a preferred embodiment of the invention, the method that the forward play controls in real time is:Play vernier from work as The frame that previous frame is more than current frame number to serial number moves in real time.
For example, it is currently located at the position of frame four in fig. 3, it is assumed that playing vernier, if user has the need of forward play It asks, wants to leap to frame six from frame four, frame six is shown, then can will play vernier and be moved at the position of frame six, it is real Now to the display of frame six.
In a preferred embodiment of the invention, it is described to retreat the method for playing and controlling in real time, be:Play vernier from work as The frame that previous frame is less than current frame number to serial number moves in real time.
For example, it is currently located at the position of frame four in fig. 3, it is assumed that playing vernier, if user has the need for retreating and playing It asks, wants to return back to frame two from frame four, frame two is shown, then can will play vernier and be moved at the position of frame two, realize Display to frame two.
In a preferred embodiment of the invention, the pause plays the method controlled in real time, is:Vernier is played to stop It is mobile.
For example, it is currently located at the position of frame four in fig. 3, it is assumed that playing vernier, if user has the need that pause plays It asks, wants GIF animations pausing at four position of frame, then can stop the mobile purpose for playing vernier, realizing pause.
In a preferred embodiment of the invention, the method that the loop play controls in real time, includes the following steps:
SA1 obtains the start frame and abort frame for needing loop play;
SA2 judges to play whether vernier is located at the abort frame, if it is, going to SA3, otherwise, goes to SA4;
SA3 when broadcasting vernier is located at the abort frame, judges whether to meet cycling condition, if it is, playing vernier Start frame is moved to, and goes to SA4;Otherwise, the next frame that vernier is moved to abort frame is played;
SA4 plays vernier and is moved to abort frame in sequence, and go to SA3.
The cycling condition includes one or more of circulation time, mouse action and cycle-index.
For example, in fig. 3, it is assumed that the broadcasting figure frame recycled is needed from second to the 5th, when the broadcasting of figure frame has shown the 5th After frame, play vernier and recall to the second frame, played since the second frame.Exit criteria is detected before each loop play, if moved back Go out condition satisfaction and then exit cycle (time, mouse action, cycle-index etc.), otherwise, recycle always, cycle is released until meeting Condition.
Embodiment three
An embodiment of the present invention provides a kind of GIF animation real-time control systems based on multiframe decomposition technique, including:
Frame separation processing unit:For each frame of GIF animations to be detached, each frame separated is obtained;It is additionally operable to Read the reproduction time of each frame separated;
Frame queue unit:It, will be even according to control frame granule size according to putting in order for each frame for establishing multiple queues Continuous frame arranging, that reproduction time is identical is placed on same or is individually placed in multiple queues;
Timer unit:For being directed to each queue, the timer of reproduction time is set;
Real-time controlling unit:The reproduction time of adjustment timer in real time, completes the real-time control to GIF animation reproduction times System;It is additionally operable to setting and plays vernier, vernier, completion pair are played according to the reproduction time of timer and the movement of the tandem of queue The real-time control of GIF animation playing progress rates.
The course of work of above system may refer to the description of embodiment one and embodiment two, and details are not described herein.
By using above-mentioned technical proposal disclosed by the invention, following beneficial effect has been obtained:The embodiment of the present invention carries The GIF animations real-time control method and system based on multiframe decomposition technique supplied, by the way that each frame in GIF animations is isolated Come, and each frame separated continuously is put into according to its reproduction time in different queues, each queue corresponds to for the moment Between timer, control the broadcasting speed of each frame in individual queue in real time using time timer, drawn using the movement for playing vernier The broadcasting into next frame is led, controls the playing progress rate of GIF animations in real time, so as to use technical side provided in an embodiment of the present invention Case can realize the real-time adjustment control played to GIF animations, greatly improve the Experience Degree of user.
Each embodiment in this specification is described by the way of progressive, the highlights of each of the examples are with The difference of other embodiment, just to refer each other for identical similar part between each embodiment.
Those skilled in the art should be understood that above-described embodiment provide method and step sequential can according to actual conditions into Row is adaptively adjusted, and also can concurrently be carried out according to actual conditions.
All or part of step in the method that above-described embodiment is related to can be instructed by program relevant hardware come It completes, the program can be stored in the storage medium that computer equipment can be read, for performing the various embodiments described above side All or part of step described in method.The computer equipment, such as:Personal computer, server, the network equipment, intelligent sliding Dynamic terminal, smart home device, wearable intelligent equipment, vehicle intelligent equipment etc.;The storage medium, such as:RAM、 ROM, magnetic disc, tape, CD, flash memory, USB flash disk, mobile hard disk, storage card, memory stick, webserver storage, network cloud storage Deng.
Finally, it is to be noted that, herein, relational terms such as first and second and the like be used merely to by One entity or operation are distinguished with another entity or operation, without necessarily requiring or implying these entities or operation Between there are any actual relationship or orders.Moreover, term " comprising ", "comprising" or its any other variant meaning Covering non-exclusive inclusion, so that process, method, commodity or equipment including a series of elements not only include that A little elements, but also including other elements that are not explicitly listed or further include for this process, method, commodity or The intrinsic element of equipment.In the absence of more restrictions, the element limited by sentence "including a ...", is not arranged Except also there are other identical elements in the process including the element, method, commodity or equipment.
The above is only the preferred embodiment of the present invention, it is noted that for the ordinary skill people of the art For member, various improvements and modifications may be made without departing from the principle of the present invention, these improvements and modifications also should Depending on protection scope of the present invention.

Claims (2)

1. a kind of GIF animation real-time control methods based on multiframe decomposition technique, which is characterized in that include the following steps:
S1 detaches each frame of GIF animations, obtains each frame separated;
S2 reads the reproduction time of each frame separated;
S3 establishes multiple queues, according to putting in order for each frame, according to control frame granule size by it is continuously arranged, play when Between identical frame be placed on same or be individually placed in multiple queues;
S4 for each queue, sets the timer of reproduction time;
S5, setting play vernier, and vernier, completion pair are played according to the reproduction time of timer and the movement of the tandem of queue The real-time control of GIF animation playing progress rates;
The real-time control to GIF animation playing progress rates includes one in the control in real time of advance, retrogressing, pause or loop play Kind is several;
The method that the forward play controls in real time is:It is real more than the frame of current frame number from present frame to serial number to play vernier Shi Yidong;
It is described to retreat the method for playing and controlling in real time, be:It is real less than the frame of current frame number from present frame to serial number to play vernier Shi Yidong;
The pause plays the method controlled in real time, is:It plays vernier and stops movement;
The method that the loop play controls in real time, includes the following steps:
SA1 obtains the start frame and abort frame for needing loop play;
SA2 judges to play whether vernier is located at the abort frame, if it is, going to SA3, otherwise, goes to SA4;
SA3 when broadcasting vernier is located at the abort frame, judges whether to meet cycling condition, if it is, playing vernier movement To start frame, and go to SA4;Otherwise, the next frame that vernier is moved to abort frame is played;
SA4 plays vernier and is moved to abort frame in sequence, and go to SA3;
The cycling condition includes one or more of circulation time, mouse action and cycle-index.
2. a kind of GIF animation real-time control systems based on multiframe decomposition technique, which is characterized in that including:
Frame separation processing unit:For each frame of GIF animations to be detached, each frame separated is obtained;It is additionally operable to read The reproduction time of each frame separated;
Frame queue unit:For establishing multiple queues, according to putting in order for each frame, will continuously be arranged according to control frame granule size Frame arrange, that reproduction time is identical is placed on same or is individually placed in multiple queues;
Timer unit:For being directed to each queue, the timer of reproduction time is set;
Real-time controlling unit:The reproduction time of adjustment timer in real time, completes the real-time control to GIF animation reproduction times;Also Vernier is played for setting, vernier is played according to the reproduction time of timer and the movement of the tandem of queue, completes to move GIF Draw the real-time control of playing progress rate.
CN201510321517.5A 2015-06-11 2015-06-11 GIF animations real-time control method and system based on multiframe decomposition technique Active CN104952097B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201510321517.5A CN104952097B (en) 2015-06-11 2015-06-11 GIF animations real-time control method and system based on multiframe decomposition technique

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201510321517.5A CN104952097B (en) 2015-06-11 2015-06-11 GIF animations real-time control method and system based on multiframe decomposition technique

Publications (2)

Publication Number Publication Date
CN104952097A CN104952097A (en) 2015-09-30
CN104952097B true CN104952097B (en) 2018-06-15

Family

ID=54166723

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201510321517.5A Active CN104952097B (en) 2015-06-11 2015-06-11 GIF animations real-time control method and system based on multiframe decomposition technique

Country Status (1)

Country Link
CN (1) CN104952097B (en)

Families Citing this family (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106385635B (en) * 2016-09-18 2019-08-27 福建天泉教育科技有限公司 GIF animation real-time control method and player
CN108401179B (en) * 2018-04-02 2019-05-17 广州荔支网络技术有限公司 A kind of animation playing method based on virtual objects, device and mobile terminal
CN108765523B (en) * 2018-05-30 2022-08-16 武汉斗鱼网络科技有限公司 Animation realization method, device, server and storage medium for advertisement with pause function
CN110968378A (en) * 2018-09-29 2020-04-07 北京字节跳动网络技术有限公司 GIF animation operation method, device, electronic equipment and storage medium
CN111443914B (en) * 2020-03-30 2023-07-14 北京字节跳动网络技术有限公司 Animation display method and device

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102520864A (en) * 2011-12-16 2012-06-27 北京新媒传信科技有限公司 Method for continuously playing images and device
CN104519404A (en) * 2013-09-29 2015-04-15 北京新媒传信科技有限公司 Graphics interchange format file playing method and device

Family Cites Families (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR20050007739A (en) * 2003-07-11 2005-01-21 엘지전자 주식회사 Method for setting time interval between frames of animated gif
US20060072166A1 (en) * 2004-09-24 2006-04-06 Nikon Corporation Image processing device, method and program
JP2009260796A (en) * 2008-04-18 2009-11-05 Canon Inc Information processing method, information processing unit, and program

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102520864A (en) * 2011-12-16 2012-06-27 北京新媒传信科技有限公司 Method for continuously playing images and device
CN104519404A (en) * 2013-09-29 2015-04-15 北京新媒传信科技有限公司 Graphics interchange format file playing method and device

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
PPT中部分页面循环播放;灰色的风;《http://huisefeng.lofter.com/post/14b604_1111216#》;20130715;第1-3页 *

Also Published As

Publication number Publication date
CN104952097A (en) 2015-09-30

Similar Documents

Publication Publication Date Title
CN104952097B (en) GIF animations real-time control method and system based on multiframe decomposition technique
CN103686418B (en) The method and electronic equipment of a kind of information processing
EP3758363A1 (en) Video production method and apparatus, computer device and storage medium
CN104660948B (en) A kind of video recording method and device
TWI672044B (en) Subtitle data processing method and system
CN107659825A (en) Method, apparatus, server, main broadcaster end and the medium that a kind of live video is retained
CN104699386B (en) A kind of method and device for adjusting playing progress rate
CN106385635B (en) GIF animation real-time control method and player
CN104038834A (en) Video positioning method and device
CN106611412A (en) Map video generation method and device
CN106162298B (en) Method and system for realizing bullet screen
CN103607657A (en) Method and device for realizing picture-in-picture playing function
CN111432260A (en) Method, device and equipment for synchronizing multiple paths of video pictures and storage medium
CN106412708A (en) Video screenshot method and video screenshot device
CN106454151A (en) Video image stitching method and device
CN108271432B (en) Video recording method and device and shooting equipment
CN107728905A (en) A kind of barrage display methods, device and storage medium
CN104461718A (en) Frame playing method and client end for game application
CN105142029B (en) The editing system and its clipping method of a kind of interdynamic video
CN105554523A (en) Live channel-based information interaction method and server
CN107438839A (en) A kind of multimedia editing method, device and intelligent terminal
CN103187082A (en) Information processing apparatus, information processing method and program
CN108337471A (en) The processing method and processing device of video pictures
CN107479872A (en) Android animation collections player method, storage medium, electronic equipment and system
CN108737903A (en) A kind of multimedia processing system and multi-media processing method

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
CP03 Change of name, title or address

Address after: 834000 Jiyun Road, Karamay District, Karamay City, Xinjiang Uygur Autonomous Region, 197-2

Patentee after: HONGYOU SOFTWARE Co.,Ltd.

Address before: 834000 No. 22, long march road, the Xinjiang Uygur Autonomous Region, Karamay

Patentee before: KARAMAY HONGYOU SOFTWARE Co.,Ltd.

CP03 Change of name, title or address