Nothing Special   »   [go: up one dir, main page]

CN104571887B - Static picture based dynamic interaction method and device - Google Patents

Static picture based dynamic interaction method and device Download PDF

Info

Publication number
CN104571887B
CN104571887B CN201410855538.0A CN201410855538A CN104571887B CN 104571887 B CN104571887 B CN 104571887B CN 201410855538 A CN201410855538 A CN 201410855538A CN 104571887 B CN104571887 B CN 104571887B
Authority
CN
China
Prior art keywords
pixel
characteristic area
frame
point
motion
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
CN201410855538.0A
Other languages
Chinese (zh)
Other versions
CN104571887A (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.)
Beijing Qihoo Technology Co Ltd
Original Assignee
Beijing Qihoo Technology Co Ltd
Qizhi Software Beijing 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 Beijing Qihoo Technology Co Ltd, Qizhi Software Beijing Co Ltd filed Critical Beijing Qihoo Technology Co Ltd
Priority to CN201410855538.0A priority Critical patent/CN104571887B/en
Publication of CN104571887A publication Critical patent/CN104571887A/en
Priority to PCT/CN2015/095933 priority patent/WO2016107356A1/en
Application granted granted Critical
Publication of CN104571887B publication Critical patent/CN104571887B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input 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/01Input arrangements or combined input and output arrangements for interaction between user and computer
    • G06F3/048Interaction techniques based on graphical user interfaces [GUI]
    • G06F3/0484Interaction techniques based on graphical user interfaces [GUI] for the control of specific functions or operations, e.g. selecting or manipulating an object, an image or a displayed text element, setting a parameter value or selecting a range
    • G06F3/04845Interaction techniques based on graphical user interfaces [GUI] for the control of specific functions or operations, e.g. selecting or manipulating an object, an image or a displayed text element, setting a parameter value or selecting a range for image manipulation, e.g. dragging, rotation, expansion or change of colour
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input 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/01Input arrangements or combined input and output arrangements for interaction between user and computer
    • G06F3/048Interaction techniques based on graphical user interfaces [GUI]
    • G06F3/0487Interaction 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
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/44Arrangements for executing specific programs
    • G06F9/451Execution arrangements for user interfaces

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • General Engineering & Computer Science (AREA)
  • Human Computer Interaction (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Software Systems (AREA)
  • Image Processing (AREA)

Abstract

The embodiment of the invention provides a static picture based dynamic interaction method and device. The static picture based dynamic interaction method and device comprises the steps of selecting a feature area in a static picture, determining a mapping reference object according to a specific interaction operation event when monitoring the specific interaction operation event, and mapping at least a part of pixel points in the feature area to a one-frame or multi-frame distorted picture so as to drive the static picture to change frame by frame according to the mapping reference object. By means of the static picture based dynamic interaction method and device, the dynamic effect is played without a special application, the technical threshold is reduced, and operation simplicity is improved. In addition, static picture based dynamic interaction is achieved by making feedback on interaction operation of a user, and a dynamic effect mode is enriched.

Description

A kind of dynamic interaction method and apparatus based on static images
Technical field
The present invention relates to technical field of image processing, more particularly to a kind of dynamic interaction method based on static images and A kind of dynamic interaction device based on static images.
Background technology
With computer science and technology development, especially mobile device is widely available, computer based be widely used into Enter the various aspects of people's life.
Picture browsing on internet occupies a big chunk of user's visit capacity, with the development of mobile Internet, User is increasingly becoming trend in browsing pictures on mobile phone.But traditional Internet picture major part is all static images, lack Weary dynamic effect.
Conventional dynamic picture typically adopts GIF forms, needs special application to generate, and general user is difficult editor, Technical threshold is high, operating difficulties.
Also only it is to be set for dynamic broadcasting according to first even the dynamic picture of GIF forms, form is single.
The content of the invention
In view of the above problems, it is proposed that the present invention so as to provide one kind overcome the problems referred to above or at least in part solve on State a kind of dynamic interaction method based on static images and a kind of corresponding dynamic interaction device based on static images of problem.
According to one aspect of the present invention, there is provided a kind of dynamic interaction method based on static images, including:
The selected characteristic region in static images;
When the interactive operation event specified is listened to, mapping references object is determined according to specified interactive operation event;
According to it is described mapping references object to the characteristic area at least part of pixel be mapped to a frame or multiframe In distortion picture, to drive the static images to be change from frame to frame.
Alternatively, the interactive operation event specified includes rocking event, the mapping references object include one or Multiple reference points;
The step of interactive operation event that the basis is specified determines mapping references object includes:
Direction is rocked according to the event of rocking, one or more reference points are chosen in the characteristic area of static images.
Alternatively, the interactive operation event specified includes screen taps event, and the mapping references object includes one Individual or multiple reference points;
The step of interactive operation event that the basis is specified determines mapping references object includes:
According to the direction for pointing to generation screen taps event, one or more ginsengs are chosen in the characteristic area of static images Examination point.
Alternatively, the characteristic area has characteristic point;
It is described according to it is described mapping references object to the characteristic area at least part of pixel be mapped to a frame or In multiframe distortion picture, include the step of to drive the static images to be change from frame to frame:
The pixel of the static images is mapped to by a frame according to the characteristic point and one or more of reference points Or in multiframe distortion picture.
Alternatively, the characteristic area includes convex domain, and the characteristic point includes focus point.
Alternatively, it is described according to the characteristic point and one or more of reference points by the pixel of the static images Step in being mapped to a frame or multiframe distortion picture includes:
Generate distortion picture;
Pixel on the first line in the characteristic area is mapped on the second line;
Copy the pixel on second line to same position in the distortion picture;
Wherein, first line is the line between the characteristic point and marginal point, and second line is current ginseng The line of examination point and marginal point, the marginal point is the coordinate points on the characteristic area edge.
Alternatively, the pixel by the first line in the characteristic area is mapped to the step on the second line Including:
Calculate the pixel in the characteristic area on the first line, the relative position on the first line;
According to the relative position, the pixel is copied on the second line.
Alternatively, it is described according to the characteristic point and one or more of reference points by the pixel of the static images Step in being mapped to a frame or multiframe distortion picture also includes:
Pixel outside the characteristic area is mapped to the same position in the distortion picture.
Alternatively, it is described according to the characteristic point and one or more of reference points by the pixel of the static images Step in being mapped to a frame or multiframe distortion picture also includes:
The pixel of location overlap carries out pixel overlap-add procedure in distorting picture.
Alternatively, it is described according to the characteristic point and one or more of reference points by the pixel of the static images Step in being mapped to a frame or multiframe distortion picture also includes:
Blank position in distorting picture carries out pixel interpolation processing.
Alternatively, the interactive operation event specified includes rocking event, and the mapping references object includes the spy Levy the direction of motion of at least part of pixel in region;
The step of interactive operation event that the basis is specified determines mapping references object includes:
Arrange event of rocking rocks the direction of motion that direction is at least part of pixel in the characteristic area.
Alternatively, the Action Events specified include screen taps event, and the mapping references object includes the spy Levy the direction of motion of at least part of pixel in region;
The step of Action Events that the basis is specified determine mapping references object includes:
The direction for being set to point to generation screen taps event is the motion of at least part of pixel in the characteristic area Direction.
Alternatively, it is described according to it is described mapping references object to the characteristic area at least part of pixel be mapped to In one frame or multiframe distortion picture, include the step of to drive the static images to be change from frame to frame:
In the direction of motion, according to preset mode to the characteristic area at least part of pixel carry out texture Mapping, produces the dynamic effect comprising a frame or multiframe distortion picture change.
Alternatively, it is described in the direction of motion, according to preset mode to the characteristic area at least part of picture Vegetarian refreshments carries out texture mapping, and producing the step of distorting the dynamic effect of picture change comprising a frame or multiframe includes:
The characteristic area is divided into one or more graphings;There are multiple summits in each graphing, each Summit has texture coordinate;
In the direction of motion, the top of each drawing image is moved in one or more time points according to preset mode Point;
For each graphing, using graphic plotting interface according to the texture coordinate on each summit in graphing Pixel carries out texture mapping, produces the dynamic effect comprising a frame or multiframe distortion picture change.
Alternatively, the preset mode includes simple harmonic motion pattern and/or damping vibration pattern;
It is described in the direction of motion, move each drawing image in one or more time points according to preset mode The step of summit, includes:
In the direction of motion, according to simple harmonic motion pattern and/or damping vibration pattern in one or more time points The summit of mobile each drawing image.
Alternatively, it is described in the direction of motion, according to simple harmonic motion pattern and/or damping vibration pattern at one or The step of multiple time points move the summit of each drawing image includes:
Determine the acceleration on the summit of each drawing image;The summit of each drawing image has original coordinates;
According to the acceleration and/or default damped coefficient, calculating is moved in one or more time points along described Move the displacement on the summit of each drawing image in direction;
The coordinates of targets on the summit of each drawing image is calculated by the original coordinates and the displacement.
Alternatively, methods described also includes:
Dynamic picture is generated using the static images and a frame or multiframe warp image.
Alternatively, methods described also includes:
Multidate information is generated based on the characteristic area;
The multidate information and scripting object are write in the static images, to generate dynamic interaction file.
Alternatively, the step of generation multidate information based on the characteristic area includes:
Multidate information is generated using the characteristic area, the characteristic point and one or more of reference points.
Alternatively, the step of generation multidate information based on the characteristic area includes:
The direction of motion of at least part of pixel in using the characteristic area and the characteristic area generates dynamic letter Breath.
According to a further aspect in the invention, there is provided a kind of dynamic interaction device based on static images, including:
Module is chosen, the selected characteristic region in static images is suitable to;
Determining module, is suitable to, when the interactive operation event specified is listened to, be determined according to specified interactive operation event Mapping references object;
Mapping block, be suitable to according to it is described mapping references object to the characteristic area at least part of pixel mapping To in a frame or multiframe distortion picture, to drive the static images to be change from frame to frame.
Alternatively, the interactive operation event specified includes rocking event, the mapping references object include one or Multiple reference points;
The determining module is further adapted for:
Direction is rocked according to the event of rocking, one or more reference points are chosen in the characteristic area of static images.
Alternatively, the interactive operation event specified includes screen taps event, and the mapping references object includes one Individual or multiple reference points;
The determining module is further adapted for:
According to the direction for pointing to generation screen taps event, one or more ginsengs are chosen in the characteristic area of static images Examination point.
Alternatively, the characteristic area has characteristic point;The mapping block is further adapted for:
The pixel of the static images is mapped to by a frame according to the characteristic point and one or more of reference points Or in multiframe distortion picture.
Alternatively, the characteristic area includes convex domain, and the characteristic point includes focus point.
Alternatively, the mapping block is further adapted for:
Generate distortion picture;
Pixel on the first line in the characteristic area is mapped on the second line;
Copy the pixel on second line to same position in the distortion picture;
Wherein, first line is the line between the characteristic point and marginal point, and second line is current ginseng The line of examination point and marginal point, the marginal point is the coordinate points on the characteristic area edge.
Alternatively, the mapping block is further adapted for:
Calculate the pixel in the characteristic area on the first line, the relative position on the first line;
According to the relative position, the pixel is copied on the second line.
Alternatively, the mapping block is further adapted for:
Pixel outside the characteristic area is mapped to the same position in the distortion picture.
Alternatively, the mapping block is further adapted for:
The pixel of location overlap carries out pixel overlap-add procedure in distorting picture.
Alternatively, the mapping block is further adapted for:
Blank position in distorting picture carries out pixel interpolation processing.
Alternatively, the interactive operation event specified includes rocking event, and the mapping references object includes the spy Levy the direction of motion of at least part of pixel in region;
The determining module is further adapted for:
Arrange event of rocking rocks the direction of motion that direction is at least part of pixel in the characteristic area.
Alternatively, the Action Events specified include screen taps event, and the mapping references object includes the spy Levy the direction of motion of at least part of pixel in region;
The determining module is further adapted for:
The direction for being set to point to generation screen taps event is the motion of at least part of pixel in the characteristic area Direction.
Alternatively, the mapping block is further adapted for:
In the direction of motion, according to preset mode to the characteristic area at least part of pixel carry out texture Mapping, produces the dynamic effect comprising a frame or multiframe distortion picture change.
Alternatively, the mapping block is further adapted for:
The characteristic area is divided into one or more graphings;There are multiple summits in each graphing, each Summit has texture coordinate;
In the direction of motion, the top of each drawing image is moved in one or more time points according to preset mode Point;
For each graphing, using graphic plotting interface according to the texture coordinate on each summit in graphing Pixel carries out texture mapping, produces the dynamic effect comprising a frame or multiframe distortion picture change.
Alternatively, the preset mode includes simple harmonic motion pattern and/or damping vibration pattern;The mapping block is also fitted In:
In the direction of motion, according to simple harmonic motion pattern and/or damping vibration pattern in one or more time points The summit of mobile each drawing image.
Alternatively, the mapping block is further adapted for:
Determine the acceleration on the summit of each drawing image;The summit of each drawing image has original coordinates;
According to the acceleration and/or default damped coefficient, calculating is moved in one or more time points along described Move the displacement on the summit of each drawing image in direction;
The coordinates of targets on the summit of each drawing image is calculated by the original coordinates and the displacement.
Alternatively, described device also includes:
First generation module, is suitable for use with the static images and a frame or multiframe warp image generates Dynamic Graph Piece.
Alternatively, described device also includes:
Second generation module, is suitable to generate multidate information based on the characteristic area;
Writing module, is suitable to the multidate information and scripting object be write in the static images, to generate dynamic friendship Mutual file.
Alternatively, second generation module is further adapted for:
Multidate information is generated using the characteristic area, the characteristic point and one or more of reference points.
Alternatively, second generation module is further adapted for:
The direction of motion of at least part of pixel in using the characteristic area and the characteristic area generates dynamic letter Breath.
The embodiment of the present invention by determine when listening to the interactive operation event specified mapping references object, with to static images Characteristic area at least part of pixel be mapped to a frame or multiframe distortion picture in, to drive static images to become frame by frame Change, without special application dynamic effect is generated, reduce technical threshold, the simplicity of operation is improve, additionally, passing through Interactive operation to user is fed back, and realizes the dynamic interaction of static images, enriches the form of dynamic effect.
The pixel of static images is mapped to into a frame based on one or more reference points for the embodiment of the present invention or multiframe is turned round In diagram piece, dynamic effect is generated, calculating is simple, need not rely on third party's kit, library file or instrument, render generation speed Degree is fast, few to resource consumption, easily cross-platform.
At least part of pixel in characteristic area is carried out texture mapping by the present invention based on the direction of motion, is produced and is included one Frame or the dynamic effect of multiframe distortion picture change, on the one hand, dynamic effect is generated to characteristic area, dynamic effect is reduced Volume, reduces bandwidth occupancy during transmission, and on the other hand convenient transmission, because texture mapping efficiency is very high, reduces generation Dynamic effect it is time-consuming, for picture in network picture or system photograph album etc. can soon produce dynamic effect, soon Speed, be conveniently generated dynamic effect, realizing dynamic effect can be with the real-time interactive of the interbehavior of user.
Described above is only the general introduction of technical solution of the present invention, in order to better understand the technological means of the present invention, And can be practiced according to the content of specification, and in order to allow the above and other objects of the present invention, feature and advantage can Become apparent, below especially exemplified by the specific embodiment of the present invention.
Description of the drawings
By the detailed description for reading hereafter preferred embodiment, various other advantages and benefit is common for this area Technical staff will be clear from understanding.Accompanying drawing is only used for illustrating the purpose of preferred embodiment, and is not considered as to the present invention Restriction.And in whole accompanying drawing, it is denoted by the same reference numerals identical part.In the accompanying drawings:
Fig. 1 shows a kind of dynamic interaction embodiment of the method based on static images according to an embodiment of the invention Flow chart of steps;
Fig. 2 shows a kind of exemplary plot of static images according to an embodiment of the invention;
Fig. 3 shows a kind of exemplary plot in selected characteristic region in static images according to an embodiment of the invention;
Fig. 4 A and Fig. 4 B show a kind of Mapping Examples figure of pixel according to an embodiment of the invention;
Fig. 5 A and Fig. 5 B show a kind of exemplary plot of warp image according to an embodiment of the invention;And
Fig. 6 shows a kind of dynamic interaction device embodiment based on static images according to an embodiment of the invention Structured flowchart.
Specific embodiment
The exemplary embodiment of the disclosure is more fully described below with reference to accompanying drawings.Although showing the disclosure in accompanying drawing Exemplary embodiment, it being understood, however, that may be realized in various forms the disclosure and should not be by embodiments set forth here Limited.On the contrary, there is provided these embodiments are able to be best understood from the disclosure, and can be by the scope of the present disclosure Complete conveys to those skilled in the art.
With reference to Fig. 1, a kind of dynamic interaction method reality based on static images according to an embodiment of the invention is shown The step of applying flow chart, specifically may include steps of:
Step 101, the selected characteristic region in static images;
It should be noted that the embodiment of the present invention can apply in mobile device, and for example, mobile phone, PDA (Personal Digital Assistant, personal digital assistant), laptop computer, palm PC etc., it is also possible to be applied to fixation and setting In standby, for example, PC (Personal Computer, PC), notebook computer etc., the embodiment of the present invention is not added with to this To limit.
These mobile devices or fixing equipment typically can be supported to include Android (Android), IOS, WindowsPhone Or the operating system of windows etc., can generally store static images.
Static images, can for dynamic picture, i.e., not have the picture of dynamic effect.
The static images can including JPG, JPEG, PNG, BMP etc. form, the embodiment of the present invention is not any limitation as to this.
In embodiments of the present invention, some region can be chosen in static images as characteristic area, this feature area Domain can be the shapes such as polygon, circle, ellipse, and for the view data in this feature region the life of dynamic effect is carried out Into.
For example, for static images as shown in Figure 2, an oval choice box as shown in Figure 3, user can be provided The shape of the oval choice box can be changed, and select it for the position of static images, the position can determine as spy Levy region.
Step 102, when the interactive operation event specified is listened to, according to specified interactive operation event mapping ginseng is determined Examine object;
In implementing, the interactive operation event can be to interact the caused event of operation by user.
When mapping references object can be to be mapped for the pixel in characteristic area, as mapping position reference Object.
By the triggering of the interactive operation event, characteristic area can be caused to carry out the shake effect similar to physics water polo (approximately filling the balloon of water), and its jitter direction and mode are changed according to the different interactive operation of user, such as hand Direction, position of screen taps of machine shake etc..
In a kind of alternative embodiment of the present invention, the interactive operation event specified can include rocking event, institute Stating mapping references object can include one or more reference points;
Then in embodiments of the present invention, step 102 can include following sub-step:
Sub-step S11, according to the event of rocking direction is rocked, and in the characteristic area of static images one or more are chosen Reference point.
In implementing, can be when the interactive operation event specified be listened to, according to specified interactive operation event Determine one or more reference points.
In embodiments of the present invention, user can interact operation by rocking.
Specifically, acceleration transducer can be monitored from the Sensor Events interface of operating system (such as Android) (such as 3-axis acceleration sensor) event.
After receiving acceleration transducer change events, equipment is obtained respectively in level, vertical and three sides of spatial vertical To acceleration, calculate the quadratic sum of all directions acceleration, and its square root is obtained, as the comprehensive acceleration of equipment movement.
If comprehensive acceleration may determine that the event of rocking that listens to more than the acceleration rate threshold of setting, assert user's Rock operation to interact.
On direction is rocked, can be with to rock direction identical, it is also possible in opposite direction with rocking, in the feature of static images The reference point of one or more continuous distributeds is chosen in region.
In a kind of alternative embodiment of the present invention, the interactive operation event specified can include screen taps thing Part, the mapping references object can include one or more reference points;
Then in embodiments of the present invention, step 102 can include following sub-step:
Sub-step S12, according to the direction for pointing to generation screen taps event, in the characteristic area of static images one is chosen Individual or multiple reference points.
In embodiments of the present invention, user can interact operation by clicking on screen (such as characteristic area).
If listening to screen taps event, can be according to the direction for pointing to generation screen taps event, such as characteristic area Central point/focus point point to the direction that screen taps event occurs, can be identical with the direction, it is also possible to direction phase Instead, the reference point of one or more continuous distributeds is chosen in the characteristic area of static images.
Certainly, the determination mode of above-mentioned reference point is intended only as example, when the embodiment of the present invention is implemented, can be according to reality Border situation arranges the determination mode of other reference points, and for example, the position of direct specified reference point, the embodiment of the present invention is not added with to this To limit.In addition, in addition to the determination mode of above-mentioned reference point, those skilled in the art can also according to actual needs adopt it The determination mode of its reference point, the embodiment of the present invention is not also any limitation as to this.
In a kind of alternative embodiment of the present invention, the interactive operation event specified can include rocking event, institute Stating mapping references object can include the direction of motion of at least part of pixel in the characteristic area;
Then in embodiments of the present invention, step 102 can include following sub-step:
Sub-step S13, arrange event of rocking rocks the fortune that direction is at least part of pixel in the characteristic area Dynamic direction.
In order to produce dynamic effect, the position on the summit of graphing can be moved, the movement of the position on summit can take Certainly in the interactive operation of user.
For example, when user is hand shakes mobile phone, then the summit of graphing can be toward the direction movement rocked, its shape Also can change therewith.
Again for example, when certain position of user's hand Touch screen, then the summit of graphing can be toward the touch of user Point movement, its shape also can change therewith.
By the triggering of the interactive operation event, characteristic area can be caused to carry out the shake effect similar to physics water polo (approximately filling the balloon of water), and its jitter direction and mode are changed according to the different interactive operation of user, such as hand Direction, position of screen taps of machine shake etc..
In embodiments of the present invention, user can interact operation by rocking.
On direction is rocked, can be with to rock direction identical, it is also possible in opposite direction with rocking, as the spy of static images Levy the direction of motion of at least part of pixel in region in selected characteristic region.
It should be noted that the direction of motion can include acceleration.
In a kind of alternative embodiment of the present invention, the Action Events specified can include screen taps event, institute Stating mapping references object can include the direction of motion of at least part of pixel in the characteristic area;
Then in embodiments of the present invention, step 102 can include following sub-step:
Sub-step S14, the direction for being set to point to generation screen taps event is at least part of picture in the characteristic area The direction of motion of vegetarian refreshments.
In embodiments of the present invention, user can interact operation by clicking on screen (such as characteristic area).
If listening to screen taps event, can be according to the direction for pointing to generation screen taps event, such as characteristic area Central point/focus point point to the direction that screen taps event occurs, can be identical with the direction, it is also possible to direction phase Instead, as the direction of motion of at least part of pixel in selected characteristic region in the characteristic area of static images.
Certainly, the determination mode of the above-mentioned direction of motion is intended only as example, when the embodiment of the present invention is implemented, can basis Actual conditions arrange the determination mode of other directions of motion, and the embodiment of the present invention is not any limitation as to this.In addition, except above-mentioned ginseng Outside the determination mode of examination point, those skilled in the art can also according to actual needs adopt the determination mode of other directions of motion, The embodiment of the present invention is not also any limitation as to this.
Step 103, according to it is described mapping references object to the characteristic area at least part of pixel be mapped to one In frame or multiframe distortion picture, to drive the static images to be change from frame to frame.
In implementing, references object can be mapped as the amplitude reference of distortion, static images are mapped, with Generate distortion picture.
When mapping references object amplitude it is bigger, the amplitude of distortion can be bigger, when mapping references object amplitude it is less, The amplitude of distortion can be less.
The embodiment of the present invention by determine when listening to the interactive operation event specified mapping references object, with to static images Characteristic area at least part of pixel be mapped to a frame or multiframe distortion picture in, to drive static images to become frame by frame Change, without special application dynamic effect is generated, reduce technical threshold, the simplicity of operation is improve, additionally, passing through Interactive operation to user is fed back, and realizes the dynamic interaction of static images, enriches the form of dynamic effect.
In a kind of alternative embodiment of the present invention, step 103 can include following sub-step:
Sub-step S21, according to the characteristic point and one or more of reference points by the pixel of the static images In being mapped to a frame or multiframe distortion picture.
In embodiments of the present invention, there can be characteristic point in the characteristic area, to the generation for carrying out dynamic effect.
In embodiments of the present invention, can be on the basis of characteristic point, using reference point as the amplitude reference of distortion, to static state Picture is mapped, to generate distortion picture.
The pixel in characteristic area in static images can point to the direction mapping of reference point along characteristic point, cause quiet The distortion of state picture.When reference point deviates, characteristic point is bigger, and the amplitude of distortion can be bigger, gets over when reference point deviates characteristic point Little, the amplitude of distortion can be less, especially, when characteristic point overlaps with reference point, in distortion picture distortion can not be produced.
In a kind of optional example of the embodiment of the present invention, the characteristic area can include convex domain, the characteristic point Focus point can be included.
Convex domain, may refer to figure toward evagination, where not falling in from geometrically seeing.
Convex domain can be so defined on algebraically:Appoint in set and take two points a, b, there are t*a+ (1-t) * b to still fall within this Set, wherein 0<t<1, the meaning of this expression formula can be the straightway for connecting two point a b also in set.
Center of gravity geometrically, is also called geometric center, and when object is homogeneous (density is definite value), barycenter is equal to the centre of form, Such as, the intersection point of Atria bar center line.
In a kind of alternative embodiment of the present invention, sub-step S21 can include following sub-step:
Sub-step S211, generates distortion picture;
In embodiments of the present invention, the original state for distorting picture can be blank.
Sub-step S212, the pixel on the first line in the characteristic area is mapped on the second line;
Wherein, first line can be line between the characteristic point and marginal point, and second line can be with For current reference point and the line of marginal point, the marginal point can be the coordinate points on the characteristic area edge.
In the embodiment of the present invention, for the pixel in characteristic area, can be mapped according to reference point.
It should be noted that if characteristic area is convex domain, reference point is characterized the pixel in region, then after mapping Pixel may be located in characteristic area, realize that the pixel in characteristic area is mapped in characteristic area, without reflecting It is mapped to outside characteristic area.
For example, as shown in Figure 4 A, C0 is characterized point (such as focus point), and C1 can be reference point, and E can be with marginal point, then C0E Can be the first line, C1E can be the second line, in the embodiment of the present invention, can be by the pixel on the first line C0E P0, is mapped on the second line C1E, obtains the point P1 being mapped to.
In a kind of alternative embodiment of the present invention, sub-step S212 can include following sub-step:
Sub-step S2121, calculates the pixel in the characteristic area on the first line, relative on the first line Position;
Sub-step S2122, according to the relative position, the pixel is copied on the second line.
In actual applications, the relative position that pixel can be expressed with proportionate relationship.
For example, in one example, as shown in Figure 4 A, the ratio of line segment C0P0 and line segment C0E, as ratio R, Ke Yizuo For relative positions of the pixel P0 on the first line C0E.According to ratio R, the point P1 on line segment C1E is tried to achieve so that line segment The ratio of C1P1 and the second line C1E is R.
Certainly, ratio table between other line segments comprising pixel and the first line can also be adopted in the embodiment of the present invention Up to relative position, the embodiment of the present invention is not any limitation as to this.
Sub-step S213, copies the pixel on second line to same position in the distortion picture;
If it is determined that on the second line pixel position, then can be copied to distort the same position in picture, Carry out the distortion mapping of image.
In a kind of alternative embodiment of the present invention, sub-step S21 can also include following sub-step:
Sub-step S214, the pixel outside the characteristic area is mapped to the same position in the distortion picture.
In the embodiment of the present invention, if pixel is outside convex characteristic area on static images, torsion can be copied directly to Corresponding same position on diagram piece, does not produce distortion.
Certainly, the embodiment of the present invention can not also to characteristic area outside pixel map, be based only upon characteristic area In pixel mapped, the embodiment of the present invention is not any limitation as to this.
In a kind of alternative embodiment of the present invention, sub-step S21 can also include following sub-step:
Sub-step S215, to the pixel of location overlap in distortion picture pixel overlap-add procedure is carried out.
In embodiments of the present invention, due to static images carry out mapping produce distortion, distortion picture in pixel more The region of concentration, may produce the situation of the location overlap of pixel.
For the situation of the location overlap of pixel, the embodiment of the present invention can carry out pixel overlap-add procedure.
For example, if using rgb color pattern, can be by red (R), green (G) to pixel, blue (B) three colors The change of passage and their superpositions each other are obtaining color miscellaneous.
Certainly, in order to further reduce amount of calculation, it is also possible to a pixel is chosen from the pixel of superposition (as random Selected pixels point, selection finally copy the pixel of the position to) as the pixel of the position, other modes can also be adopted The pixel of the position is chosen, the embodiment of the present invention is not any limitation as to this.
In a kind of alternative embodiment of the present invention, sub-step S21 can also include following sub-step:
Sub-step S216, to the blank position in distortion picture pixel interpolation processing is carried out.
In embodiments of the present invention, due to static images carry out mapping produce distortion, distortion picture in pixel more Sparse region, may be not assigned by some pixels and (be mapped to the position, the pixel of the position without pixel Point is reset condition, such as white), produce the situation of blank position.
The situation of the blank position in for distorting picture, the embodiment of the present invention can carry out pixel interpolation processing, with Completion distorts picture.
For example, for the pixel Px not being assigned, the pixel Py of selected distance its nearest assignment is (as above Pixel, the pixel of lower section, the pixel in left side, the pixel on right side of side etc.), the value of pixel Py is assigned to into pixel Px。
In actual applications, when reference point (C1 as shown in Figure 4 A) moves to some position, can basis The position of reference point (C1 as shown in Figure 4 A) maps out a distortion picture, with reference point (C1 as shown in Figure 4 A) movement To different positions, distort picture and also change, distortion picture can be played continuously, so as to form dynamic effect.
As shown in Figure 5A, if reference point (C1 as shown in Figure 4 A) is in the left side of characteristic point (C0 as shown in Figure 4 A), It is overall in characteristic image to distort toward left side;Shown in Fig. 5 B, if reference point is on the right side of characteristic point (C0 as shown in Figure 4 A), The then overall distortion that can turn right in characteristic image.
Further, if the position of reference point determines that reference point can be from feature according to the interactive operation event specified The position of point is set out, and (rocking direction, pointing to generation screen for event is such as rocked along the corresponding direction of interactive operation event specified The direction of click event) in the distribution of characteristic point both sides, finally overlap with characteristic point, then the distortion picture that characteristic area is mapped out can To distort back and forth along the corresponding direction of interactive operation event specified, shake effect is produced, and it is final static.
For example, as shown in Figure 4 A, reference Point C 1 does concussion movement, reference point along in the X-direction through focus point C0 C1 often moves to a position and will generate a distortion picture, and distortion picture is played frame by frame, can produced such as Fig. 5 A and Fig. 5 B Image table in shown characteristic area reveals the dynamic effect of left and right vibrations.
The pixel of static images is mapped to into a frame based on one or more reference points for the embodiment of the present invention or multiframe is turned round In diagram piece, dynamic effect is generated, calculating is simple, need not rely on third party's kit, library file or instrument, render generation speed Degree is fast, few to resource consumption, easily cross-platform.
In a kind of alternative embodiment of the present invention, step 103 can include following sub-step:
Sub-step S31, in the direction of motion, according to preset mode to the characteristic area at least part of pixel Point carries out texture mapping, produces the dynamic effect comprising a frame or multiframe distortion picture change.
In embodiments of the present invention, can be using the direction of motion (including acceleration) as the amplitude reference of distortion, to static state Picture is mapped, to generate distortion picture.
The pixel in characteristic area in static images can map along the direction of motion, cause the distortion of static images.
(as the amplitude of acceleration is bigger, the position of screen is clicked on when the amplitude of the direction of motion is bigger in characteristic area The heart is more remote), the amplitude of distortion can be bigger, and (as the amplitude of acceleration is less, screen is clicked on when the amplitude of the direction of motion is less Position from the center of characteristic area more close to), the amplitude of distortion can be less.
In a kind of alternative embodiment of the present invention, sub-step S31 can include following sub-step:
Sub-step S311, by the characteristic area one or more graphings are divided;
In embodiments of the present invention, can be in the way of Graphics Application, you can with the generation dynamic effect based on grid.
Specifically, characteristic area one or more graphings be can be divided into, triangle or other shapes are chosen as The grid (i.e. graphing) of shape, using triangle graphic plotting interface, such as OpenGL (Open Graphics are because Library), for the figure of triangle has rendered efficient accelerating algorithm.
There can be multiple summits in each graphing, each graphing (such as triangle) can be by summit (such as three Individual summit) represent, in addition to corresponding two-dimensional coordinate, each summit can have the texture coordinate of static images.
In one embodiment, one or more graphings can be divided to the central area of characteristic area, to simulate Similar to the shake effect (approximately filling the balloon of water) of physics water polo.
Sub-step S312, in the direction of motion, moves each and paints according to preset mode in one or more time points Imaged summit;
In embodiments of the present invention, can be according to preset mode, equidirectional, the rightabout movement along the direction of motion The summit of each graphing.
In a kind of alternative embodiment of the present invention, the preset mode can include simple harmonic motion pattern and/or damping Vibration mode;Then in embodiments of the present invention, sub-step S312 can include following sub-step:
Sub-step S3121, in the direction of motion, according to simple harmonic motion pattern and/or damping vibration pattern at one Or multiple time points move the summit of each drawing image.
Simple harmonic motion, or simple harmonic oscillation, resonance, SHM (Simple Harmonic Motion), can refer to object (such as The summit of each graphing) when carrying out simple harmonic motion, the power suffered by object (such as the summit of each graphing) with displacement into Direct ratio, and power always points at equilbrium position.
Damping vibration can refer to the vibrations under drag effect, when drag size can be ignored, it may be said that be simple harmonic quantity fortune It is dynamic.Acted on by resistance in vibration processes, amplitude is gradually reduced, energy gradually loses, until vibration stops.
In a kind of optional example of the embodiment of the present invention, sub-step S3121 can include following sub-step:
Sub-step S31211, determines the acceleration on the summit of each drawing image;
If interactive operation event is to rock event, can rock from this and acceleration initial when rocking is extracted in event, Used as the acceleration on the summit of each graphing, the amplitude rocked is bigger, and the acceleration on the summit of each graphing is also got over Greatly.
If interactive operation event is screen taps event, default acceleration can be extracted as each graphing The initial acceleration in summit.
Sub-step S31212, according to the acceleration and/or default damped coefficient, calculates in one or more time points The displacement on the interior summit that each drawing image is moved along the direction of motion;
For simple harmonic motion, can point to according to the power suffered by the summit of each graphing of the acceleration simulation, the power Equilbrium position, builds spring model, and simulate the summit of each graphing carries out simple harmonic motion along the direction of motion.
For damping vibration, the resistance suffered by the summit of each graphing can be simulated according to the damping system, be simulated The summit of each graphing carries out damping vibration along the direction of motion.
Can be calculated in one or more times by kinematics formula based on acceleration, damped coefficient, the direction of motion Displacement in point.
Sub-step S31213, the target on the summit of each drawing image is calculated by the original coordinates and the displacement Coordinate.
In embodiments of the present invention, the summit of each graphing can have original coordinates, i.e., in static images Original two-dimensional coordinate, the displacement in the direction of motion, addition, the then top of each graphing after being moved The position (i.e. coordinates of targets) of point.
Sub-step S313, for each graphing, using graphic plotting interface according to each summit texture coordinate pair Pixel in graphing carries out texture mapping, produces the dynamic effect comprising a frame or multiframe distortion picture change.
In implementing, graphic plotting interface can adopt OpenGL, and it can provide texture mapping (Texture Mapping), it is the process of the pixel being mapped to the texture pixel in texture space in screen space.
Generally, using can be as follows the step of texture mapping:
The first step:Define texture object
const int TexNumber4;
GLuint mes_Texture[TexNumber];// define texture object array
Second step:Generate texture object array
glGenTextures(TexNumber,m_Texture);
3rd step:Select texture object to complete the definition of the texture object by using glBindTexture.
glBindTexture(GL_TEXTURE 2D,m_Texture[0]);
glTexImage2D(GL_TEXTURE_2D,0,3,mes_Texmapl.GetWidth(),mee_Tex mapl.GetHeight(),0,GL_BGR_EXT,GL_UNSIGNED_BYTE,mse_Texmapl.Get DibBitsl' trQ);
4th step:It is that the scenery loads corresponding texture by glBindTexture before scenery is drawn.
glBindTexture(GLes_TEXTURE_2D,mse_Texture[0]);
5th step:GlDeleteTextures was called to delete texture object before EP (end of program).
glDeleteTextures(TexNumber,mee_Texture)。
In one example, as shown in Figure 4 B, graphing is triangle, and it includes one or more pixels, wherein, Summit has in the texture space texture coordinate, and the texture coordinate of summit a is for (0.2,0.8), the texture coordinate of summit b is (0.4,0.2), the texture coordinate of summit c for (0.8,0.4), the summit of graphing movement is moved so that draw Figure deforms, and carries out OpenGL texture mappings to object space is obtained, and renders after coming, and graphing generates stretching, pressure Contracting and other effects, characteristic area will present mobile phenomenon.
As shown in Figure 5A, if transporting the left side of the direction of motion of at least part of pixel in characteristic area toward characteristic area, It is then overall in characteristic image to distort toward left side;Shown in Fig. 5 B, if the motion side of at least part of pixel in characteristic area Yearn for the right side of characteristic area, then the overall distortion that can turn right in characteristic image.
By the texture mapping of OpenGL, can be by the graphing of the characteristic area near central regions of static images Simulate the simple harmonic motion of spring in summit so that picture is drawn high by the carrying out of rule, produce the shake effect similar to elastic force water polo.
Further, it is at least part of in characteristic area if the direction of motion determines according to the interactive operation event specified The direction of motion of pixel (can such as rock rocking direction, pointing to for event along the corresponding direction of interactive operation event specified There is the direction of screen taps event) characteristic area both sides (as left side and right side, above and below), then transport according to simple harmonic quantity Dynamic model formula and/or damping vibration pattern, the distortion picture that characteristic area is mapped out can be along the interactive operation event correspondence specified Direction distort back and forth, produce shake effect, and final static.
Wherein, the direction that mobile phone shakes may determine that according to sensor, characteristic area can be along shaking in static images The motion of dynamic direction, when equipment or so is aggressively shaken up and down, characteristic area can be around central rotation simulating fierce shake Dynamic effect.
By judging that finger clicks on the position of screen, characteristic area center can be along center and the side of click location To being shaken, when finger is pinned in shake region, and when slidably reciprocating on screen, characteristic area center can follow finger The direction of motion, produces dragged effect, and by micro- dither algorithm so that shake region generation water polo is produced when dragged Slight shake effect, strengthen its physical reality.
For example, equipment rolls or user left and right in characteristic area slidably reciprocates so that in characteristic area extremely Small part pixel does concussion movement in horizontal axis, and the summit of each graphing is in each time in characteristic area Point moves to a position and will generate a distortion picture, and distortion picture is played frame by frame, can produced such as Fig. 5 A and Fig. 5 B institutes The image table in characteristic area shown reveals the dynamic effect of left and right vibrations.
At least part of pixel in characteristic area is carried out texture mapping by the present invention based on the direction of motion, is produced and is included one Frame or the dynamic effect of multiframe distortion picture change, on the one hand, dynamic effect is generated to characteristic area, dynamic effect is reduced Volume, reduces bandwidth occupancy during transmission, and on the other hand convenient transmission, because texture mapping efficiency is very high, reduces generation Dynamic effect it is time-consuming, for picture in network picture or system photograph album etc. can soon produce dynamic effect, soon Speed, be conveniently generated dynamic effect, realizing dynamic effect can be with the real-time interactive of the interbehavior of user.
In a kind of alternative embodiment of the present invention, methods described can also comprise the steps:
Step 104, using the static images and a frame or multiframe warp image dynamic picture is generated.
In embodiments of the present invention, a frame static images can be preserved, and, a frame or multiframe include this feature region Distortion picture, generates dynamic picture, such as GIF.
Relative to traditional GIF, due to reducing the storage for distorting the view data beyond picture, it is possible to reduce Dynamic Graph The volume size of piece.
In a kind of alternative embodiment of the present invention, methods described can also comprise the steps:
Step 105, based on the characteristic area multidate information is generated;
Multidate information can be the configuration information that the characteristic area of static images is mapped to a frame or multiframe warp image, Such as XML (Extensible Markup Language, extendible identifiable language), json (Javascript Object Notation, data interchange language) etc..
The example of the configuration information designed with json can be as follows:
In a kind of alternative embodiment of the present invention, step 105 can include following sub-step:
Sub-step S41, using the characteristic area, the characteristic point and one or more of reference points dynamic letter is generated Breath.
In embodiments of the present invention, characteristic area, characteristic point and one or more reference points can be generated multidate information, To support the generation based on the dynamic effect of reference point.
In a kind of alternative embodiment of the present invention, step 105 can include following sub-step:
Sub-step S42, using the characteristic area and the characteristic area at least part of pixel the direction of motion Generate multidate information.
In embodiments of the present invention, can be by the direction of motion of at least part of pixel in characteristic area, characteristic area Multidate information is generated, to support the generation based on the dynamic effect of the direction of motion.
Step 106, the multidate information and scripting object are write in the static images, to generate dynamic interaction text Part.
In embodiments of the present invention, can be by multidate information, scripting object (such as JS scripts) write static images, can be with Be transferred to network or to other users, can also be stored.
After the scripting object is read, it is possible to use scripting object reflects according to the multidate information to the static images Penetrate, to produce the dynamic effect being change from frame to frame.
For embodiment of the method, in order to be briefly described, therefore it is all expressed as a series of combination of actions, but this area Technical staff should know that the embodiment of the present invention is not limited by described sequence of movement, because according to present invention enforcement Example, some steps can adopt other orders or while carry out.Secondly, those skilled in the art also should know, specification Described in embodiment belong to preferred embodiment, necessary to the involved action not necessarily embodiment of the present invention.
With reference to Fig. 6, a kind of dynamic interaction device reality based on static images according to an embodiment of the invention is shown The structured flowchart of example is applied, specifically can be included such as lower module:
Module 601 is chosen, the selected characteristic region in static images is suitable to;
Determining module 602, is suitable to when the interactive operation event specified is listened to, true according to specified interactive operation event Surely references object is mapped;
Mapping block 603, be suitable to according to it is described mapping references object to the characteristic area at least part of pixel In being mapped to a frame or multiframe distortion picture, to drive the static images to be change from frame to frame.
In a kind of alternative embodiment of the present invention, the interactive operation event specified can include rocking event, institute Stating mapping references object can include one or more reference points;
The determining module 602 can be adapted to:
Direction is rocked according to the event of rocking, one or more reference points are chosen in the characteristic area of static images.
In a kind of alternative embodiment of the present invention, the interactive operation event specified can include screen taps thing Part, the mapping references object can include one or more reference points;
The determining module 602 can be adapted to:
According to the direction for pointing to generation screen taps event, one or more ginsengs are chosen in the characteristic area of static images Examination point.
In a kind of alternative embodiment of the present invention, the characteristic area can have characteristic point;The mapping block 603 Can be adapted to:
The pixel of the static images is mapped to by a frame according to the characteristic point and one or more of reference points Or in multiframe distortion picture.
In a kind of optional example of the embodiment of the present invention, the characteristic area can include convex domain, the characteristic point Focus point can be included.
In a kind of alternative embodiment of the present invention, the mapping block 603 can be adapted to:
Generate distortion picture;
Pixel on the first line in the characteristic area is mapped on the second line;
Copy the pixel on second line to same position in the distortion picture;
Wherein, first line is the line between the characteristic point and marginal point, and second line is current ginseng The line of examination point and marginal point, the marginal point is the coordinate points on the characteristic area edge.
In a kind of alternative embodiment of the present invention, the mapping block 603 can be adapted to:
Calculate the pixel in the characteristic area on the first line, the relative position on the first line;
According to the relative position, the pixel is copied on the second line.
In a kind of alternative embodiment of the present invention, the mapping block 603 can be adapted to:
Pixel outside the characteristic area is mapped to the same position in the distortion picture.
In a kind of alternative embodiment of the present invention, the mapping block 603 can be adapted to:
The pixel of location overlap carries out pixel overlap-add procedure in distorting picture.
In a kind of alternative embodiment of the present invention, the mapping block 603 can be adapted to:
Blank position in distorting picture carries out pixel interpolation processing.
In a kind of alternative embodiment of the present invention, the interactive operation event specified can include rocking event, institute Stating mapping references object can include the direction of motion of at least part of pixel in the characteristic area;The determining module 602 can be adapted to:
Arrange event of rocking rocks the direction of motion that direction is at least part of pixel in the characteristic area.
In a kind of alternative embodiment of the present invention, the Action Events specified can include screen taps event, institute Stating mapping references object can include the direction of motion of at least part of pixel in the characteristic area;The determining module 602 can be adapted to:
The direction for being set to point to generation screen taps event is the motion of at least part of pixel in the characteristic area Direction.
In a kind of alternative embodiment of the present invention, the mapping block 603 can be adapted to:
In the direction of motion, according to preset mode to the characteristic area at least part of pixel carry out texture Mapping, produces the dynamic effect comprising a frame or multiframe distortion picture change.
In a kind of alternative embodiment of the present invention, the mapping block 603 can be adapted to:
The characteristic area is divided into one or more graphings;There are multiple summits in each graphing, each Summit has texture coordinate;
In the direction of motion, the top of each drawing image is moved in one or more time points according to preset mode Point;
For each graphing, using graphic plotting interface according to the texture coordinate on each summit in graphing Pixel carries out texture mapping, produces the dynamic effect comprising a frame or multiframe distortion picture change.
In a kind of alternative embodiment of the present invention, the preset mode can include simple harmonic motion pattern and/or damping Vibration mode;The mapping block 603 can be adapted to:
In the direction of motion, according to simple harmonic motion pattern and/or damping vibration pattern in one or more time points The summit of mobile each drawing image.
In a kind of alternative embodiment of the present invention, the mapping block 603 can be adapted to:
Determine the acceleration on the summit of each drawing image;The summit of each drawing image has original coordinates;
According to the acceleration and/or default damped coefficient, calculating is moved in one or more time points along described Move the displacement on the summit of each drawing image in direction;
The coordinates of targets on the summit of each drawing image is calculated by the original coordinates and the displacement.
In a kind of alternative embodiment of the present invention, described device can also be included such as lower module:
First generation module, is suitable for use with the static images and a frame or multiframe warp image generates Dynamic Graph Piece.
In a kind of alternative embodiment of the present invention, described device can also be included such as lower module:
Second generation module, is suitable to generate multidate information based on the characteristic area;
Writing module, is suitable to the multidate information and scripting object be write in the static images, to generate dynamic friendship Mutual file.
In a kind of alternative embodiment of the present invention, second generation module can be adapted to:
Multidate information is generated using the characteristic area, the characteristic point and one or more of reference points.
In a kind of alternative embodiment of the present invention, second generation module can be adapted to:
The direction of motion of at least part of pixel in using the characteristic area and the characteristic area generates dynamic letter Breath.
For device embodiment, due to itself and embodiment of the method basic simlarity, so description is fairly simple, it is related Part is illustrated referring to the part of embodiment of the method.
Provided herein algorithm and display be not inherently related to any certain computer, virtual system or miscellaneous equipment. Various general-purpose systems can also be used together based on teaching in this.As described above, construct required by this kind of system Structure be obvious.Additionally, the present invention is also not for any certain programmed language.It is understood that, it is possible to use it is various Programming language realizes the content of invention described herein, and the description done to language-specific above is to disclose this Bright preferred forms.
In specification mentioned herein, a large amount of details are illustrated.It is to be appreciated, however, that the enforcement of the present invention Example can be put into practice in the case of without these details.In some instances, known method, structure is not been shown in detail And technology, so as not to obscure the understanding of this description.
Similarly, it will be appreciated that in order to simplify the disclosure and help understand one or more in each inventive aspect, exist Above in the description of the exemplary embodiment of the present invention, each feature of the present invention is grouped together into single enforcement sometimes In example, figure or descriptions thereof.However, the method for the disclosure should be construed to reflect following intention:I.e. required guarantor The more features of feature that the application claims ratio of shield is expressly recited in each claim.More precisely, such as following Claims reflect as, inventive aspect is all features less than single embodiment disclosed above.Therefore, Thus the claims for following specific embodiment are expressly incorporated in the specific embodiment, wherein each claim itself All as the separate embodiments of the present invention.
Those skilled in the art are appreciated that can be carried out adaptively to the module in the equipment in embodiment Change and they are arranged in one or more equipment different from the embodiment.Can be the module or list in embodiment Unit or component are combined into a module or unit or component, and can be divided in addition multiple submodule or subelement or Sub-component.In addition at least some in such feature and/or process or unit is excluded each other, can adopt any Combine to all features disclosed in this specification (including adjoint claim, summary and accompanying drawing) and so disclosed Where all processes or unit of method or equipment are combined.Unless expressly stated otherwise, this specification is (including adjoint power Profit is required, summary and accompanying drawing) disclosed in each feature can it is identical by offers, be equal to or the alternative features of similar purpose carry out generation Replace.
Although additionally, it will be appreciated by those of skill in the art that some embodiments described herein include other embodiments In included some features rather than further feature, but the combination of the feature of different embodiments means in of the invention Within the scope of and form different embodiments.For example, in the following claims, embodiment required for protection appoint One of meaning can in any combination mode using.
The present invention all parts embodiment can be realized with hardware, or with one or more processor operation Software module realize, or with combinations thereof realization.It will be understood by those of skill in the art that can use in practice Microprocessor or digital signal processor (DSP) are realizing the dynamic interaction based on static images according to embodiments of the present invention The some or all functions of some or all parts in equipment.The present invention is also implemented as being retouched here for performing Some or all equipment of the method stated or program of device (for example, computer program and computer program). Such program for realizing the present invention can be stored on a computer-readable medium, or can have one or more signal Form.Such signal can be downloaded from internet website and obtained, or on carrier signal provide, or with it is any its He provides form.
It should be noted that above-described embodiment the present invention will be described rather than limits the invention, and ability Field technique personnel can design without departing from the scope of the appended claims alternative embodiment.In the claims, Any reference symbol between bracket should not be configured to limitations on claims.Word "comprising" is not excluded the presence of not Element listed in the claims or step.Word "a" or "an" before element does not exclude the presence of multiple such Element.The present invention can come real by means of the hardware for including some different elements and by means of properly programmed computer It is existing.If in the unit claim for listing equipment for drying, several in these devices can be by same hardware branch To embody.The use of word first, second, and third does not indicate that any order.These words can be explained and be run after fame Claim.

Claims (40)

1. a kind of dynamic interaction method based on static images, including:
The selected characteristic region in static images;The characteristic area is shape of the user by change regional choice frame, and is selected The regional choice frame is selected for the position of the static images determines;
When the interactive operation event specified is listened to, mapping references object is determined according to specified interactive operation event;
According to it is described mapping references object to the characteristic area at least part of pixel be mapped to a frame or multiframe distortion In picture, to drive the static images to be change from frame to frame.
2. the method for claim 1, it is characterised in that the interactive operation event specified includes rocking event, institute Stating mapping references object includes one or more reference points;
The step of interactive operation event that the basis is specified determines mapping references object includes:
Direction is rocked according to the event of rocking, one or more reference points are chosen in the characteristic area of static images.
3. the method as described in any one of claim 1-2, it is characterised in that the interactive operation event specified includes screen Click event, the mapping references object includes one or more reference points;
The step of interactive operation event that the basis is specified determines mapping references object includes:
According to the direction for pointing to generation screen taps event, one or more references are chosen in the characteristic area of static images Point.
4. method as claimed in claim 3, it is characterised in that the characteristic area has characteristic point;
It is described according to it is described mapping references object to the characteristic area at least part of pixel be mapped to a frame or multiframe In distortion picture, include the step of to drive the static images to be change from frame to frame:
The pixel of the static images is mapped to by a frame or many according to the characteristic point and one or more of reference points In frame distortion picture.
5. method as claimed in claim 4, it is characterised in that the characteristic area includes convex domain, the characteristic point includes Focus point.
6. method as claimed in claim 4, it is characterised in that described according to the characteristic point and one or more of references Step during the pixel of the static images is mapped to a frame or multiframe distortion picture by point includes:
Generate distortion picture;
Pixel on the first line in the characteristic area is mapped on the second line;
Copy the pixel on second line to same position in the distortion picture;
Wherein, first line is the line between the characteristic point and marginal point, and second line is current reference point With the line of marginal point, the marginal point is the coordinate points on the characteristic area edge.
7. method as claimed in claim 6, it is characterised in that the pixel by the first line in the characteristic area The step that point is mapped on the second line includes:
Calculate the pixel in the characteristic area on the first line, the relative position on the first line;
According to the relative position, the pixel is copied on the second line.
8. the method as described in claim 4,6 any one, it is characterised in that it is described according to the characteristic point and it is one or Step during the pixel of the static images is mapped to a frame or multiframe distortion picture by multiple reference points also includes:
Pixel outside the characteristic area is mapped to the same position in the distortion picture.
9. the method as described in claim 4,6 any one, it is characterised in that it is described according to the characteristic point and it is one or Step during the pixel of the static images is mapped to a frame or multiframe distortion picture by multiple reference points also includes:
The pixel of location overlap carries out pixel overlap-add procedure in distorting picture.
10. the method as described in claim 4,6 any one, it is characterised in that described according to the characteristic point and one Or the pixel of the static images is mapped to multiple reference points into a frame or multiframe distorts the step in picture and also includes:
Blank position in distorting picture carries out pixel interpolation processing.
11. the method for claim 1, it is characterised in that the interactive operation event specified includes rocking event, institute Stating mapping references object includes the direction of motion of at least part of pixel in the characteristic area;
The step of interactive operation event that the basis is specified determines mapping references object includes:
Arrange event of rocking rocks the direction of motion that direction is at least part of pixel in the characteristic area.
12. methods as described in claim 1,11 any one, it is characterised in that the interactive operation event specified includes screen Curtain clicks on event, and the mapping references object includes the direction of motion of at least part of pixel in the characteristic area;
The step of interactive operation event that the basis is specified determines mapping references object includes:
The direction for being set to point to generation screen taps event is the direction of motion of at least part of pixel in the characteristic area.
13. methods as claimed in claim 11, it is characterised in that according to the mapping references object in the characteristic area At least part of pixel be mapped in a frame or multiframe distortion picture, wrap the step of to drive the static images to be change from frame to frame Include:
In the direction of motion, according to preset mode to the characteristic area at least part of pixel carry out texture and reflect Penetrate, produce the dynamic effect comprising a frame or multiframe distortion picture change.
14. methods as claimed in claim 13, it is characterised in that described in the direction of motion, according to preset mode pair At least part of pixel in the characteristic area carries out texture mapping, produces comprising moving that a frame or multiframe distortion picture change The step of state effect, includes:
The characteristic area is divided into one or more graphings;There is multiple summits, each summit in each graphing With texture coordinate;
In the direction of motion, the summit of each drawing image is moved in one or more time points according to preset mode;
For each graphing, using graphic plotting interface according to the texture coordinate on each summit to the pixel in graphing Point carries out texture mapping, produces the dynamic effect comprising a frame or multiframe distortion picture change.
15. methods as claimed in claim 14, it is characterised in that the preset mode includes simple harmonic motion pattern and/or resistance Buddhist nun's vibration mode;
It is described in the direction of motion, the summit of each drawing image is moved in one or more time points according to preset mode The step of include:
In the direction of motion, according to simple harmonic motion pattern and/or damping vibration pattern in one or more time point movements The summit of each drawing image.
16. methods as claimed in claim 15, it is characterised in that described in the direction of motion, according to simple harmonic motion pattern And/or damping vibration pattern includes the step of the summit of each drawing image is moved in one or more time points:
Determine the acceleration on the summit of each drawing image;The summit of each drawing image has original coordinates;
According to the acceleration and/or default damped coefficient, calculate in one or more time points along the direction of motion The displacement on the summit of mobile each drawing image;
The coordinates of targets on the summit of each drawing image is calculated by the original coordinates and the displacement.
17. methods as described in claim 1,16 any one, it is characterised in that also include:
Dynamic picture is generated using the static images and a frame or multiframe warp image.
18. methods as claimed in claim 4, it is characterised in that also include:
Multidate information is generated based on the characteristic area;
The multidate information and scripting object are write in the static images, to generate dynamic interaction file.
19. methods as claimed in claim 18, it is characterised in that the step that multidate information is generated based on the characteristic area Suddenly include:
Multidate information is generated using the characteristic area, the characteristic point and one or more of reference points.
20. methods as described in claim 18,19 any one, it is characterised in that described generation based on the characteristic area is moved The step of state information, includes:
The direction of motion of at least part of pixel in using the characteristic area and the characteristic area generates multidate information.
A kind of 21. dynamic interaction devices based on static images, including:
Module is chosen, the selected characteristic region in static images is suitable to;The characteristic area is user by changing regional choice The shape of frame, and select the regional choice frame to determine for the position of the static images;
Determining module, is suitable to, when the interactive operation event specified is listened to, according to specified interactive operation event mapping be determined References object;
Mapping block, be suitable to according to it is described mapping references object to the characteristic area at least part of pixel be mapped to one In frame or multiframe distortion picture, to drive the static images to be change from frame to frame.
22. devices as claimed in claim 21, it is characterised in that the interactive operation event specified includes rocking event, The mapping references object includes one or more reference points;
The determining module is further adapted for:
Direction is rocked according to the event of rocking, one or more reference points are chosen in the characteristic area of static images.
23. devices as described in any one of claim 21-22, it is characterised in that the interactive operation event specified includes Screen taps event, the mapping references object includes one or more reference points;
The determining module is further adapted for:
According to the direction for pointing to generation screen taps event, one or more references are chosen in the characteristic area of static images Point.
24. devices as claimed in claim 23, it is characterised in that the characteristic area has characteristic point;The mapping block It is further adapted for:
The pixel of the static images is mapped to by a frame or many according to the characteristic point and one or more of reference points In frame distortion picture.
25. devices as claimed in claim 24, it is characterised in that the characteristic area includes convex domain, the characteristic point bag Include focus point.
26. devices as claimed in claim 24, it is characterised in that the mapping block is further adapted for:
Generate distortion picture;
Pixel on the first line in the characteristic area is mapped on the second line;
Copy the pixel on second line to same position in the distortion picture;
Wherein, first line is the line between the characteristic point and marginal point, and second line is current reference point With the line of marginal point, the marginal point is the coordinate points on the characteristic area edge.
27. devices as claimed in claim 26, it is characterised in that the mapping block is further adapted for:
Calculate the pixel in the characteristic area on the first line, the relative position on the first line;
According to the relative position, the pixel is copied on the second line.
28. devices as described in claim 24,26 any one, it is characterised in that the mapping block is further adapted for:
Pixel outside the characteristic area is mapped to the same position in the distortion picture.
29. devices as described in claim 24,26 any one, it is characterised in that the mapping block is further adapted for:
The pixel of location overlap carries out pixel overlap-add procedure in distorting picture.
30. devices as described in claim 24,26 any one, it is characterised in that the mapping block is further adapted for:
Blank position in distorting picture carries out pixel interpolation processing.
31. devices as claimed in claim 21, it is characterised in that the interactive operation event specified includes rocking event, The mapping references object includes the direction of motion of at least part of pixel in the characteristic area;
The determining module is further adapted for:
Arrange event of rocking rocks the direction of motion that direction is at least part of pixel in the characteristic area.
32. the device as described in claim 21,31 any one, it is characterised in that the interactive operation event specified includes Screen taps event, the mapping references object includes the direction of motion of at least part of pixel in the characteristic area;
The determining module is further adapted for:
The direction for being set to point to generation screen taps event is the direction of motion of at least part of pixel in the characteristic area.
33. devices as claimed in claim 31, it is characterised in that mapping block is further adapted for:
In the direction of motion, according to preset mode to the characteristic area at least part of pixel carry out texture and reflect Penetrate, produce the dynamic effect comprising a frame or multiframe distortion picture change.
34. devices as claimed in claim 33, it is characterised in that the mapping block is further adapted for:
The characteristic area is divided into one or more graphings;There is multiple summits, each summit in each graphing With texture coordinate;
In the direction of motion, the summit of each drawing image is moved in one or more time points according to preset mode;
For each graphing, using graphic plotting interface according to the texture coordinate on each summit to the pixel in graphing Point carries out texture mapping, produces the dynamic effect comprising a frame or multiframe distortion picture change.
35. devices as claimed in claim 34, it is characterised in that the preset mode includes simple harmonic motion pattern and/or resistance Buddhist nun's vibration mode;The mapping block is further adapted for:
In the direction of motion, according to simple harmonic motion pattern and/or damping vibration pattern in one or more time point movements The summit of each drawing image.
36. devices as claimed in claim 35, it is characterised in that the mapping block is further adapted for:
Determine the acceleration on the summit of each drawing image;The summit of each drawing image has original coordinates;
According to the acceleration and/or default damped coefficient, calculate in one or more time points along the direction of motion The displacement on the summit of mobile each drawing image;
The coordinates of targets on the summit of each drawing image is calculated by the original coordinates and the displacement.
37. devices as described in claim 21,36 any one, it is characterised in that also include:
First generation module, is suitable for use with the static images and a frame or multiframe warp image generates dynamic picture.
38. devices as claimed in claim 24, it is characterised in that also include:
Second generation module, is suitable to generate multidate information based on the characteristic area;
Writing module, is suitable to the multidate information and scripting object be write in the static images, to generate dynamic interaction text Part.
39. devices as claimed in claim 38, it is characterised in that second generation module is further adapted for:
Multidate information is generated using the characteristic area, the characteristic point and one or more of reference points.
40. devices as described in claim 38,39 any one, it is characterised in that second generation module is further adapted for:
The direction of motion of at least part of pixel in using the characteristic area and the characteristic area generates multidate information.
CN201410855538.0A 2014-12-31 2014-12-31 Static picture based dynamic interaction method and device Active CN104571887B (en)

Priority Applications (2)

Application Number Priority Date Filing Date Title
CN201410855538.0A CN104571887B (en) 2014-12-31 2014-12-31 Static picture based dynamic interaction method and device
PCT/CN2015/095933 WO2016107356A1 (en) 2014-12-31 2015-11-30 Static picture-based dynamic interaction method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201410855538.0A CN104571887B (en) 2014-12-31 2014-12-31 Static picture based dynamic interaction method and device

Publications (2)

Publication Number Publication Date
CN104571887A CN104571887A (en) 2015-04-29
CN104571887B true CN104571887B (en) 2017-05-10

Family

ID=53088092

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201410855538.0A Active CN104571887B (en) 2014-12-31 2014-12-31 Static picture based dynamic interaction method and device

Country Status (1)

Country Link
CN (1) CN104571887B (en)

Families Citing this family (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2016107356A1 (en) * 2014-12-31 2016-07-07 北京奇虎科技有限公司 Static picture-based dynamic interaction method and device
CN106022424B (en) * 2016-05-10 2019-04-26 腾讯科技(深圳)有限公司 Generate the method and device with the two-dimension code image of dynamic effect
CN109587390B (en) * 2017-09-29 2021-05-07 腾讯科技(深圳)有限公司 Picture rendering method, picture rendering device and storage medium
CN112396671B (en) * 2019-08-16 2024-01-30 北京字节跳动网络技术有限公司 Water ripple effect realization method and device, electronic equipment and computer readable storage medium
CN110580691A (en) * 2019-09-09 2019-12-17 京东方科技集团股份有限公司 dynamic processing method, device and equipment of image and computer readable storage medium
US20220028141A1 (en) * 2019-09-09 2022-01-27 Boe Technology Group Co., Ltd. Method and device of dynamic processing of image and computer-readable storage medium
CN113287087A (en) * 2019-12-19 2021-08-20 京东方科技集团股份有限公司 Computer-implemented method of implementing dynamic effects in images, apparatus and computer program product for implementing dynamic effects in images
CN112164121B (en) * 2020-09-30 2021-11-23 北京完美赤金科技有限公司 Tearing effect graph generation method and device, storage medium and electronic device
CN116501227B (en) * 2023-06-26 2023-11-07 北京达佳互联信息技术有限公司 Picture display method and device, electronic equipment and storage medium

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102411791A (en) * 2010-09-19 2012-04-11 三星电子(中国)研发中心 Method and equipment for dynamic still image
CN103971391A (en) * 2013-02-01 2014-08-06 腾讯科技(深圳)有限公司 Animation method and device

Family Cites Families (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101446883B (en) * 2008-12-02 2011-11-23 宇龙计算机通信科技(深圳)有限公司 Method for controlling mobile equipment by touch screen and mobile equipment
KR101184876B1 (en) * 2010-02-11 2012-09-20 삼성전자주식회사 Apparatus and method for creating character's dynamic effect related to image contents
RU2481640C1 (en) * 2011-12-01 2013-05-10 Корпорация "Самсунг Электроникс Ко., Лтд" Method and system of generation of animated art effects on static images
CN103473799B (en) * 2013-09-02 2016-09-14 腾讯科技(深圳)有限公司 The method for dynamically processing of a kind of picture and device, terminal unit

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102411791A (en) * 2010-09-19 2012-04-11 三星电子(中国)研发中心 Method and equipment for dynamic still image
CN103971391A (en) * 2013-02-01 2014-08-06 腾讯科技(深圳)有限公司 Animation method and device

Also Published As

Publication number Publication date
CN104571887A (en) 2015-04-29

Similar Documents

Publication Publication Date Title
CN104571887B (en) Static picture based dynamic interaction method and device
US8610714B2 (en) Systems, methods, and computer-readable media for manipulating graphical objects
US9691172B2 (en) Furry avatar animation
CN104574484B (en) A kind of method and apparatus producing picture dynamic effect based on interactive operation
US10403035B2 (en) Rendering images using ray tracing with multiple light sources
US9723204B2 (en) Dynamic motion path blur kernel
TW201108152A (en) Displaying a visual representation of performance metrics for rendered graphics elements
CN109844820A (en) The hand that hologram is modified based on contextual information is blocked
US11757997B2 (en) Systems and methods for facilitating shared extended reality experiences
US9955065B2 (en) Dynamic motion path blur user interface
WO2014188235A1 (en) Creation of a cinemagraph file
CN104574473B (en) Method and device for generating dynamic effect on basis of static image
US9779484B2 (en) Dynamic motion path blur techniques
Otten et al. Illustrative white matter fiber bundles
Yan et al. A non-photorealistic rendering method based on Chinese ink and wash painting style for 3D mountain models
CN104574483A (en) Method and device for generating customizable dynamic graphs
WO2022026603A1 (en) Object recognition neural network training using multiple data sources
Levkowitz et al. Cloud and mobile web-based graphics and visualization
Ohkawara et al. Experiencing GPU path tracing in online courses
CN116129057A (en) Virtual system for dynamically displaying three-dimensional fine flow field structure and flow field generation method
Zhao et al. Visual analysis of three-dimensional flow field based on WebVR
WO2016107356A1 (en) Static picture-based dynamic interaction method and device
Schweiß et al. Towards Collaborative Analysis of Computational Fluid Dynamics using Mixed Reality.
Hildebrandt et al. Image-based strategies for interactive visualisation of complex 3D geovirtual environments on lightweight devices
Alharbi et al. Interactive Holographic 4D Visualization Multidimensional Structured Grid Data

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
GR01 Patent grant
TR01 Transfer of patent right

Effective date of registration: 20220718

Address after: Room 801, 8th floor, No. 104, floors 1-19, building 2, yard 6, Jiuxianqiao Road, Chaoyang District, Beijing 100015

Patentee after: BEIJING QIHOO TECHNOLOGY Co.,Ltd.

Address before: 100088 room 112, block D, 28 new street, new street, Xicheng District, Beijing (Desheng Park)

Patentee before: BEIJING QIHOO TECHNOLOGY Co.,Ltd.

Patentee before: Qizhi software (Beijing) Co.,Ltd.

TR01 Transfer of patent right