CN113192160A - Method for realizing slide switching effect, storage medium and computer - Google Patents

Method for realizing slide switching effect, storage medium and computer Download PDF

Info

Publication number
CN113192160A
CN113192160A CN202110529336.7A CN202110529336A CN113192160A CN 113192160 A CN113192160 A CN 113192160A CN 202110529336 A CN202110529336 A CN 202110529336A CN 113192160 A CN113192160 A CN 113192160A
Authority
CN
China
Prior art keywords
picture
frame
content display
slide
area
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202110529336.7A
Other languages
Chinese (zh)
Inventor
江宝歆
于正国
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Yozosoft Co ltd
Original Assignee
Yozosoft 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 Yozosoft Co ltd filed Critical Yozosoft Co ltd
Publication of CN113192160A publication Critical patent/CN113192160A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T11/002D [Two Dimensional] image generation
    • G06T11/60Editing figures and text; Combining figures or text
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F40/00Handling natural language data
    • G06F40/10Text processing
    • G06F40/166Editing, e.g. inserting or deleting

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Health & Medical Sciences (AREA)
  • Artificial Intelligence (AREA)
  • Audiology, Speech & Language Pathology (AREA)
  • Computational Linguistics (AREA)
  • General Health & Medical Sciences (AREA)
  • General Engineering & Computer Science (AREA)
  • Controls And Circuits For Display Device (AREA)
  • Studio Circuits (AREA)

Abstract

The invention discloses a method for realizing a slide switching effect, a storage medium and a computer, wherein the method comprises the following steps: analyzing the slide objects and combining the slide objects into a picture; after the picture is reduced, all pixel points are obtained and transmitted to a processor for processing; calculating the total frame number of pictures to be processed; determining a transparent area, a fuzzy gradual change area and a content display area of a first frame of picture; setting corresponding pixel points processed by a processor in the fuzzy gradual change area of the first frame of picture; setting a picture part corresponding to the original image object before reduction in a first frame picture content display area; and directly drawing a first frame of picture, determining a transparent area, a fuzzy gradual change area and a content display area of the next frame of picture according to the frame number index, and repeating the steps until all pictures are drawn. The application makes the slide have the fuzzy shade effect when switching to when guaranteeing the definition that slide content display region internal content shows, can also obviously promote the smoothness degree when slide switches the effect and plays.

Description

Method for realizing slide switching effect, storage medium and computer
Technical Field
The invention relates to the technical field of slide switching, in particular to a method for realizing a fuzzy mask type slide switching effect, a storage medium and a computer.
Background
The slide multi-finger electronic slide is also called presentation and brief, and is a playable file made up of characters and pictures with some special effect dynamic display effect. To achieve better presentation, different switching effects are often added while the slide show is being performed. Office draws a processed picture when the slide show switching effect is displayed, and then displays the picture in a frame mode, so that the corresponding switching effect is generated. Slide show switching effects are very diverse and include some fuzzy mask type slide show switching effects such as segmentation, erasure, shape, etc. The fuzzy shade type slide switching effect means that in the process of switching slides, an effect of gradually displaying the next slide according to a certain rule can be generated, the edge of the content of each displayed frame of picture can form a fuzzy gradual change effect, and along with the sequential display of all pictures, a fuzzy gradual change area on the previous slide can be gradually moved or expanded according to a certain rule to form the switching effect of the next slide. However, Java is too slow when processing large pictures, and if it directly processes the original picture, it is easy to cause a pause phenomenon during showing, thereby affecting the switching effect of switching slides. If the picture size is reduced for processing, the phenomenon that the mosaic is serious during showing can occur. Therefore, it is necessary to increase the speed of processing pictures and ensure that the picture quality is not too poor.
Disclosure of Invention
The invention aims to provide a method for realizing the switching effect of a fuzzy mask type slide, which comprises the steps of analyzing slide objects, combining the slide objects into a picture, and then zooming and processing the picture. And dividing each frame of picture into a transparent area, a fuzzy gradual change area and a content display area according to the switching effect, drawing pixel points corresponding to the zoomed picture in the fuzzy gradual change area and drawing the corresponding part of the zoomed picture in the content display area when each frame of picture is played. The method can ensure the definition of content display in the slide content display area and can also obviously improve the smoothness of playing the slide switching effect. Meanwhile, a storage medium and a computer suitable for the implementation method are also provided. The specific technical scheme is as follows:
the invention provides a method for realizing the switching effect of a fuzzy mask type slide, which comprises the following steps:
analyzing the current slide object, and combining the slide objects into a cache picture object; the picture object is reduced, and all pixel points of the reduced picture object are acquired and transmitted to the processor for processing; calculating the total frame number of the pictures to be processed according to the switching effect type and the set duration; determining a transparent area, a fuzzy gradual change area and a content display area of the first frame of picture according to the switching effect type; setting corresponding pixel points processed by a processor in a fuzzy gradual change area of a first frame of picture; setting a corresponding picture part of the original image object before reduction in a content display area of the first frame picture; and returning the first frame of picture to the showing module for direct drawing, determining a transparent area, a fuzzy gradual change area and a content display area of the next frame of picture according to the frame number index, and repeating the previous steps until the drawing of all the frame pictures is completed.
Furthermore, the reduced picture objects can be smoothly processed in Java.
Further, the picture object size is reduced to 1/2 to 1/10 of the original picture object size.
Further, when the original image object is set in the content display area of each frame of picture, the processor cuts the original image object into a shape matching the shape of the content display area, and then draws the original image object part obtained by cutting into the content display area.
Further, after the total number of the pictures to be processed is determined, the increment of the fuzzy gradual change area of each frame of picture is calculated according to the switching effect type and the set duration.
Furthermore, when the corresponding pixel points processed by the processor are arranged in the fuzzy gradual change area of each frame of picture, the processor calculates the transparency values of all the pixel points, and a display effect that the transparency of the pixel points gradually becomes smaller from the content display area to the transparent area is formed in the fuzzy gradual change area.
The invention also provides a storage medium, which stores program instructions, and the program instructions are executed to execute the method for realizing the fuzzy mask type slide switching effect.
The invention also provides a storage medium which comprises a processor and a memory, wherein the memory is stored with program instructions, and the processor executes the program instructions to execute the implementation method of the blur mask type slide switching effect.
The implementation method of the fuzzy shade type slide switching effect enables the slide to have the fuzzy shade effect during switching, ensures the definition of content display in a slide content display area, and can also obviously improve the smoothness of the slide switching effect during playing.
Drawings
Fig. 1 is a flowchart illustrating a method for implementing a fuzzy mask type slide switching effect according to an embodiment of the present invention.
Detailed Description
To further explain the technical means and effects of the present invention adopted to achieve the predetermined objects, the following detailed description of the embodiments, structures, features and effects according to the present invention will be given with reference to the accompanying drawings and preferred embodiments.
Referring to fig. 1, fig. 1 is a schematic flowchart illustrating a method for implementing a fuzzy mask type slide switching effect according to an embodiment of the present invention.
The embodiment provides a method for realizing a fuzzy mask type slide switching effect, which comprises the following steps:
analyzing the current slide object, and combining the slide objects into a cache picture object;
the picture object is reduced, and all pixel points of the reduced picture object are acquired and transmitted to the processor for processing;
calculating the total frame number of the pictures to be processed according to the switching effect type and the set duration;
determining a transparent area, a fuzzy gradual change area and a content display area of the first frame of picture according to the switching effect type;
setting corresponding pixel points processed by a processor in a fuzzy gradual change area of a first frame of picture;
setting a corresponding picture part of the original image object before reduction in a content display area of the first frame picture;
and returning the first frame of picture to the showing module for direct drawing, determining a transparent area, a fuzzy gradual change area and a content display area of the next frame of picture according to the frame number index, and repeating the previous steps until the drawing of all the frame pictures is completed.
In a further embodiment, the scaled down picture objects can be processed smoothly in Java.
In a further embodiment, the picture object size is reduced to 1/2 through 1/10 of the original picture object size. Preferably 1/6.
In a further embodiment, when the original image object is set in the content display area of each frame of picture, the processor cuts the original image object into a shape matching the shape of the content display area, and then draws the original image object obtained by cutting into the content display area.
In a further embodiment, after the total number of frames of pictures needing to be processed is determined, the increment of the fuzzy gradual change area of each frame of picture is calculated according to the switching effect type and the set duration.
In a further embodiment, when the corresponding pixel points processed by the processor are arranged in the fuzzy gradual change region of each frame of picture, the processor calculates the transparency values of all the pixel points, and a display effect that the transparency of the pixel points gradually decreases from the content display region to the transparent region is formed in the fuzzy gradual change region.
It should be noted that, the pixel point of the whole picture is transmitted (the pixel point acquisition method can be directly obtained by java) into the filter processor (java entity class), the pixel point is of argb type, and represents that the pixel point is formed by combining a, r, g and b, wherein a represents the transparency of the pixel point, r represents the red intensity of the pixel point, g represents the green intensity of the pixel point, and b represents the blue intensity of the pixel point.
And determining the transparency intensity (0-255) of the pixel point according to the current frame number and the fuzzy gradual change region. For example, the position of the fuzzy gradual change region is calculated according to the total number of frames in the first frame with the erasing effect (from left to right), and the weight of the transparency is calculated at the pixel point in the fuzzy gradual change region, and the calculation formula is as follows:
factor=(x-start)/(end-start);
wherein, x is the position of the pixel point in the horizontal direction on a coordinate axis which takes the upper left corner of the picture as the origin of a coordinate system; the start is the starting position of the fuzzy gradual change area in the horizontal direction on a coordinate axis which takes the upper left corner of the picture as the origin of a coordinate system; end is the horizontal end position of the fuzzy gradual change area on the coordinate axis which takes the upper left corner of the picture as the origin of the coordinate system.
And finally, calculating a value a according to the weight, wherein a is factor 255. Combining a new argb value according to the calculated a value and the r, g and b values before the pixel point, replacing the original argb value of the pixel point with a target argb value, after all the pixel points are processed according to the method, adopting the original image shearing method of the text for the image outside the fuzzy gradient area, namely in the content display area, and after all the processing is finished, transmitting the processed image to a showing module by a processor for drawing.
The method comprises the following specific steps:
the first step is to obtain the current slide object, combine the slide objects into a cache picture object, reduce the picture to the size that java can smoothly process, take out all pixel points of the picture, and transmit the pixel points into a processor.
And secondly, calculating the number of the picture frames to be processed according to the switching effect type selected by the user and the set duration.
And thirdly, determining the initial area of the pixel points to be processed of the picture according to the effect type, setting the processed pixel points transmitted in the previous step into the picture, returning the picture to a projection module for direct drawing, and simultaneously determining the pixel point change area of the next frame according to the frame number index.
And fourthly, when the picture is processed to be excessively blurred (due to the reduction of the picture), cutting the original picture which is not zoomed by the slide object in the first step into a shape required by the effect through a processor, drawing the original picture out of the picture processing area, and returning the picture to the showing module for drawing after the original picture is finished.
And fifthly, repeating the third step and the fourth step until all the frame pictures are finished.
The invention provides some special handling of the switching effects, such as: segmentation, erasure, shape, etc. The following further explains the erasing effect as an example:
the first step is as follows: and taking the picture combined by the current slide object, reducing the picture to a proper size, taking out a pixel set of the picture, and transmitting the pixel set to the processor.
The second step is that: the total frame number is determined according to time, in order to ensure the fluency of the picture, the total frame number is generally 30 frames per second (namely 30 pictures are processed and drawn in one second, if the size of the pictures is too large, java1 seconds can only process about 5 pictures), and after the total frame number is determined, the increment of the fuzzy mask range of each frame of picture is calculated.
The third step: and (3) processing the transparency values of the pixel points independently and setting the transparency values into the picture, and if the picture has an overlarge mosaic area, cutting parts of the original picture into the picture area beyond the fuzzy area through a processor.
And fourthly, drawing the current frame and processing the picture of the next frame.
And fifthly, repeating the third step and the fourth step until the effect playing is finished.
The present disclosure also provides a storage medium storing program instructions, which are executed to implement the method for switching a blur mask type slide show.
The present disclosure also provides a storage medium, which includes a processor and a memory, where the memory stores program instructions, and the processor executes the program instructions to execute the method for implementing the blur mask type slide switching effect.
As used herein, the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, including not only those elements listed, but also other elements not expressly listed.
In this document, the terms front, back, upper and lower are used to define the components in the drawings and the positions of the components relative to each other, and are used for clarity and convenience of the technical solution. It is to be understood that the use of the directional terms should not be taken to limit the scope of the claims.
The features of the embodiments and embodiments described herein above may be combined with each other without conflict.
The above description is only for the purpose of illustrating the preferred embodiments of the present invention and is not to be construed as limiting the invention, and any modifications, equivalents, improvements and the like that fall within the spirit and principle of the present invention are intended to be included therein.

Claims (8)

1. A method for implementing a slide show switching effect, comprising:
analyzing the current slide object, and combining the slide objects into a cache picture object;
the picture object is reduced, and all pixel points of the reduced picture object are acquired and transmitted to the processor for processing;
calculating the total frame number of the pictures to be processed according to the switching effect type and the set duration;
determining a transparent area, a fuzzy gradual change area and a content display area of the first frame of picture according to the switching effect type;
setting corresponding pixel points processed by a processor in a fuzzy gradual change area of a first frame of picture;
setting a corresponding picture part of the original image object before reduction in a content display area of the first frame picture;
and returning the first frame of picture to the showing module for direct drawing, determining a transparent area, a fuzzy gradual change area and a content display area of the next frame of picture according to the frame number index, and repeating the previous steps until the drawing of all the frame pictures is completed.
2. The method of claim 1, wherein the scaled down picture objects can be processed smoothly in Java.
3. A method for implementing a slide show effect as claimed in claim 1, wherein the picture object size is reduced to 1/2 through 1/10 of the original picture object size.
4. The method of claim 1, wherein when the original image object is disposed in the content display area of each frame of the picture, the processor cuts the original image object into a shape matching the shape of the content display area, and then draws a portion of the original image object obtained by the cutting into the content display area.
5. The method of claim 1, wherein after determining the total number of frames of pictures to be processed, the delta of the fuzzy gradual change area of each frame of picture is calculated according to the type of the switching effect and the set duration.
6. The method of claim 1, wherein when corresponding pixels are disposed in the fuzzy gradual change region of each frame of picture after being processed by the processor, the processor calculates transparency values of all the pixels, and a display effect is formed in the fuzzy gradual change region in which the transparency of the pixels gradually decreases from the content display region to the transparent region.
7. A storage medium storing program instructions which are executed to perform a method of implementing a slide show effect according to any one of claims 1 to 6.
8. A computer, characterized in that it comprises a processor and a memory, in which program instructions are stored, which program instructions are executed by the processor to perform a method of implementing a slide show effect according to any one of claims 1 to 6.
CN202110529336.7A 2020-05-15 2021-05-14 Method for realizing slide switching effect, storage medium and computer Pending CN113192160A (en)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN202010410873 2020-05-15
CN2020104108735 2020-05-15

Publications (1)

Publication Number Publication Date
CN113192160A true CN113192160A (en) 2021-07-30

Family

ID=76981736

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202110529336.7A Pending CN113192160A (en) 2020-05-15 2021-05-14 Method for realizing slide switching effect, storage medium and computer

Country Status (1)

Country Link
CN (1) CN113192160A (en)

Similar Documents

Publication Publication Date Title
CN110650368B (en) Video processing method and device and electronic equipment
US6717586B2 (en) Apparatus, method, program code, and storage medium for image processing
US6975329B2 (en) Depth-of-field effects using texture lookup
JP2003271125A (en) Device, method and program for image display
JP2008501170A (en) Method and system for viewing and enhancing images
US9684990B2 (en) Method and terminal for displaying an animation
EP1223559A2 (en) Drawing method on two-dimensional screen
CN113469883B (en) Rendering method and device of dynamic resolution, electronic equipment and readable storage medium
CN109302629B (en) Method for switching picture frames for pictures and display terminal
US8633941B2 (en) Image-processing apparatus, method for controlling thereof, and computer program
JP4183082B2 (en) 3D image drawing apparatus and 3D image drawing method
JP6947939B2 (en) Image generator, image generation method and program
JP2003066943A (en) Image processor and program
JP2001250127A (en) Computer-readable recording medium with recorded program for three-dimensional computer image processing, shading drawing method, and video game device
CN113192160A (en) Method for realizing slide switching effect, storage medium and computer
CN117205553A (en) Information processing method and device and electronic equipment
CN109859303B (en) Image rendering method and device, terminal equipment and readable storage medium
JP2001126086A (en) Method and device for displaying three-dimensional model in video game, game machine, and computer- readable recording medium storing three-dimensional model displaying program for video game
CN106909283A (en) Painting canvas display control method and system
US10114447B2 (en) Image processing method and apparatus for operating in low-power mode
CN115421641A (en) Special effect animation method for transverse movement of android card and implementation device thereof
EP3836091A1 (en) Alpha value decision device, alpha value decision method, program, and data structure of image data
CN113923379B (en) Multi-picture synthesis method and processing terminal for self-adaptive window
CN112583976B (en) Graphic code display method, equipment and readable storage medium
CN112346614B (en) Image display method and device, electronic device, and storage medium

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination