CN107340964A - The animation effect implementation method and device of a kind of view - Google Patents
The animation effect implementation method and device of a kind of view Download PDFInfo
- Publication number
- CN107340964A CN107340964A CN201710406260.2A CN201710406260A CN107340964A CN 107340964 A CN107340964 A CN 107340964A CN 201710406260 A CN201710406260 A CN 201710406260A CN 107340964 A CN107340964 A CN 107340964A
- Authority
- CN
- China
- Prior art keywords
- view
- gesture
- offset distance
- animation effect
- event
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Pending
Links
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F3/00—Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
- G06F3/01—Input arrangements or combined input and output arrangements for interaction between user and computer
- G06F3/048—Interaction techniques based on graphical user interfaces [GUI]
- G06F3/0487—Interaction techniques based on graphical user interfaces [GUI] using specific features provided by the input device, e.g. functions controlled by the rotation of a mouse with dual sensing arrangements, or of the nature of the input device, e.g. tap gestures based on pressure sensed by a digitiser
- G06F3/0488—Interaction techniques based on graphical user interfaces [GUI] using specific features provided by the input device, e.g. functions controlled by the rotation of a mouse with dual sensing arrangements, or of the nature of the input device, e.g. tap gestures based on pressure sensed by a digitiser using a touch-screen or digitiser, e.g. input of commands through traced gestures
- G06F3/04883—Interaction techniques based on graphical user interfaces [GUI] using specific features provided by the input device, e.g. functions controlled by the rotation of a mouse with dual sensing arrangements, or of the nature of the input device, e.g. tap gestures based on pressure sensed by a digitiser using a touch-screen or digitiser, e.g. input of commands through traced gestures for inputting data by handwriting, e.g. gesture or text
Landscapes
- Engineering & Computer Science (AREA)
- General Engineering & Computer Science (AREA)
- Theoretical Computer Science (AREA)
- Human Computer Interaction (AREA)
- Physics & Mathematics (AREA)
- General Physics & Mathematics (AREA)
- User Interface Of Digital Computer (AREA)
- Processing Or Creating Images (AREA)
Abstract
The present invention provides a kind of the animation effect implementation method and device of view, and applied to touch type terminal, methods described includes:S1, monitor the gesture operation event of touch type terminal top view;S2, the mapping relations between offset distance and gesture slip offset distance and view animation effect parameter are slided according to the gesture to view, obtain view animation effect parameter;S3, according to the view animation effect parameter, animated show is carried out to view.The present invention is directed to the dynamic effect demand of product in client, it is proposed that a set of elastic animation effect implementation method based on gesture, can assign a kind of inertia special efficacy of physics of animation effect so that animation is more true to nature and true.
Description
Technical field
The present invention relates to view cartoon technique field, a kind of animation effect implementation method more particularly, to view and
Device.
Background technology
In the view development process of client, animation effect is often used, common practice is at present, with system
Existing animation effect sets the animation effect of each view, such as a view to fly into the mode of screen in system, rotates
Fly into or scaling is flown into.
For different animation effects, it is necessary to set repeatedly dynamic effect efficacy parameter to same view, can so operate numerous
It is trivial, operating efficiency is influenceed, while during being configured to the animation effect parameter of view, belong to zero with user and interacted
Journey, the experience property of user are poor.
The content of the invention
The present invention provides a kind of animation effect for the view for overcoming above mentioned problem or solving the above problems at least in part
Implementation method and device.
According to the first aspect of the invention, there is provided a kind of animation effect implementation method of view, it is whole applied to touch type
End, including:
S1, monitor the gesture operation event of touch type terminal top view;
S2, offset distance is slided according to the gesture to view and gesture slides offset distance and view animation effect parameter
Between mapping relations, obtain view animation effect parameter;
S3, according to the view animation effect parameter, animated show is carried out to view.
Beneficial effects of the present invention are:For the dynamic effect demand of product in client, it is proposed that a set of bullet based on gesture
Property animation effect implementation method, according to the gesture operation to view, different animation effects is assigned to view so that animation is more
It is true to nature and true.
On the basis of above-mentioned technical proposal, the present invention can also improve as follows.
Further, the gesture operation event presses event, gesture slip event and gesture including gesture and lifts event;
Calculated in the following way in the step S2 and offset distance is slided to the gesture of view:
S21a, monitor gesture and press event, record presses transverse and longitudinal coordinate (Ax, Ay) a little;
S22a, monitor gesture slip event, the transverse and longitudinal coordinate for the finger current location being recorded in gesture sliding process
(Ex, Ey);
S23a, the slip offset distance Δ x=Ex-Ax of transverse axis and the slip offset distance Δ y=Ey- of the longitudinal axis are obtained respectively
Ay, offset distance is slided using the greater in Δ x and Δ y as the gesture to view.
Further, established in the following way in the step S2 and the gesture slip offset distance and view of view are moved
Draw the mapping relations between efficacy parameter:
S21b, detection gesture lift event, and record lifts transverse and longitudinal coordinate a little;
S22b, transverse and longitudinal coordinate a little is pressed according to gesture and lifts transverse and longitudinal coordinate a little, determines gesture slip offset distance
Span;
S23b, the span of offset distance and taking for default view animation effect parameter are slided according to the gesture of determination
It is worth scope, the mapping relations established between gesture slip offset distance and view animation effect parameter.
Further, the step S22b is specifically included:
If it is (Gx, Gy) to lift transverse and longitudinal coordinate a little, the gesture for obtaining transverse axis respectively slides offset distance Δ x'=Gx-Ax
Offset distance Δ y'=Gy-Ay is slided with the gesture of the longitudinal axis, the higher value in Δ x' and Δ y' determines that gesture slides skew
The span of distance.
Further, the animation effect parameter includes view scaling and view perspective.
Further, default view scaling P span is 0 < P≤1.1, the view perspective T
Span be 0 < T≤1.
Further, it is curve of order 2 relation that the gesture, which is slided between offset distance and view scaling, the hand
It is first-order linear relation that gesture, which is slided between offset distance and view perspective,.
Further, the step S3 is specifically included:
In gesture in the sliding process of view, the view according to corresponding to obtaining current gesture slip offset distance contracts in real time
Ratio and transparency are put, animated show is carried out to view;Or
When listening to gesture and lifting event, gesture when being lifted according to gesture slides offset distance, obtain corresponding to regard
Figure scaling and transparency, animated show is carried out to view.
According to an aspect of the invention, there is provided a kind of animation effect realization device of view, including:
Module is monitored, for monitoring the gesture operation event of touch type terminal top view;
Acquisition module, for being moved according to the gesture slip offset distance to view and gesture slip offset distance and view
The mapping relations between efficacy parameter are drawn, obtain view animation effect parameter;
Display module, for according to the view animation effect parameter, animated show to be carried out to view.
According to the third aspect, the equipment of the animation effect implementation method of a kind of view, it is characterised in that including processor
(processor), memory (memory) and bus;
The processor and memory complete mutual communication by the bus;
The memory storage has and by the programmed instruction of the computing device, the processor described program can be called to refer to
Order is able to carry out following method:
Monitor the gesture operation event of touch type terminal top view;Offset distance and hand are slided according to the gesture to view
Gesture slides the mapping relations between offset distance and view animation effect parameter, obtains view animation effect parameter;According to described
View animation effect parameter, animated show is carried out to view.
Brief description of the drawings
Fig. 1 is the animation effect implementation method flow chart of the view in one embodiment of the invention;
Fig. 2 is that the gesture of one embodiment of the invention slides the mapping relations curve between offset distance and view pantograph ratio
Figure;
Fig. 3 is that the gesture of one embodiment of the invention slides the mapping relations curve between offset distance and view perspective
Figure;
Fig. 4 is that the animation effect realization device of the view of another embodiment of the present invention connects block diagram;
Fig. 5 is the integrated connection block diagram of the animation effect realization device for the view that the present invention has one embodiment;
Fig. 6 is that the equipment of the animation effect implementation method of the view of another embodiment of the invention connects block diagram.
Embodiment
With reference to the accompanying drawings and examples, the embodiment of the present invention is described in further detail.Implement below
Example is used to illustrate the present invention, but is not limited to the scope of the present invention.
Referring to Fig. 1, Fig. 1 provides a kind of animation effect implementation method of view, being capable of basis applied to touch type terminal
User assigns view different animation effects so that view animation is more life-like and true the gesture operation event of view.Should
Method includes:S1, monitor the gesture operation event of touch type terminal top view;S2, offset distance is slided according to the gesture to view
From and gesture slide mapping relations between offset distance and view animation effect parameter, obtain view animation effect parameter;
S3, according to the view animation effect parameter, animated show is carried out to view.
When user wishes that view shows different animation effects, gesture behaviour can be carried out to the view on touch-screen
Make, touch type terminal therein can be touch type mobile phone or touch type computer etc..When touch type terminal is detected on view
Gesture operation event when, according to user during to view operation, offset distance is slided to the gesture of view, and in advance
The gesture first established slides the mapping relations between offset distance and view animation effect parameter, obtains sliding skew with gesture
Apart from corresponding animation effect parameter.Then, according to view animation effect parameter, the exhibition to view realization difference animation effect
Show.
The present embodiment is directed to the dynamic effect demand of view in client, it is proposed that a set of elastic animation effect based on gesture is real
Existing method, according to the gesture operation to view, different animation effects is assigned to view so that animation is more true to nature and true.
In one embodiment of the invention, the gesture operation event presses event, gesture slip event including gesture
Event is lifted with gesture.
Calculated in the following way in the step S2 and offset distance is slided to the gesture of view:S21a, monitor gesture and press
Lower event, record press transverse and longitudinal coordinate (Ax, Ay) a little;S22a, gesture slip event is monitored, is recorded in gesture sliding process
Current location transverse and longitudinal coordinate (Ex, Ey);S23a, the slip offset distance Δ x=Ex-Ax and the longitudinal axis of transverse axis are obtained respectively
Offset distance Δ y=Ey-Ay is slided, offset distance is slided using the greater in Δ x and Δ y as the gesture to view.
During user carries out gesture operation to the view in touch type terminal, the gesture operation event difference of user
Event, gesture slip event and gesture, which are pressed, including gesture lifts event.In the present embodiment, the gestures detection to view is whole
The basis of individual animation effect, the acquisition of subsequent animation efficacy parameter are all based on gesture change to carry out.Hand in this programme
The detection of gesture change is monitored by the onTouch methods for the system of making carbon copies, and onTouch methods can return to current gesture
The event information of operation, current gesture state is judged by the operation event information of gesture.
During user is operated by gesture to view, such as, when being zoomed in and out to view, typically two
Root finger is scratched or collapsed, the relative distance pressed a little of the distance that two fingers are scratched or collapsed under normal conditions
When it is equal, therefore, for convenience, user is to press in the acquisition to the coordinate position during view operation to this programme
Centered on point, the coordinate of a finger is detected come what is subsequently calculated, i.e., following coordinates each means one of finger
Coordinate.Within a particular process, press event by monitoring gesture on view, and record press a little transverse and longitudinal coordinate (Ax,
Ay), a starting point slided as gesture will be pressed.Gesture slip event is monitored, and is recorded in gesture sliding process, finger
Current location transverse and longitudinal coordinate (Ex, Ey).The slip offset distance Δ x=Ex-Ax and the longitudinal axis of transverse axis slip are obtained respectively
Offset distance Δ y=Ey-Ay, and using the greater in Δ x and Δ y as slip offset distance of the gesture to view.Wherein, select
Take the greater in Δ x and Δ y to slide offset distance as gesture, be because being possible to when sliding on horizontally and vertically
Gesture slide offset distance it is unequal, in order to embody user gesture slip this action, so taking the greater conduct
Gesture of the user in touch type terminal slides offset distance, if both are equal, takes arbitrary value in both.
In another embodiment of the present invention, the gesture slip to view is established in the step S2 in the following way
Mapping relations between offset distance and view animation effect parameter:S21b, monitor gesture and lift event, record lifts horizontal stroke a little
Ordinate;S22b, transverse and longitudinal coordinate a little is pressed according to gesture and lifts transverse and longitudinal coordinate a little, determines gesture slip offset distance
Span;S23b, the span of offset distance and default view animation effect parameter are slided according to the gesture of determination
Span, design gesture slide the mapping relations between offset distance and view animation effect parameter.
After the above-mentioned gesture that have detected user presses event and gesture slip event, and the transverse and longitudinal pressed a little according to gesture is sat
The transverse and longitudinal coordinate of current location in mark and gesture sliding process, user is calculated and offset distance is slided to the gesture of view.
Then, then detection gesture lifts event, and records the transverse and longitudinal coordinate (Gx, Gy) lifted a little, is sat according to the transverse and longitudinal that gesture is pressed a little
Mark (Ax, Ay) and transverse and longitudinal coordinate (Gx, Gy) a little is lifted, determine the span of gesture slip offset distance.The present embodiment
Always according to the span of real needs Design view animation effect parameter, slide the span of offset distance in gesture and regard
Under conditions of the span of figure animation effect parameter is satisfied by, design gesture slides offset distance and view animation effect parameter
Between corresponding relation.During actual user slides to gesture, offset distance and the corresponding relation are slided according to gesture,
It can be obtained by view animation effect parameter.
In one embodiment of the invention, transverse and longitudinal coordinate a little is pressed according to gesture in the step S22b and lifted a little
Transverse and longitudinal coordinate, determine gesture slide offset distance span specifically include:If lift transverse and longitudinal coordinate a little for (Gx,
Gy), the gesture for obtaining transverse axis respectively slides the gesture slip deviation range Δ y'=of deviation range Δ x'=Gx-Ax and the longitudinal axis
Gy-Ay, the higher value in Δ x' and Δ y' determine that gesture slides the span of offset distance.
Detected in above-described embodiment and have recorded the transverse and longitudinal coordinate (Ax, Ay) of finger down point and transverse and longitudinal that finger lifts
Coordinate (Gx, Gy), the gesture of the transverse and longitudinal coordinate then lifted according to the transverse and longitudinal coordinate of finger down and finger, respectively calculating transverse axis
The gesture for sliding deviation range Δ x'=Gx-Ax and the longitudinal axis slides deviation range Δ y'=Gy-Ay, according in Δ x' and Δ y'
Higher value determines that gesture slides the span of offset distance, wherein, the span that gesture slides offset distance is 0~max
(| Δ x'|, | Δ y'|).
In one embodiment of the invention, the animation effect parameter includes view scaling and view perspective;
The view scaling P pre-set span is 0 < P≤1.1, and view perspective T span is 0 < T≤1.
In the present embodiment, described view animation effect parameter is primarily referred to as view scaling and view perspective,
Can according to user to during the gesture operation of view gesture slide offset distance, obtain scaling corresponding to view and thoroughly
Lightness, and according to view scaling and transparency, to the view corresponding scaling of progress and the animation effect of corresponding transparency
Displaying.In the present embodiment, view scaling P span is designed as 0 <≤1.1, wherein, why Design view contracts
The maximum for putting ratio is 1.1, is to realize inertia effect physically, i.e. animation arrives a small mistake again from small to large
Journey, respective view pantograph ratio from 0 to 1.1 again to 1 process, give people a kind of experience of the flexible effect of animation, that is, institute
The physics inertia effect of meaning.And view perspective T span is 0 < T≤1, view perspective and view scaling are not
Equally, the animation effect of a zoom is had when view scales, but the change of transparency is not need this spy of inertia
Effect, therefore, it is designed as 0 to 1.
In another embodiment of the present invention, it is two that the gesture, which is slided between offset distance and view scaling value,
Rank curved line relation, it is linear relationship that the gesture, which is slided between offset distance and view perspective,.
The mapping relations between gesture slip offset distance and view animation effect parameter are described in the above-described embodiments
It is that the span of offset distance and the span of view animation effect parameter are slided according to gesture to determine.By above-mentioned
Embodiment understands that the span that gesture slides offset distance is 0~max (| Δ x'|, | Δ y'|), and the view scaling designed
The span of ratio is 0 to 1.1, and because the acceleration that user slides on view is different, therefore, the present embodiment designs
The mapping relations slided between offset distance and view scaling of gesture be curve of order 2 relational expression, curve of order 2 relational expression
It can be designed as following functional equation:
Y=ax2+bx+c;
Wherein, a, b, c are constant, and x is that gesture slides offset distance, and span is 0~max (| Δ x'|, | Δ y'|),
Y span is 0 to 1.1, wherein, not including 0.For ease of understanding, the functional relation figure of design can be found in Fig. 2, wherein,
X1 to X2 is the span domain of X-axis, and what Y-axis represented is the value of view scaling, and the span of Y-axis arrives for 0
1.1.Under conditions of meeting that gesture slides the span of offset distance and the span of view scaling, can first it draw
Go out a curve of order 2, then according to 3 points on the curve of order 2, you can obtain constant factor a, b and c, and then obtain specific
Functional relation, i.e. gesture slides the Function Mapping relational expression between offset distance and view scaling.
Likewise, the mapping relations between offset distance and view perspective are slided for gesture, in the present embodiment, depending on
Linear relationship when between figure transparency and gesture slip offset distance, the gesture that can be designed slides offset distance and view is transparent
Function Mapping relational expression between degree is:
Y=dx+e;
Wherein, d and e is constant, and x is that gesture slides offset distance, and span is 0~max (| Δ x'|, | Δ y'|), y
For view perspective, y span is 0 to 1, wherein, not including 0.For ease of understanding, the functional relation figure of design can join
See Fig. 3, the span of X-axis is X1 to X2, and the span of corresponding Y-axis is 0 to 1, and variation relation is linear changing relation.
Under conditions of meeting that gesture slides the span of offset distance and the span of view perspective, Ke Yixian
Straight line is made according to real needs, then according to a point on straight line, you can obtain constant factor d and e, and then obtain
Specific functional relation, i.e. gesture slide the Function Mapping relational expression between offset distance and view perspective.
Mapping relations between gesture slip offset distance and view scaling are devised by above-mentioned method, and
Devise gesture and slide mapping relations between offset distance and view perspective, it is established that view scaling and transparency
The relation between offset distance is slided with gesture.
In another embodiment of the present invention, the step S3 is specifically included:In gesture in the sliding process of view,
View scaling and transparency according to corresponding to obtaining current gesture slip offset distance in real time, animation exhibition is carried out to view
Show;Or when listening to gesture and lifting event, gesture when being lifted according to gesture slides offset distance, obtain corresponding to regard
Figure scaling and transparency, animated show is carried out to view.
Gesture has been obtained in above-described embodiment to slide between offset distance and view scaling and view perspective
Mapping relations, during user carries out gesture slip to view, offset distance can be slided according to real-time gesture and be regarded
Scheme real-time scaling and real-time transparent degree, the present embodiment carries out animation according to view scaling and transparency to view
Displaying.It is Anima1 by scaling cartoon mark, is Anima2 by transparency cartoon mark, the sliding process in gesture to view
In, view scaling and view perspective according to corresponding to obtaining current gesture slip offset distance, are carried out to view in real time
Animated show.Or when listening to gesture and lifting event, gesture when being lifted according to gesture slides offset distance, obtain pair
The view scaling and view perspective answered, animated show is carried out to view.
In order that the animation effect for obtaining Anima1 and Anima2 is opened simultaneously, the AinmationSet that can be used
Class, by AinmationSet, this tool-class can open different animation effects to same view.Specifically call
Anima1 and Anima2 animations are added in AinmationSet by the add methods in AinmationSet classes, then recall
Start methods in AinmationSet, it becomes possible to while perform Anima1 and Anima2 animations.
Referring to Fig. 4, there is provided the animation effect realization device of the view of another embodiment of the present invention, including monitor module
21st, acquisition module 22 and display module 23.
Wherein, module 21 is monitored, for monitoring the gesture operation event of touch screen terminal top view;
Acquisition module 22, for sliding offset distance and gesture slip offset distance and view according to the gesture to view
Mapping relations between animation effect parameter, obtain view animation effect parameter;
Display module 23, for according to the view animation effect parameter, animated show to be carried out to view.
Referring to Fig. 5, the animation effect realization device of view also includes computing module 24, determining module 25 and establishes module
26。
Module 21 is monitored, monitoring gesture is additionally operable to and presses event, and record the transverse and longitudinal coordinate (Ax, Ay) pressed a little;And
Monitor gesture slip event, and the transverse and longitudinal coordinate (Ex, Ey) for the current location being recorded in gesture sliding process.
Computing module 24, for calculating the slip offset distance Δ x=Ex-Ax of transverse axis and the slip offset distance of the longitudinal axis respectively
From Δ y=Ey-Ay, using the greater in Δ x and Δ y as slip offset distance of the gesture to view.
Module 21 is monitored, monitoring gesture is additionally operable to and lifts event, record lifts transverse and longitudinal coordinate a little.
Determining module 25, for pressing transverse and longitudinal coordinate a little according to gesture and lifting transverse and longitudinal coordinate a little, determine gesture cunning
The span of dynamic offset distance.
Module 26 is established, the span and default view animation for sliding offset distance according to the gesture of determination are imitated
The span of fruit parameter, the mapping relations established between gesture slip offset distance and view animation effect parameter.
The determining module 25, the gesture for being additionally operable to calculate transverse axis respectively slide offset distance Δ x'=Gx-Ax and the longitudinal axis
Gesture slide offset distance Δ y'=Gy-Ay, the higher value in Δ x' and Δ y' determines that gesture slides offset distance
Span, wherein, the transverse and longitudinal coordinate lifted a little is (Gx, Gy).
Described display module 23, is specifically used for:
In gesture in the sliding process of view, the view according to corresponding to obtaining current gesture slip offset distance contracts in real time
Ratio and transparency are put, animated show is carried out to view;Or
When listening to gesture and lifting event, gesture when being lifted according to gesture slides offset distance, obtain corresponding to regard
Figure scaling and transparency, animated show is carried out to view.
Fig. 6 shows the structured flowchart of the equipment of the animation effect implementation method of the view of the embodiment of the present application.
Reference picture 6, the equipment of the animation effect implementation method of the view, including:Processor (processor) 601, deposit
Reservoir (memory) 602 and bus 603;Wherein, the processor 601 and memory 602 are completed mutually by the bus 603
Between communication.
The processor 601 is used to call the programmed instruction in the memory 602, to perform above-mentioned each method embodiment
The method provided, such as including:Monitor the gesture operation event of touch type terminal top view;According to the gesture slip to view
Offset distance and gesture slide the mapping relations between offset distance and view animation effect parameter, obtain view animation effect
Parameter;According to the view animation effect parameter, animated show is carried out to view.
The present embodiment discloses a kind of computer program product, and the computer program product includes being stored in non-transient calculating
Computer program on machine readable storage medium storing program for executing, the computer program include programmed instruction, when described program instruction is calculated
When machine performs, computer is able to carry out the method that above-mentioned each method embodiment is provided, such as including:Monitor in touch type terminal
The gesture operation event of view;Offset distance is slided according to the gesture to view and gesture slides offset distance and view animation
Mapping relations between efficacy parameter, obtain view animation effect parameter;According to the view animation effect parameter, view is entered
Action picture display.
The present embodiment provides a kind of non-transient computer readable storage medium storing program for executing, the non-transient computer readable storage medium storing program for executing
Computer instruction is stored, the computer instruction makes the computer perform the method that above-mentioned each method embodiment is provided, example
Such as include:Monitor the gesture operation event of touch type terminal top view;Offset distance and hand are slided according to the gesture to view
Gesture slides the mapping relations between offset distance and view animation effect parameter, obtains view animation effect parameter;According to described
View animation effect parameter, animated show is carried out to view.
One of ordinary skill in the art will appreciate that:Realizing all or part of step of above method embodiment can pass through
Programmed instruction related hardware is completed, and foregoing program can be stored in a computer read/write memory medium, the program
Upon execution, the step of execution includes above method embodiment;And foregoing storage medium includes:ROM, RAM, magnetic disc or light
Disk etc. is various can be with the medium of store program codes.
The embodiments such as the equipment of animation effect implementation method of view described above are only schematical, wherein making
The unit illustrated for separating component can be or may not be physically separate, can be as the part that unit is shown
Or it may not be physical location, you can with positioned at a place, or can also be distributed on multiple NEs.Can be with
Some or all of module therein is selected to realize the purpose of this embodiment scheme according to the actual needs.The common skill in this area
Art personnel are not in the case where paying performing creative labour, you can to understand and implement.
Through the above description of the embodiments, those skilled in the art can be understood that each embodiment can
Realized by the mode of software plus required general hardware platform, naturally it is also possible to pass through hardware.Based on such understanding, on
The part that technical scheme substantially in other words contributes to prior art is stated to embody in the form of software product, should
Computer software product can store in a computer-readable storage medium, such as ROM/RAM, magnetic disc, CD, including some fingers
Make to cause a computer equipment (can be personal computer, server, or network equipment etc.) to perform each implementation
Some Part Methods of example or embodiment.
A kind of view cartoon implementing method and device provided by the invention, the gesture in touch type terminal is grasped by monitoring
Make event, and the two sets of mapping relations established between gesture slip offset distance and the pantograph ratio and transparency of view, by two sets
Mapping relations are combined, while are realized to the pantograph ratio of view and the animation effect of transparency, so as to reach needed for view
The elastic animation effect with physics special efficacy wanted, by dexterously establishing the mapping relations between gesture and dynamic effect so as to greatly
Ground improves the usage experience of user and the friendly of program man-machine interaction.
Finally, the present processes are only preferable embodiment, are not intended to limit the scope of the present invention.It is all
Within the spirit and principles in the present invention, any modification, equivalent substitution and improvements made etc., the protection of the present invention should be included in
Within the scope of.
Claims (10)
- A kind of 1. animation effect implementation method of view, it is characterised in that applied to touch type terminal, including:S1, monitor the gesture operation event of touch type terminal top view;S2, offset distance is slided according to the gesture to view and gesture is slided between offset distance and view animation effect parameter Mapping relations, obtain view animation effect parameter;S3, according to the view animation effect parameter, animated show is carried out to view.
- 2. the animation effect implementation method of view as claimed in claim 1, it is characterised in that the gesture operation event includes Gesture presses event, gesture slip event and gesture and lifts event;Calculated in the following way in the step S2 and offset distance is slided to the gesture of view:S21a, monitor gesture and press event, record presses transverse and longitudinal coordinate (Ax, Ay) a little;S22a, monitor gesture slip event, the finger current location being recorded in gesture sliding process transverse and longitudinal coordinate (Ex, Ey);S23a, the slip offset distance △ x=Ex-Ax of transverse axis and the slip offset distance △ y=Ey-Ay of the longitudinal axis are obtained respectively, Offset distance is slided using the greater in △ x and △ y as the gesture to view.
- 3. the animation effect implementation method of view as claimed in claim 2, it is characterised in that by as follows in the step S2 Mode establishes the mapping relations slided to the gesture of view between offset distance and view animation effect parameter:S21b, detection gesture lift event, and record lifts transverse and longitudinal coordinate a little;S22b, transverse and longitudinal coordinate a little is pressed according to gesture and lifts transverse and longitudinal coordinate a little, determines taking for gesture slip offset distance It is worth scope;S23b, the span of offset distance and the value model of default view animation effect parameter are slided according to the gesture of determination Enclose, the mapping relations established between gesture slip offset distance and view animation effect parameter.
- 4. the animation effect implementation method of view as claimed in claim 3, it is characterised in that the step S22b is specifically wrapped Include:If it is (Gx, Gy) to lift transverse and longitudinal coordinate a little, the gesture for obtaining transverse axis when gesture is lifted respectively slides offset distance Δ x' The gesture of=Gx-Ax and the longitudinal axis slides offset distance Δ y'=Gy-Ay, and the higher value in △ x' and △ y' determines that gesture is slided The span of dynamic offset distance.
- 5. the animation effect implementation method of view as claimed in claim 3, it is characterised in that the animation effect parameter includes View scaling and view perspective.
- 6. the animation effect implementation method of view as claimed in claim 5, it is characterised in that the default view pantograph ratio Example P span is 0 < P≤1.1, and the span of the view perspective T is 0 < T≤1.
- 7. the animation effect implementation method of view as claimed in claim 6, it is characterised in that the gesture slides offset distance It is curve of order 2 relation between view scaling, it is single order line that the gesture, which is slided between offset distance and view perspective, Sexual intercourse.
- 8. the animation effect implementation method of view as claimed in claim 7, it is characterised in that the step S3 is specifically included:In gesture in the sliding process of view, in real time according to current gesture slide offset distance obtain corresponding to view pantograph ratio Example and transparency, animated show is carried out to view;OrWhen listening to gesture and lifting event, gesture when being lifted according to gesture slides offset distance, obtain corresponding to view contracting Ratio and transparency are put, animated show is carried out to view.
- A kind of 9. animation effect realization device of view, it is characterised in that including:Module is monitored, for monitoring the gesture operation event of touch type terminal top view;Acquisition module, for sliding offset distance and gesture slip offset distance and view animation effect according to the gesture to view Mapping relations between fruit parameter, obtain view animation effect parameter;Display module, for according to the view animation effect parameter, animated show to be carried out to view.
- 10. the equipment of the animation effect implementation method of a kind of view, it is characterised in that including processor (processor), storage Device (memory) and bus;The processor and memory complete mutual communication by the bus;The memory storage has can be by the programmed instruction of the computing device, and the processor calls described program instruction energy Enough perform the method as described in claim any one of 1-8.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201710406260.2A CN107340964A (en) | 2017-06-02 | 2017-06-02 | The animation effect implementation method and device of a kind of view |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201710406260.2A CN107340964A (en) | 2017-06-02 | 2017-06-02 | The animation effect implementation method and device of a kind of view |
Publications (1)
Publication Number | Publication Date |
---|---|
CN107340964A true CN107340964A (en) | 2017-11-10 |
Family
ID=60221478
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201710406260.2A Pending CN107340964A (en) | 2017-06-02 | 2017-06-02 | The animation effect implementation method and device of a kind of view |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN107340964A (en) |
Cited By (9)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN107967102A (en) * | 2017-12-29 | 2018-04-27 | 北京酷我科技有限公司 | A kind of view control in android system |
CN108628455A (en) * | 2018-05-14 | 2018-10-09 | 中北大学 | A kind of virtual husky picture method for drafting based on touch-screen gesture identification |
CN110619615A (en) * | 2018-12-29 | 2019-12-27 | 北京时光荏苒科技有限公司 | Method and apparatus for processing image |
CN110704138A (en) * | 2018-06-25 | 2020-01-17 | 马上消费金融股份有限公司 | Animation effect realization method and device and computer readable storage medium |
CN112214856A (en) * | 2020-11-04 | 2021-01-12 | 上海理工大学 | Precision machine tool rigidity optimization design method for overall structure |
CN112882637A (en) * | 2021-02-23 | 2021-06-01 | 上海哔哩哔哩科技有限公司 | Interaction method for multi-layer animation display and browser |
CN112882638A (en) * | 2021-02-23 | 2021-06-01 | 上海哔哩哔哩科技有限公司 | Multi-layer animation display method and device |
WO2022062985A1 (en) * | 2020-09-25 | 2022-03-31 | 荣耀终端有限公司 | Method and apparatus for adding special effect in video, and terminal device |
WO2024098713A1 (en) * | 2022-11-11 | 2024-05-16 | 中兴通讯股份有限公司 | Terminal desktop display method, terminal and computer-readable medium |
Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN103942050A (en) * | 2014-04-15 | 2014-07-23 | Tcl集团股份有限公司 | Implementation method and system for applying animation to Android platform |
CN104780093A (en) * | 2014-01-15 | 2015-07-15 | 阿里巴巴集团控股有限公司 | Method and device for processing expression information in instant messaging process |
CN105373291A (en) * | 2015-11-11 | 2016-03-02 | 北京麒麟合盛网络技术有限公司 | Interface switching method and device |
US20160231895A1 (en) * | 2013-07-24 | 2016-08-11 | Innoventions, Inc. | Tilt-Based View Scrolling with Baseline Update for Proportional and Dynamic Modes |
CN106445337A (en) * | 2016-09-13 | 2017-02-22 | 广州视睿电子科技有限公司 | Spotlight effect achieving method and device |
-
2017
- 2017-06-02 CN CN201710406260.2A patent/CN107340964A/en active Pending
Patent Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20160231895A1 (en) * | 2013-07-24 | 2016-08-11 | Innoventions, Inc. | Tilt-Based View Scrolling with Baseline Update for Proportional and Dynamic Modes |
CN104780093A (en) * | 2014-01-15 | 2015-07-15 | 阿里巴巴集团控股有限公司 | Method and device for processing expression information in instant messaging process |
CN103942050A (en) * | 2014-04-15 | 2014-07-23 | Tcl集团股份有限公司 | Implementation method and system for applying animation to Android platform |
CN105373291A (en) * | 2015-11-11 | 2016-03-02 | 北京麒麟合盛网络技术有限公司 | Interface switching method and device |
CN106445337A (en) * | 2016-09-13 | 2017-02-22 | 广州视睿电子科技有限公司 | Spotlight effect achieving method and device |
Cited By (11)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN107967102A (en) * | 2017-12-29 | 2018-04-27 | 北京酷我科技有限公司 | A kind of view control in android system |
CN108628455A (en) * | 2018-05-14 | 2018-10-09 | 中北大学 | A kind of virtual husky picture method for drafting based on touch-screen gesture identification |
CN108628455B (en) * | 2018-05-14 | 2021-10-15 | 中北大学 | Virtual sand painting drawing method based on touch screen gesture recognition |
CN110704138A (en) * | 2018-06-25 | 2020-01-17 | 马上消费金融股份有限公司 | Animation effect realization method and device and computer readable storage medium |
CN110704138B (en) * | 2018-06-25 | 2021-04-23 | 马上消费金融股份有限公司 | Animation effect realization method and device and computer readable storage medium |
CN110619615A (en) * | 2018-12-29 | 2019-12-27 | 北京时光荏苒科技有限公司 | Method and apparatus for processing image |
WO2022062985A1 (en) * | 2020-09-25 | 2022-03-31 | 荣耀终端有限公司 | Method and apparatus for adding special effect in video, and terminal device |
CN112214856A (en) * | 2020-11-04 | 2021-01-12 | 上海理工大学 | Precision machine tool rigidity optimization design method for overall structure |
CN112882637A (en) * | 2021-02-23 | 2021-06-01 | 上海哔哩哔哩科技有限公司 | Interaction method for multi-layer animation display and browser |
CN112882638A (en) * | 2021-02-23 | 2021-06-01 | 上海哔哩哔哩科技有限公司 | Multi-layer animation display method and device |
WO2024098713A1 (en) * | 2022-11-11 | 2024-05-16 | 中兴通讯股份有限公司 | Terminal desktop display method, terminal and computer-readable medium |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN107340964A (en) | The animation effect implementation method and device of a kind of view | |
CN109242765B (en) | Face image processing method and device and storage medium | |
CN108062526A (en) | A kind of estimation method of human posture and mobile terminal | |
EP3452886A1 (en) | Identification of objects in a scene using gaze tracking techniques | |
CN104063128B (en) | A kind of information processing method and electronic equipment | |
CN109697265B (en) | Page returning method and device | |
CN104679388B (en) | The method and its mobile terminal of application program are opened by icon duplicate | |
CN104035562B (en) | Method and system for mapping three-dimensional desktop touch events | |
CN104423796B (en) | User interface based on equipment situation | |
CN102902458A (en) | Page turning method for E-books | |
CN110297973A (en) | A kind of data recommendation method based on deep learning, device and terminal device | |
CN108463799A (en) | The flexible display and its operating method of electronic equipment | |
CN102945077A (en) | Image viewing method and device and intelligent terminal | |
CN105549892A (en) | Augmented reality information display method and apparatus | |
CN105824534B (en) | A kind of information processing method and electronic equipment | |
CN105739771B (en) | A kind of display interface management method, device and terminal | |
CN108629767A (en) | A kind of method, device and mobile terminal of scene detection | |
US20160379033A1 (en) | Interaction method and apparatus | |
CN107908331A (en) | The display control method and electronic equipment of a kind of desktop icons | |
WO2015176376A1 (en) | Method and device for automatically adjusting valid touch point, and computer storage medium | |
CN107450905A (en) | Session interface rendering intent and client | |
CN105677187B (en) | The display control method and device of image | |
CN104049843B (en) | A kind of information processing method and electronic equipment | |
CN107291344A (en) | A kind of method of content selection, device and terminal device | |
CN111324274A (en) | Virtual makeup trial method, device, equipment 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 | ||
RJ01 | Rejection of invention patent application after publication |
Application publication date: 20171110 |
|
RJ01 | Rejection of invention patent application after publication |