Method and system for generating video special effect plug-in
By extracting key features and special effects requirement information from video materials, matching and adjusting plug-in templates, and generating special effects plug-ins, the problem of insufficient customization and cumbersome generation process of existing special effects plug-ins is solved, and high-quality, personalized video special effects production is achieved. .
Patent Information
- Application Number
- CN202410807591.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-06-21
- Publication Date
- 2024-09-13
AI Technical Summary
Existing video special effects plug-ins lack customization, the generation process is cumbersome, it is difficult to meet the personalized needs of users, and the integration with the original material is not high.
By extracting key features and special effects requirement information from user-side materials, matching the corresponding plug-in template, and adjusting the plug-in template according to the parameters input by the user, a special effects plug-in is generated, providing a preview function, reducing rendering time, and supporting material replacement to save production time.
It improves the flexibility and specificity of special effects plug-ins, reduces the difficulty of user production, and improves the quality and look and feel of video special effects.
Smart Images

Figure CN118646928A
Abstract
Description
Technical Field
[0001] The present application relates to the technical field of computer technology, and in particular to a method and system for generating a video special effects plug-in. Background Art
[0002] With the rapid development of digital media technology, video special effects are playing an increasingly important role in film and television production, advertising design and personal creation. At present, there are many professional video editing software on the market, such as Adobe AfterEffects (AE for short), which provide a variety of special effects plug-ins, allowing users to add various visual effects to videos at will.
[0003] In software such as AE, special effects plug-ins are usually a pre-designed visual effects module that users can apply to video materials by simply adjusting parameters.
[0004] However, most of the existing special effects plug-ins are developed based on preset templates and algorithms. Although they can meet the needs of general users, they are often not flexible and customized enough when faced with specific or complex special effects requirements.
[0005] At present, the special effects plug-ins on the market have the following main technical problems: first, the special effects plug-ins are not customizable enough and it is difficult to meet the users' personalized special effects needs; second, the generation process of special effects plug-ins is cumbersome and requires users to have high professional skills and experience; third, the degree of integration between special effects plug-ins and original materials is not high, which easily leads to mismatch between special effects and materials. Summary of the invention
[0006] In order to improve the flexibility and specificity of special effects plug-ins, reduce the difficulty and threshold for users to create special effects and special effects plug-ins, and improve the quality and viewing experience of video special effects, the present application provides a method and system for generating a video special effects plug-in.
[0007] The above-mentioned invention objective of the present application is achieved through the following technical solutions:
[0008] A method for generating a video special effects plug-in comprises the steps of:
[0009] When receiving the original material and special effect requirement information from the user end, extracting key features in the original material based on the special effect requirement information;
[0010] Match the corresponding special effect type based on the extracted key features and special effect requirement information and obtain the plug-in template corresponding to the special effect type;
[0011] Obtain plug-in parameters from the user end, and adjust the plug-in template based on the obtained plug-in parameters;
[0012] Generate special effect plug-ins based on the adjusted plug-in template and key features.
[0013] By adopting the above-mentioned technical scheme, when the original material and special effect requirement information sent by the user end are received, the special effect requirement information is analyzed, and the key features in the original material are extracted based on the special effect requirement information, the corresponding special effect type is matched based on the extracted key features and the special effect requirement information of the user end, and the plug-in template corresponding to the special effect type is obtained, the plug-in parameters are obtained from the user end, and the plug-in template is adjusted, and the adjusted plug-in template is used as the final generation template of the special effect plug-in, and the special effect plug-in is generated based on the template and the key features; the present application extracts the key features in the original material based on the special effect requirement information of the user end, matches the plug-in template corresponding to the key features and the special effect requirement information, and obtains the plug-in parameters of the adjusted plug-in template from the user end, and generates the special effect plug-in based on the template and the key features after adjustment, which reduces the difficulty and threshold for users to make special effects and special effect plug-ins, improves the flexibility and specificity of the special effect plug-in, and thus improves the quality and viewing effect of video special effects.
[0014] In a preferred example, the present application may be further configured as follows: after the step of generating a special effect plug-in based on the adjusted plug-in template and key features, the following steps are performed:
[0015] Generate a corresponding preview window based on the special effect type;
[0016] The special effect plug-in is loaded in the preview window, and the preview special effect is displayed based on the special effect parameters input by the user.
[0017] By adopting the above technical solution, a preview window corresponding to the special effect type preset is generated based on the special effect type for the user to preview, the special effect plug-in is loaded in the preview window, and the replacement special effect for preview is displayed based on the special effect parameters input by the user. On the basis of reducing the rendering time, the user can make a simple preview of the special effect plug-in and the special effect parameters input by the user.
[0018] In a preferred example, the present application may be further configured as follows: after the step of generating a special effect plug-in based on the adjusted plug-in template, the following steps are performed:
[0019] When receiving the replacement material from the user end, extracting key features in the replacement material based on the generated special effect plug-in;
[0020] The key features in the replacement material are input into the special effect plug-in to replace the key features of the original material.
[0021] By adopting the above technical solution, when a replacement material with the same attributes as the original material is received from the user end, the key features in the replacement material are extracted based on the generated special effects plug-in, and the key features in the replacement material are input into the special effects plug-in to replace the key features of the original material. When the user needs to change the material, the key features in the new material are re-extracted without the need to regenerate the corresponding plug-in, thereby saving the time cost of special effects production.
[0022] In a preferred example, the present application can be further configured as follows: the key features include color distribution features, shape features, audio features, and dynamic change features; when the original material and special effect requirement information are received from the user end, the step of extracting the key features in the original material based on the special effect requirement information includes the steps of:
[0023] When the special effect requirement information is to extract a specific color area or color contrast, extract the color distribution characteristics corresponding to the special effect requirement information in the original material;
[0024] When the special effect requirement information is to extract a specific shape or outline, extract the shape features corresponding to the special effect requirement information in the original material;
[0025] When the special effect requirement information is to extract the motion trajectory or motion change of a specific object, extract the dynamic change features corresponding to the special effect requirement information in the original material;
[0026] When the special effect requirement information is to extract specific keywords, timbre or rhythm segmentation points, the audio features corresponding to the special effect requirement information are extracted from the original material.
[0027] By adopting the above technical solution, corresponding key features are extracted for different special effect demand information sent by the user end, thereby improving the flexibility and specificity of the special effect plug-in.
[0028] In a preferred example, the present application can be further configured as follows: when the special effect requirement information is to extract a specific color area or color contrast, the step of extracting the color distribution characteristics corresponding to the special effect requirement information in the original material includes the steps of:
[0029] Perform color space conversion on the original material based on extracting special effect requirement information of specific color area or color contrast;
[0030] Capture the distribution and proportion of each main color in the converted color space;
[0031] Extract the corresponding color distribution features in the special effect requirement information.
[0032] By adopting the above technical solution, the original material is converted into a color space to separate the brightness and chromaticity information, the distribution and proportion of each main color in the converted color space are captured, and the color distribution characteristics are extracted based on the specific color area or color contrast in the special effect requirement information.
[0033] In a preferred example, the present application can be further configured as follows: when the special effect requirement information is to extract a specific shape or contour, the step of extracting the shape feature corresponding to the special effect requirement information in the original material includes the steps of:
[0034] Sampling original frames of the original material that contain a specific shape or contour corresponding to the special effect requirement information;
[0035] Identify edge information of a specific shape or contour in the original frame through an edge detection algorithm, and extract shape features based on the edge information;
[0036] If the specific shape or outline corresponding to the special effect requirement information is a dynamic object, the shape features are extracted based on the inter-frame difference method.
[0037] By adopting the above technical solution, the original frames containing the specific shapes or specific contours corresponding to the special effect requirement information in the original material are sampled, and the edge information of the specific shapes or contours in the original frames are identified and the shape features are extracted through the edge detection algorithm. If the specific shape or contour corresponding to the special effect requirement information is a dynamic object, the shape features of the dynamic object are extracted based on the inter-frame difference method.
[0038] In a preferred example, the present application can be further configured as follows: when the special effect requirement information is to extract the motion trajectory or motion change of a specific object, the step of extracting the dynamic change feature corresponding to the special effect requirement information in the original material includes the steps of:
[0039] Frame sampling of the original footage and calculation of the differences of specific objects between adjacent frames to capture dynamic changes;
[0040] The dynamic parameters such as motion trajectory, velocity, acceleration, etc. are extracted as dynamic change features.
[0041] By adopting the above technical solution, the original material is frame sampled, and the difference changes of specific objects between adjacent frames are calculated, so as to capture its dynamic changes and extract the dynamic parameters such as the motion trajectory, speed, acceleration, etc. of the specific object as dynamic change features.
[0042] The second object of the invention is achieved by the following technical solutions:
[0043] A system for generating a video special effects plug-in, comprising:
[0044] A feature extraction module, for extracting key features from the original material based on the special effect requirement information when receiving the original material and special effect requirement information from the user end;
[0045] A matching module, used to match the corresponding special effect type based on the extracted key features and special effect requirement information and obtain the plug-in template corresponding to the special effect type;
[0046] An adjustment module, used for obtaining plug-in parameters from a user end, and adjusting the plug-in template based on the obtained plug-in parameters;
[0047] The plug-in generation module is used to generate special effect plug-ins based on the adjusted plug-in template and key features.
[0048] By adopting the above technical solution, the feature extraction module is used to extract key features in the original material based on the special effect requirement information when receiving the original material and special effect requirement information from the user end; the matching module is used to match the corresponding special effect type based on the extracted key features and special effect requirement information and obtain the plug-in template corresponding to the special effect type; the adjustment module is used to obtain plug-in parameters from the user end and adjust the plug-in template based on the obtained plug-in parameters; the plug-in generation module is used to generate a special effect plug-in based on the adjusted plug-in template and key features.
[0049] In summary, the present application includes at least one of the following beneficial technical effects:
[0050] 1. This application extracts key features from the original material based on the special effects requirement information of the user end, matches the plug-in template corresponding to the key features and the special effects requirement information, obtains the plug-in parameters for adjusting the plug-in template from the user end, and generates a special effects plug-in based on the template and key features after adjustment, which reduces the difficulty and threshold for users to make special effects and special effects plug-ins, improves the flexibility and speciality of special effects plug-ins, and thus improves the quality and viewing effect of video special effects. ; BRIEF DESCRIPTION OF THE DRAWINGS
[0051] Figure 1 This is a flow chart of a method and system embodiment for generating a video special effects plug-in of the present application;
[0052] Figure 2 This is a flow chart of an implementation of step S10 in a method and system for generating a video special effects plug-in in the present application;
[0053] Figure 3 This is a flow chart of an implementation of step S11 in a method and system for generating a video special effects plug-in in the present application;
[0054] Figure 4 This is a flow chart for implementing step S12 in a method and system embodiment for generating a video special effects plug-in of the present application. DETAILED DESCRIPTION
[0055] The following is combined with Figure 1-4 This application is described in further detail.
[0056] In one embodiment, if Figure 1 As shown, the present application discloses a method for generating a video special effects plug-in, which specifically includes the following steps:
[0057] S10: when receiving the original material and special effect requirement information from the user end, extracting key features in the original material based on the special effect requirement information;
[0058] In this embodiment, the original material is an unprocessed video, audio or image file imported by the user, the special effect requirement information is the user's requirement information for the functional type of the special effect plug-in to be generated, and the key features are features related to the special effect requirement information extracted from the original material.
[0059] Specifically, when the original material input by the user end and the requirement information of the desired function of the special effect plug-in are received, the corresponding key features in the original material are extracted based on the requirement information.
[0060] S20: matching a corresponding special effect type based on the extracted key features and special effect requirement information and obtaining a plug-in template corresponding to the special effect type;
[0061] In this embodiment, the special effect type is the type of special effect, and the presets include particle effects, scene effects, audio effects, and dynamic visual effects. The plug-in template is the basic framework or model of a pre-designed special effect plug-in, which contains the basic algorithms and parameter settings required to achieve a certain special effect. Different plug-in templates will be set according to different special effect types.
[0062] Specifically, the corresponding special effect type is matched based on the extracted key features and the user's demand information for the special effect, and the plug-in basic template corresponding to the special effect type is obtained.
[0063] S30: Obtaining plug-in parameters from the user end, and adjusting the plug-in template based on the obtained plug-in parameters;
[0064] In this embodiment, the plug-in parameters are parameters that the user needs to set when making personalized adjustments to the special effect plug-in based on his / her own needs.
[0065] Specifically, the requirement parameters of the special effect plug-in for the user end are obtained, and the plug-in template is adjusted based on the obtained parameters.
[0066] S40: Generate special effect plug-ins based on the adjusted plug-in template and key features.
[0067] In this embodiment, the special effects plug-in is a software plug-in with specific visual effects that is generated based on the user's special effects needs through steps such as extracting key features, matching special effects types, obtaining and adjusting plug-in templates, etc. The user can apply it to the original material to produce corresponding special effects through the special effects plug-in, thereby enhancing the visual effects of the video.
[0068] Specifically, based on the adjusted plug-in template and the extracted key features, a special effect plug-in that can produce a corresponding special effect type is generated.
[0069] In one embodiment, after step S40, the following steps are performed:
[0070] S41: Generate a corresponding preview window based on the special effect type;
[0071] S42: Loading a special effect plug-in in the preview window, and displaying the preview special effect based on the special effect parameters input by the user.
[0072] In this embodiment, the preview window is an interface for displaying or previewing special effects. In the preview window, the user can make adjustments and decisions based on the simple effects after applying the special effects seen in advance. The preview special effects are replacement special effects used for previewing the effects.
[0073] Furthermore, if the special effect type is a scene special effect, a solid color preview window is generated, and in the generated solid color preview window, the basic color tone and atmosphere of the scene special effect are simulated as the preview special effect by means of gradient or superimposed texture;
[0074] If the special effect type is an audio special effect, a preview window of a waveform or spectrum will be generated. When the user loads or adjusts the audio file, the preview window will display the audio waveform or spectrum changes in real time. By adjusting the audio special effect parameters (reverberation, pitch, volume, etc.), the user can observe the real-time changes of the audio waveform or spectrum in the preview window, so that the user can evaluate and adjust the audio effect;
[0075] If the special effect type is a dynamic visual special effect, a dynamic preview window is generated to display the effect of the special effect: according to the special effect sub-type corresponding to the dynamic visual special effect selected by the user, the corresponding preview special effect is rendered and displayed in the preview window for the user to preview its effect; wherein, the special effect sub-type corresponding to the dynamic visual special effect is preset to include particle special effect, translation special effect, deformation special effect, light and shadow special effect, etc.; wherein, the corresponding preview special effect is rendered and displayed in the preview window for the user to preview its effect, specifically:
[0076] Generate corresponding pixel points based on the particle area, particle combination, speed, acceleration, color, size and other parameters of the particle effect as a preview effect. You can also choose to adjust the particle movement based on physical rules or other custom rules.
[0077] Based on the shape characteristics and dynamic change characteristics of the translation special effect and the deformation special effect, a corresponding shape is generated and an animation of the dynamic change of the shape is rendered and displayed in the preview window as a preview special effect;
[0078] Based on the light source of the light and shadow effects, the distance between the light source and the object, the object properties, and the light and shadow parameters, the corresponding light effects are generated and rendered as preview effects in the form of shadow mapping and ray tracing;
[0079] Furthermore, based on the radiosity method, the distribution and bounce of light energy in the scene are simulated to calculate soft indirect lighting, and multiple bounces and energy distribution of light are simulated based on path tracing.
[0080] Specifically, based on the special effect type, a preview window corresponding to the special effect type preset is generated for the user to preview, the special effect plug-in is loaded in the preview window, and the replacement special effect for preview is displayed based on the special effect parameters input by the user, so that the user can make a simple preview of the special effect plug-in and the special effect parameters input by the user on the basis of reducing the rendering time.
[0081] In one embodiment, after step S40, the following steps are performed:
[0082] S50: when receiving the replacement material from the user end, extracting key features in the replacement material based on the generated special effect plug-in;
[0083] S60: Inputting the key features in the replacement material into the special effect plug-in to replace the key features of the original material.
[0084] In this embodiment, the replacement material is a new material provided by the user terminal to replace the original material.
[0085] Specifically, when a replacement material with the same attributes as the original material is received from the user end, the key features in the replacement material are extracted based on the generated special effects plug-in, and the key features in the replacement material are input into the special effects plug-in to replace the key features of the original material. When the user needs to change the material, the key features in the new material are re-extracted without the need to regenerate the corresponding plug-in, thereby saving the time cost of special effects production.
[0086] In one embodiment, the key features include color distribution features, shape features, audio features, and dynamic change features, such as Figure 2 As shown, step S10 includes the steps of:
[0087] S11: When the special effect requirement information is to extract a specific color area or color contrast, extracting color distribution features corresponding to the special effect requirement information in the original material;
[0088] S12: When the special effect requirement information is to extract a specific shape or contour, extract the shape features corresponding to the special effect requirement information in the original material;
[0089] S13: When the special effect requirement information is to extract the motion trajectory or motion change of a specific object, extract the dynamic change features corresponding to the special effect requirement information in the original material;
[0090] S14: When the special effect requirement information is to extract specific keywords, timbre or rhythm segmentation points, extract the audio features corresponding to the special effect requirement information in the original material.
[0091] In this embodiment, the color distribution feature is the statistical distribution characteristics of the color in the image material or video material, which includes the frequency of occurrence of different colors, the distribution pattern of colors in space, etc.; the shape feature is the appearance structure feature of the object in the image material or video material, which includes contours, boundaries, corners, areas, etc.; the audio feature is the meaningful attributes or parameters extracted from the sound signal to describe the characteristics and content of the sound, which includes keywords, volume, pitch, timbre, rhythm, etc. recognized in the voice information; the dynamic change feature is the characteristic of the object or scene in the video material changing over time, which includes the object's motion trajectory, speed, acceleration, and lighting changes in the scene, etc.
[0092] Specifically, when the special effect requirement information is to extract a specific color area or color contrast, the color distribution characteristics corresponding to the special effect requirement information in the original material are extracted; when the special effect requirement information is to extract a specific shape or outline, the shape characteristics corresponding to the special effect requirement information in the original material are extracted; when the special effect requirement information is to extract the motion trajectory or motion change of a specific object, the dynamic change characteristics corresponding to the special effect requirement information in the original material are extracted; when the special effect requirement information is to extract specific keywords, timbre or rhythm section points, the audio characteristics corresponding to the special effect requirement information in the original material are extracted; by extracting the corresponding key features of different special effect requirement information sent by the user end, the flexibility and specificity of the special effect plug-in are improved.
[0093] In one embodiment, if Figure 3 As shown, step S11 includes the steps of:
[0094] S111: performing color space conversion on the original material based on special effect requirement information of extracting a specific color area or color contrast;
[0095] S112: capturing the distribution and proportion of each main color in the converted color space;
[0096] S113: Extracting color distribution features corresponding to the special effect requirement information.
[0097] In this embodiment, the color space (or color space) is a mathematical model for describing and expressing colors, and the color space conversion is to convert the color data in one color space into data in another color space. For example, the RGB color space (red, green, and blue primary color model) is converted into the HSV color space (hue, saturation, and brightness model) or the Lab color space, etc.; the color distribution is the layout and frequency of different colors in space in an image or video, which describes the location, range, and density of the appearance of various colors in the image; the color ratio is the ratio of the area or number of pixels occupied by different colors in the image, which reflects the overall hue and color composition of the image.
[0098] Specifically, the original material is converted into a color space to separate brightness and chromaticity information, the distribution and proportion of each main color in the converted color space are captured, and the color distribution characteristics are extracted based on specific color areas or color contrasts in the special effect requirement information.
[0099] In one embodiment, if Figure 4 As shown, step S12 includes the steps of:
[0100] S121: sampling original frames of the original material that contain the specific shape or outline corresponding to the special effect requirement information;
[0101] S122: identifying edge information of a specific shape or contour in the original frame by an edge detection algorithm, and extracting shape features based on the edge information;
[0102] S123: If the specific shape or outline corresponding to the special effect requirement information is a dynamic object, shape features are extracted based on an inter-frame difference method.
[0103] In this embodiment, the original frame is a video frame that has not been modified or processed in video processing; edge detection is an image processing technology used to identify and locate areas (i.e., edges) with obvious brightness changes in an image. The identified and located edges usually correspond to the outline of an object or the boundary between different objects. The edge detection algorithm works by analyzing the gradient changes of pixel values in the image; the inter-frame difference method is a method used for video processing and motion detection, which detects dynamic changes in an image by comparing the differences between two or more adjacent frames. When an object moves in the scene, the difference between adjacent frames will increase, so that motion can be detected by setting a threshold.
[0104] Specifically, the original frames containing specific shapes or specific contours corresponding to the special effect requirement information in the original material are sampled, and the edge information of the specific shapes or contours in the original frames are identified and shape features are extracted through an edge detection algorithm. If the specific shape or contour corresponding to the special effect requirement information is a dynamic object, the shape features of the dynamic object are extracted based on the inter-frame difference method.
[0105] In one embodiment, step S13 comprises the steps of:
[0106] S131: Frame sampling of the original material, and calculation of differences of specific objects between adjacent frames to capture dynamic changes;
[0107] S132: Extracting dynamic parameters such as motion trajectory, speed, acceleration, etc. as dynamic change features.
[0108] In this embodiment, frame sampling is to select specific frames from a continuous image sequence (i.e., video frames) for analysis according to certain rules or intervals, which helps to reduce the complexity and computational complexity of data processing, while also capturing key dynamic change information; dynamic changes are the changing behaviors of objects in a time series, including changes in their motion trajectory, position, speed, acceleration and other attributes.
[0109] Specifically, a fixed time interval is set to sample the original material (such as sampling one frame per second), and image processing techniques such as background subtraction, frame difference method, feature point matching, etc. are used to locate and track the position of the object in consecutive frames. The dynamic changes are then captured by calculating the changes in the position, shape or other attributes of the object between adjacent frames, and the dynamic parameters such as motion trajectory, speed, acceleration, etc. are extracted as dynamic change features.
[0110] Furthermore, image processing techniques can be applied to detect the differences between frames and dynamically adjust the sampling rate according to the degree of change between frames;
[0111] Furthermore, the accuracy of object detection and tracking can be significantly improved by applying deep learning techniques, especially convolutional neural networks (CNN) and target detection algorithms (such as YOLO, SSD, etc.);
[0112] Furthermore, data analysis techniques such as Kalman filtering or particle filtering can be used to more accurately estimate the motion state of an object, especially in the presence of noise or uncertainty.
[0113] It should be understood that the size of the serial numbers of the steps in the above embodiments does not mean the order of execution. The execution order of each process should be determined by its function and internal logic, and should not constitute any limitation on the implementation process of the embodiments of the present application.
[0114] In one embodiment, a system for generating a video special effects plug-in is provided, and the system for generating a video special effects plug-in corresponds one-to-one to a method for generating a video special effects plug-in in the above embodiment. The system for generating a video special effects plug-in includes:
[0115] A first feature extraction module is used to extract key features in the original material based on the special effect requirement information when receiving the original material and special effect requirement information from the user terminal;
[0116] A matching module, used to match the corresponding special effect type based on the extracted key features and special effect requirement information and obtain the plug-in template corresponding to the special effect type;
[0117] An adjustment module, used for obtaining plug-in parameters from a user end, and adjusting the plug-in template based on the obtained plug-in parameters;
[0118] A plug-in generation module, used to generate special effect plug-ins based on the adjusted plug-in template and key features;
[0119] Optionally, also include:
[0120] A window generation module, used to generate a corresponding preview window based on the special effect type;
[0121] A plug-in loading module is used to load special effect plug-ins in the preview window and display the preview special effects based on the special effect parameters input by the user end;
[0122] Optionally, also include:
[0123] A first feature extraction module is used to extract key features in the replacement material based on the generated special effect plug-in when receiving the replacement material from the user terminal;
[0124] A material input module, used for inputting key features in the replacement material into the special effect plug-in to replace the key features of the original material;
[0125] Optionally, the first feature extraction module includes:
[0126] The color distribution extraction submodule is used to extract the color distribution characteristics corresponding to the special effect requirement information in the original material when the special effect requirement information is to extract a specific color area or color contrast;
[0127] The shape extraction submodule is used to extract the shape features corresponding to the special effect requirement information in the original material when the special effect requirement information is to extract a specific shape or contour;
[0128] A dynamic change extraction submodule is used to extract dynamic change features corresponding to the special effect requirement information in the original material when the special effect requirement information is to extract the motion trajectory or motion change of a specific object;
[0129] The audio extraction submodule is used to extract the audio features corresponding to the special effect requirement information in the original material when the special effect requirement information is to extract specific keywords, timbre or rhythm segmentation points;
[0130] Optionally, the color distribution extraction submodule includes:
[0131] A color space conversion submodule, used to convert the color space of the original material based on the special effect requirement information of extracting a specific color area or color contrast;
[0132] The color capture submodule is used to capture the distribution and proportion of each main color in the converted color space;
[0133] Optionally, the shape extraction submodule includes:
[0134] The original frame sampling submodule is used to sample the original frame of the original material containing the specific shape or outline corresponding to the special effect requirement information;
[0135] An edge detection submodule, for identifying edge information of a specific shape or contour in an original frame by an edge detection algorithm, and extracting shape features based on the edge information;
[0136] An inter-frame difference extraction submodule, for extracting shape features based on an inter-frame difference method if the specific shape or outline corresponding to the special effect requirement information is a dynamic object;
[0137] Optionally, the dynamic change extraction submodule also includes:
[0138] The dynamic change capture submodule is used to perform frame sampling on the original material and calculate the difference of specific objects between adjacent frames to capture dynamic changes.
[0139] For the specific definition of a system for generating a video special effects plug-in, please refer to the definition of a method for generating a video special effects plug-in above, which will not be repeated here. Each module in the above-mentioned system for generating a video special effects plug-in can be implemented in whole or in part by software, hardware, and a combination thereof. The above-mentioned modules can be embedded in or independent of the processor in the computer device in the form of hardware, or can be stored in the memory of the computer device in the form of software, so that the processor can call and execute the operations corresponding to the above modules.
[0140] The embodiments described above are only used to illustrate the technical solutions of the present application, rather than to limit them. Although the present application has been described in detail with reference to the aforementioned embodiments, a person skilled in the art should understand that the technical solutions described in the aforementioned embodiments may still be modified, or some of the technical features may be replaced by equivalents. Such modifications or replacements do not deviate the essence of the corresponding technical solutions from the spirit and scope of the technical solutions of the embodiments of the present application, and should all be included in the protection scope of the present application.
Claims
1. A method for generating a video special effects plug-in, characterized in that: Includes steps: When receiving the original material and special effect requirement information from the user end, extracting key features in the original material based on the special effect requirement information; Match the corresponding special effect type based on the extracted key features and special effect requirement information and obtain the plug-in template corresponding to the special effect type; Obtain plug-in parameters from the user end, and adjust the plug-in template based on the obtained plug-in parameters; Generate special effect plug-ins based on the adjusted plug-in template and key features.
2. The method for generating a video special effects plug-in according to claim 1, characterized in that: After the step of generating a special effect plug-in based on the adjusted plug-in template and key features, the following steps are performed: Generate a corresponding preview window based on the special effect type; The special effect plug-in is loaded in the preview window, and the preview special effect is displayed based on the special effect parameters input by the user.
3. The method for generating a video special effects plug-in according to claim 1, characterized in that: After the step of generating a special effect plug-in based on the adjusted plug-in template, the following steps are performed: When receiving the replacement material from the user end, extracting key features in the replacement material based on the generated special effect plug-in; The key features in the replacement material are input into the special effect plug-in to replace the key features of the original material.
4. The method for generating a video special effect plug-in according to claim 1, characterized in that: The key features include color distribution features, shape features, audio features, and dynamic change features. When the original material and special effect requirement information are received from the user end, the step of extracting the key features in the original material based on the special effect requirement information includes the steps of: When the special effect requirement information is to extract a specific color area or color contrast, extract the color distribution characteristics corresponding to the special effect requirement information in the original material; When the special effect requirement information is to extract a specific shape or outline, extract the shape features corresponding to the special effect requirement information in the original material; When the special effect requirement information is to extract the motion trajectory or motion change of a specific object, extract the dynamic change features corresponding to the special effect requirement information in the original material; When the special effect requirement information is to extract specific keywords, timbre or rhythm segmentation points, the audio features corresponding to the special effect requirement information are extracted from the original material.
5. The method for generating a video special effect plug-in according to claim 4, characterized in that: When the special effect requirement information is to extract a specific color area or color contrast, the step of extracting the color distribution characteristics corresponding to the special effect requirement information in the original material comprises the steps of: Perform color space conversion on the original material based on extracting special effect requirement information of specific color area or color contrast; Capture the distribution and proportion of each main color in the converted color space; Extract the corresponding color distribution features in the special effect requirement information.
6. The method for generating a video special effect plug-in according to claim 4, characterized in that: When the special effect requirement information is to extract a specific shape or contour, the step of extracting the shape feature corresponding to the special effect requirement information in the original material comprises the steps of: Sampling original frames of the original material that contain a specific shape or contour corresponding to the special effect requirement information; Identify edge information of a specific shape or contour in the original frame through an edge detection algorithm, and extract shape features based on the edge information; If the specific shape or outline corresponding to the special effect requirement information is a dynamic object, the shape features are extracted based on the inter-frame difference method.
7. The method for generating a video special effect plug-in according to claim 4, characterized in that: When the special effect requirement information is to extract the motion trajectory or motion change of a specific object, the step of extracting the dynamic change feature corresponding to the special effect requirement information in the original material includes the steps of: Frame sampling of the original footage and calculation of the differences of specific objects between adjacent frames to capture dynamic changes; The dynamic parameters such as motion trajectory, velocity, acceleration, etc. are extracted as dynamic change features.
8. A system for generating a video special effects plug-in, characterized in that: include: A feature extraction module, for extracting key features from the original material based on the special effect requirement information when receiving the original material and special effect requirement information from the user end; A matching module, used to match the corresponding special effect type based on the extracted key features and special effect requirement information and obtain the plug-in template corresponding to the special effect type; An adjustment module, used for obtaining plug-in parameters from a user end, and adjusting the plug-in template based on the obtained plug-in parameters; The plug-in generation module is used to generate special effect plug-ins based on the adjusted plug-in template and key features.
