Import video as animation material
We can import a video as animation material by using the [File>Import>Video Frames to Layer] command. This command requires QuickTime 7.1 or above to be installed in the system before it can be used. Otherwise, a warning box will appear as shown in the figure below. QuickTime is an excellent encoding method for videos created by Apple. In the early years, it could only be used in MAC OS systems. Now it has been ported to Windows systems. A free version of the player can be downloaded from Apple's website at http://www.apple.com.cn/quicktime.
We edited a self-shot animal video into a short version through Premiere and provided it for everyone to practice importing. After entering the dialog box for importing video frames into layers, the dialog box shown on the left is shown below. On the left, you can choose to import all or only a certain segment. There is no need to explain in detail if all are imported. To import clips, you need to define the video range in advance. The method is to drag the playback progress bar to the starting moment of the desired clip (red arrow), then hold down the SHIFT key and continue dragging to the end moment (green arrow). You can also hold down SHIFT. Click directly on the end position. At this time, a dark area will appear on the playback progress bar, which is the clip to be imported.
After confirmation, an animation that exists as an independent layer will be created, that is, each frame is composed of one layer, and different layers are displayed in different frames. The animation palette looks like the picture below.
The number of animation bytes generated by this video import method is usually very large, which is related to the length of the clip and the frame rate of the video. For example, if the clip duration is 10 seconds and the frame rate is 15fps, then the total number of frames generated is 150 frames, which is quite large. Therefore, it is generally not advisable to import for too long. Two or three seconds is enough. But for some high frame rate videos (such as 24fps, 30fps), the total number of frames generated in this time is also considerable. At this time, you can turn on "Limit to every 2 frames", so that the original video is limited to every 2 frames. By importing one frame at a time, the total number of frames generated is reduced by half. If set to every 3 frames, the total number of frames is reduced by two-thirds, and so on. This method is called frame extraction. It can effectively reduce the number of animation bytes, but due to the average extraction, some action details may be lost or the picture may jump.
Under normal circumstances, the original video of 15fps can be imported every 3 frames to form an animation of 5 frames per second. The higher rate raw video can be deduced accordingly. Note that after importing, you need to adjust the frame dwell time to 3 times the original, otherwise there will be a playback effect similar to fast forward.
Reduce the size of imported animations
For imported animations, to reduce the number of bytes, adjustments need to be made in terms of image size and number of colors. What I need to remind everyone here is that using [Image>Image Size] [CTRL+ALT+I] to reduce the image may cause the edges of some originally sharp-edged images to become blurred due to pixel reorganization, thus increasing the number of theoretical colors. As shown in the figure below, the theoretical color number comparison of a square with sharp edges before and after shrinkage can be seen. It can be seen that the number of colors has increased due to pixel reorganization. In this case, the reduced image may not necessarily have a smaller byte count. Unless the color number is forced to be the same as the former. But forcibly reducing the number of colors may result in burr edges.
Furthermore, some process images are mainly composed of points, lines, and frames. Using the zoom out command will make these details difficult to identify, thus affecting expression. This problem not only occurs for the entire image, but also occurs in the Free Transform command for certain layers. Therefore, for some images with sharp edges, shrinking is not a good way to reduce the number of bytes, and may even be counterproductive.
For videos, because most video encoding methods focus on expressing the smoothness between frames rather than the picture quality of a single frame, they themselves cannot perfectly record sharp edges. The same is true for imported animation pictures, so reducing the size causes The loss and change in color quantity are not obvious.
In addition to reducing the overall image size, you can also consider using the crop command to retain parts of the video. Since it does not involve pixel reorganization, it will not affect the edges of the image and will not increase the number of theoretical colors. In most cases, this is a better solution. As shown in the figure below, a common processing flow is to cut some unnecessary areas in the original picture into squares to obtain the main body of the animation, and then reduce the image to the common size of MMS 128×128 (or other required sizes). Finally, add a color adjustment layer as appropriate to improve the color of the animation.
Note that the adjustment layer must be above all layers to ensure that it is effective for all layers. Of course, it can also be placed on other levels to create the effect of color changes in animation.
After clarifying the screen layout of the animation, further frame extraction can be performed manually, as shown in the figure below. If you need to reduce 10 frames in a process to 5 frames, you can select 2, 4, 6, 8, and 10 frames respectively. Delete and delay the remaining frames. This requires you to first browse each frame. When you find that there is not much change between frames in a certain process, you can use this method to perform average extraction. In addition, you can also continuously select certain frames for concentrated extraction. For example, it takes 7 frames for an object to fall, and the changes in the 4 frames are not very big. You can delete them together and change the duration of the remaining frames.
This method of manually extracting frames is slow and requires a certain amount of experience, but it is more flexible. Different extraction methods can be adopted according to the actual situation, which can greatly reduce the number of bytes of the animation. This is knowledge that everyone must master. If you try more often, you can still undo it anyway. After detaching, it is best to output the animation to a web page or mobile phone for viewing effect. Manual frame extraction can also be performed before modifying the image size or cropping, but cropping and changing the size can determine the picture condition of the animation, so it is recommended that you do it at this time. After detaching a frame, you can delete the corresponding layer.
Average extraction can be performed multiple times. In the final animation frame in the figure below, frames 2 and 4 can also be extracted. But frame 6 is very important. It is the key to plot transformation and cannot be taken away from it under any circumstances. As a digression, pay attention to this 6th frame, and you will see the motion blur effect that you have learned before. In fact, motion blur is originally caused by photography equipment, and we just simulated it before.
It is more difficult to reduce the number of bytes in terms of the number of colors, because due to the characteristics of the video encoding method, even objects that are stationary in the picture may have different colors in the previous and next frames. Coupled with the slight changes in lighting and camera aperture, focal length, and exposure, it is even more difficult to have the same color between the previous and later frames. This is completely different from the animation we used to create objects through drawing. Moreover, video images often contain transitional colors, such as changes in lighting or shadows. Reducing the number of colors can easily cause color spots. Although turning on dithering can improve color spots, it will also increase the number of bytes.
At this time, you can consider displaying the animation in grayscale, that is, establishing a black and white gradient mapping adjustment layer. The loss caused by reducing the number of colors in grayscale mode is less noticeable. You can also use the threshold command to form a clear black and white image, and use it with a solid color fill layer in a special blending mode to create a special artistic effect while reducing the number of bytes. Click here to download the sample PSD file .
The image created by the Threshold command has strong contrasting colors, which is very suitable for creating transparent backgrounds. In the Save for Web and Devices dialog box, you can specify a color to be transparent. First make sure the "Transparency" option is off, then use the eyedropper tool (shortcut key I) to click on the background so that a color in the color table is selected, then click below button to make the selected color transparent. As shown below. Multiple colors can be made transparent.
In addition, there is another method that can effectively reduce the number of bytes, which is to cover the screen with a drawing line. Since the covered area becomes a single color, it actually eliminates the pixel difference in this line. The principle is equivalent to filling half of the image with full black, except that it is not filled continuously, but one line is filled every 1 pixel, so that the overall picture is still readable. This method is actually called a scanning line or drawing line effect, which can be achieved by using pattern filling. Click here to read the content about pattern filling in the basic tutorial . Interlacing can reduce the number of animation bytes by nearly half.
It should be noted that although translucent drawing lines look good, the pattern fill here cannot be translucent, because translucency cannot completely cover the original pixels in the image, which defeats our purpose. In addition, black threads may make the image darker, while white threads may make the image lighter. Pay attention to the color adjustment layer to neutralize the brightness. You can also use threads of other colors to achieve alternative effects, and you can also change the color of the threads to transparent. Before turning transparent, the color of the thread should be as contrasting as possible with the color of the picture. This is to prevent the same color in other places from being turned transparent and damaging the picture.
The imported video exists as an independent layer and can be switched to the timeline mode for additional production, such as adding text or other graphics. It is best to group all video frames into a layer group before switching to avoid taking up space in the animation palette. For example, in the example, a logo is added to the lower left corner and dynamic text effects are added. It should be noted that it is difficult to adjust the frame dwell time using the timeline method, so when switching to the timeline method, it is best to confirm that all previous work has been completed.
Try to create this animation and then refer to the comparison example file.
Sometimes you may need to open an existing GIF animation file for reprocessing. At this time, a problem will arise, that is, after directly opening the GIF animation file, only the first frame of the image will be retained, and subsequent animation frames will be abandoned. As shown below. This obviously does not meet the demand.
In fact, Photoshop can open the existing GIF animation, but it blocks this function. We can open the animated GIF through [File>Import>Video Frame to Layer], as shown in the figure below. By default, only the video format MOV can be enabled. , AVI, MPG, MPEG, but no GIF. Now first confirm that the path is correct at the red arrow, then enter the symbol "*" at the green arrow, click the "Load" button, and all formats of files will be listed. Select the corresponding GIF file to import it as an independent layer. Animated GIF. Or directly enter the full name of the animation file, such as abc.gif, 123.gif, etc. The operation after import is the same as before. You can use this method to open GIF animations from the past and give it a try.
In addition, you can also use [File>Open As] [CTRL+ALT+SHIFT+O] and select QuickTime movie in the "Open As" item, so that you can open the GIF as a movie and form an independent video layer in the layer palette. Exists independently in the timeline. As shown below. This method was proposed by a friend named XYBLUEIDEA in the classic forum. I would like to thank him and all the friends who worked hard to improve the tutorial.
Photoshop's [File>Open As] command is to open the image in the form required for a special purpose, and then save it in the format for that special purpose. It is actually an open command with a conversion function. You can see file formats for various purposes in the "Open As" project. Some of the applications of special formats will be introduced in other tutorials. It should be noted that not all files can support all special formats.
At this time, the content of the imported GIF animation itself cannot be modified, but because it is an independent layer, you can add effects through layer styles like ordinary layers, indirectly achieving the purpose of modifying the animation, as shown in the figure below. Although this kind of modification is limited to the style, due to the powerful function of Photoshop layer styles, except for the animation plot, which cannot be modified, any other visual effects can be achieved.
However, optimizing the animation is still a primary prerequisite. If we choose the color of the inner glow as red, green, etc. that is significantly different from the original animation color, because color resources are limited, some colors assigned to the original animation must be assigned to the inner glow style. Then the number of bytes of this animation will increase significantly, or the image quality will decrease significantly with the same number of colors. I believe everyone can understand this truth.
For some animations that must be produced as independent layers, this method can be easily used for secondary production. For example, the animation of birds flapping their wings mentioned earlier, this method can achieve the effect of flapping wings and moving at the same time. For example, if a character runs forward, you can first create a running animation, output it as a GIF, and then load it as a video layer. After expanding the canvas size (note not the image size), change the position of the video layer and animate it. , achieving the effect of running and moving forward at the same time.
This import method actually provides the possibility of component animation. This method can be considered if the object needs to have multiple motion attributes at the same time. This idea is also widely used in the field of video editing. For example, when you want to create the effect of scaling and rotating two scenes while switching, theoretically you should first set the same rotation speed for the two scenes, and then gradually reduce the first scene. The opacity achieves the goal. However, in actual operation, differences in the properties of the scene (such as size) may lead to differences in scaling and rotation angles. At this point, you can first render the static switching of the scene into a video, then import the video, and then zoom and rotate it. Click here to download the sample video file .
It should be noted that the introduction of component knowledge is to expand everyone's knowledge and does not encourage everyone to use it here. After all, we are currently only targeting GIF animation works, not video works. It's best if you can do it in one go. If necessary, be sure to retain the original files of all component animations to facilitate future modifications.
After QuickTime is installed, in addition to the import function, you can also use the export function to output animations as videos, instead of being limited to the previous GIF format output. Due to its own characteristics, the GIF format cannot perfectly record all the animation effects we can create in Photoshop. But the video format is different. The encoding method of the video can not only support tens of millions of colors (click here to read the content about tens of millions of colors in the basic tutorial) and higher color numbers, but also has better playback smoothness than GIF. The most obvious manifestation of the improvement is the screen size and frame rate. In the video encoding method, we no longer have to be limited by the limited image size, and can use 640×480, 800×600 or larger sizes. The frame rate used can also be increased to 30fps, 60fps or higher.
The [File>Export>Render Video] command can output the video format, as shown in the figure below. Select the format of the exported video as AVI, and then click the button at the red arrow to set it. Just select "None" for the compression type at the green arrow in the video settings. This will output a video that can be played through WindowsMediaPlayer in Windows. If you select other compression types such as "DV-PAL", you can also output video, but the screen size, frame rate, etc. will be different from those set in our document.
Below we will give a brief introduction to other video formats: 3G is used for mobile phones and can be sent as MMS (note the MMS capacity limit); FLC is a 256-color animation format under early DOS systems; FLV is a popular Flash video on the Internet; QuickTime, APPLE TV, iPod and iPhone are all Apple's video formats, the latter two are for handheld devices; MPEG-4 is the so-called MP4 and is also commonly used in handheld devices. The details about video encoding are not something you need to learn now. We will introduce them in video-related tutorials when we have the opportunity in the future. As an aside, the MP3 audio format we are familiar with belongs to MPEG-1, which is called MPEG-1 Audio Layer3.
"Image sequence" mode can output animation as multiple still images, and the image file names are named in ascending order. The image size defaults to the document size and can be changed to other sizes. However, changing the small size to a large size may cause loss of image quality due to pixel reorganization. Note that some compression types (such as PAL-DV) will render at the fixed size they set. The output range is generally all frames, that is, the entire animation. If there are special needs, it can be changed to other methods. The Alpha channel can output video with multi-level translucency information, making it easy to synthesize in video editing software such as Premiere. It is recommended to keep the frame rate at the rate set in the document. There is generally no problem playing it on a computer. However, some special-purpose playback devices have fixed frame rates, such as transcribing to PAL format (25fps) or NTSC format (about 30fps). Copy to film (24fps), etc., otherwise the effect may be affected due to out-of-synchronization.
In addition to Photoshop, there are some software that can also create GIF animations, and in some ways are simpler. For example, GIF Animator produced by Ulead is one of them. It can easily combine some static pictures into animations of various styles and add some text or graphics. And you can output each frame sequence of animated GIF. It can also be exported to PSD file format, with each frame stored in a layer and retaining transparency information. Open this PSD file in Photoshop, click the extended menu in the upper right corner of the animation palette in frame mode, and select "Create Frame from Layer" to create an animation in the form of an independent layer. In actual production, everyone can use this kind of software to complete some simple works as appropriate.
The last assignment is to use the materials to imitate the following animation. The size of this animation is 128×160, and it was used to flash the Moto L6 phone as a boot animation. But it can also be used for MMS messages. There are no technical difficulties in this animation. Carefully observe the details of the animation, try more implementation methods, and find the most convenient path. And after completion, add your own creativity to form a new animation.
Now everyone has complete GIF animation production capabilities, and can use photos, videos or draw graphics to complete the production. Send the animation to friends and family as MMS and add your blessings. You can also send it to me for review. My mobile phone currently has QVGA resolution (240×320). And I hope to see the excellent MMS messages you create that are widely circulated on the Internet.
At this point, the animation production part of the Photoshop extended tutorial is over, and you can continue to learn the web design part. If you find any errors during reading, please correct them. Your support is the source of motivation for the continuous improvement of the tutorial. I hope that everyone can spread the knowledge they have learned so that more people can access and learn this knowledge, learn from each other, and make progress together.