CN114640806A - Video file synthesis method and device - Google Patents

Video file synthesis method and device Download PDF

Info

Publication number
CN114640806A
CN114640806A CN202210246945.6A CN202210246945A CN114640806A CN 114640806 A CN114640806 A CN 114640806A CN 202210246945 A CN202210246945 A CN 202210246945A CN 114640806 A CN114640806 A CN 114640806A
Authority
CN
China
Prior art keywords
video
commodity
tasks
task processing
video file
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
CN202210246945.6A
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.)
Shanghai Bilibili Technology Co Ltd
Original Assignee
Shanghai Bilibili Technology 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 Shanghai Bilibili Technology Co Ltd filed Critical Shanghai Bilibili Technology Co Ltd
Priority to CN202210246945.6A priority Critical patent/CN114640806A/en
Publication of CN114640806A publication Critical patent/CN114640806A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N5/00Details of television systems
    • H04N5/222Studio circuitry; Studio devices; Studio equipment
    • H04N5/262Studio circuits, e.g. for mixing, switching-over, change of character of image, other special effects ; Cameras specially adapted for the electronic generation of special effects
    • H04N5/265Mixing
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N21/00Selective content distribution, e.g. interactive television or video on demand [VOD]
    • H04N21/20Servers specifically adapted for the distribution of content, e.g. VOD servers; Operations thereof
    • H04N21/23Processing of content or additional data; Elementary server operations; Server middleware
    • H04N21/234Processing of video elementary streams, e.g. splicing of video streams or manipulating encoded video stream scene graphs
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N21/00Selective content distribution, e.g. interactive television or video on demand [VOD]
    • H04N21/80Generation or processing of content or additional data by content creator independently of the distribution process; Content per se
    • H04N21/81Monomedia components thereof
    • H04N21/8146Monomedia components thereof involving graphical data, e.g. 3D object, 2D graphics
    • H04N21/8153Monomedia components thereof involving graphical data, e.g. 3D object, 2D graphics comprising still images, e.g. texture, background image
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N5/00Details of television systems
    • H04N5/222Studio circuitry; Studio devices; Studio equipment
    • H04N5/262Studio circuits, e.g. for mixing, switching-over, change of character of image, other special effects ; Cameras specially adapted for the electronic generation of special effects

Landscapes

  • Engineering & Computer Science (AREA)
  • Multimedia (AREA)
  • Signal Processing (AREA)
  • Computer Graphics (AREA)
  • Two-Way Televisions, Distribution Of Moving Picture Or The Like (AREA)

Abstract

The application discloses a video file synthesis method. The method comprises the following steps: acquiring a plurality of sets of commodity materials; creating a video task for each set of commodity materials, and associating each created video task with the corresponding commodity material; the method comprises the steps that video tasks to be processed are obtained in parallel through a plurality of video task processing services, and commodity materials related to the target video tasks are combined into a video file through each video task processing service according to the obtained target video tasks. The application can reduce the time consumption of video synthesis.

Description

Video file synthesis method and device
Technical Field
The present application relates to the field of video technologies, and in particular, to a method and an apparatus for synthesizing a video file.
Background
With the continuous development of internet technology, the demand of video processing is increasing. In the prior art, a mode of only synthesizing one video at a time cannot meet the development requirement of services. When a plurality of videos exist to be synthesized, the prior art needs to spend a lot of time to complete the synthesis of the plurality of videos.
Disclosure of Invention
In view of the above, a video file composition method, an apparatus, a computer device and a computer readable storage medium are provided to solve the problem that a lot of time is consumed when a plurality of videos are composited.
The application provides a video file synthesis method, which comprises the following steps:
acquiring a plurality of sets of commodity materials;
creating a video task for each set of commodity materials, and associating each created video task with the corresponding commodity material;
the method comprises the steps that video tasks to be processed are obtained in parallel through a plurality of video task processing services, and commodity materials related to the target video tasks are combined into a video file through each video task processing service according to the obtained target video tasks.
Optionally, the method further comprises:
storing each created video task into a database;
the method comprises the following steps of acquiring video tasks to be processed in parallel through a plurality of video task processing services, and synthesizing commodity materials related to the target video tasks into video files according to the acquired target video tasks through each video task processing service, wherein the video tasks to be processed comprise:
and acquiring video tasks to be processed from the database in parallel through a plurality of video task processing services, and synthesizing commodity materials associated with the target video tasks into video files according to the acquired target video tasks through each video task processing service.
Optionally, the database is Redis, and storing each created video task into the database includes:
and storing each established video task into the Redis in a queue form.
Optionally, the method further comprises:
when the video task processing service successfully synthesizes the commodity materials into the video file, setting the state of the video task corresponding to the commodity materials successfully synthesized into the video file as a completion state;
and when the video task processing service fails to synthesize the commodity materials into the video file, storing the video tasks corresponding to the commodity materials which are not successfully synthesized into the video file into the queue of the Redis.
Optionally, the method further comprises:
and sending the successfully synthesized video file to a material provider of the commodity material of the successfully synthesized video file.
Optionally, the video file composition method according to claim 5, wherein the material provider that transmits the successfully composed video file to the commodity material of the successfully composed video file comprises:
and sending the successfully synthesized video file to a material provider of the commodity material of the successfully synthesized video file in an asynchronous mode.
Optionally, the multiple video task processing services are deployed in a distributed manner.
Optionally, the obtaining, by a plurality of video task processing services in parallel, a video task to be processed, and synthesizing, by each of the video task processing services according to the obtained target video task, a video file from commodity materials associated with the target video task includes:
selecting a plurality of video task processing services meeting preset conditions from all the video task processing services deployed in a distributed manner;
the method comprises the steps that video tasks to be processed are obtained in parallel through a plurality of video task processing services, and commodity materials related to the target video tasks are combined into a video file through each video task processing service according to the obtained target video tasks.
Optionally, the preset condition is that the usage rate of physical resources of the video task processing service is lower than a preset value.
The present application further provides a video file synthesizing apparatus, including:
the acquisition module is used for acquiring a plurality of sets of commodity materials;
the association module is used for creating a video task for each set of commodity materials and associating each created video task with the corresponding commodity material;
and the synthesis module is used for acquiring video tasks to be processed in parallel through a plurality of video task processing services, and synthesizing the commodity materials associated with the target video tasks into video files according to the acquired target video tasks through each video task processing service.
The present application further provides a computer device comprising a memory, a processor and a computer program stored on the memory and executable on the processor, the processor implementing the steps of the above method when executing the computer program.
The present application also provides a computer-readable storage medium having stored thereon a computer program which, when being executed by a processor, carries out the steps of the above-mentioned method.
According to the method and the device, a plurality of sets of commodity materials are obtained simultaneously, a video task can be created for each set of commodity materials, each created video task is associated with the corresponding commodity material, then the video tasks to be processed can be obtained in parallel through a plurality of video task processing services, and the commodity materials associated with the target video tasks are combined into a video file through the video task processing services according to the obtained target video tasks. By the video synthesis method, a plurality of video task processing services can simultaneously synthesize a plurality of commodity materials into a plurality of video files without synthesizing one video file, so that the time consumed by video synthesis can be reduced.
Drawings
Fig. 1 is an environment diagram of a video file synthesizing method according to an embodiment of the present application;
FIG. 2 is a flowchart of an embodiment of a video file synthesizing method according to the present application;
fig. 3 is a schematic flowchart illustrating a detailed process of steps of acquiring a video task to be processed by a plurality of video task processing services in parallel, and synthesizing commodity materials associated with a target video task into a video file according to the acquired target video task by each of the video task processing services according to an embodiment of the present application;
FIG. 4 is a block diagram of a video file compositing apparatus according to an embodiment of the present application;
fig. 5 is a schematic hardware structure diagram of a computer device for executing a video file synthesis method according to an embodiment of the present application.
Detailed Description
The advantages of the present application are further illustrated below with reference to the accompanying drawings and specific embodiments.
Reference will now be made in detail to the exemplary embodiments, examples of which are illustrated in the accompanying drawings. When the following description refers to the accompanying drawings, like numbers in different drawings represent the same or similar elements unless otherwise indicated. The implementations described in the exemplary embodiments below are not intended to represent all implementations consistent with the present disclosure. Rather, they are merely examples of apparatus and methods consistent with certain aspects of the present disclosure, as detailed in the appended claims.
The terminology used in the present disclosure is for the purpose of describing particular embodiments only and is not intended to be limiting of the disclosure. As used in this disclosure and the appended claims, the singular forms "a," "an," and "the" are intended to include the plural forms as well, unless the context clearly indicates otherwise. It should also be understood that the term "and/or" as used herein refers to and encompasses any and all possible combinations of one or more of the associated listed items.
It is to be understood that although the terms first, second, third, etc. may be used herein to describe various information, such information should not be limited to these terms. These terms are only used to distinguish one type of information from another. For example, first information may also be referred to as second information, and similarly, second information may also be referred to as first information, without departing from the scope of the present disclosure. The word "if" as used herein may be interpreted as "at … …" or "when … …" or "in response to a determination", depending on the context.
In the description of the present application, it should be understood that the numerical references before the steps do not identify the sequence of executing the steps, but merely serve to facilitate the description of the present application and to distinguish each step, and thus should not be construed as limiting the present application.
Fig. 1 shows a schematic diagram of an application scenario provided in an embodiment of the present application, where the application scenario includes, but is not limited to: the orchestration center service 10, the annotation center service 20, and the video center service 30.
The orchestration center service 10 is configured to collect commodity materials (including pictures and other attribute information of a commodity library) and video templates of the commercial commodities.
The annotation center service 20 is used for dotting the commodities (such as the sponsors) in the commodity material and obtaining the key points of the sponsors, for example: eyes, hands, limbs, etc. Wherein, a handheld video can be synthesized according to one or more still pictures. The annotation center service 20 can annotate multiple still pictures, one for each. The annotation center service 20 may perform dotting in a manual manner or may perform dotting by using an AI technique when dotting the still picture. In the present embodiment, after completing dotting through the annotation center service 20, the user can trigger video composition by clicking a "composite video" button, so that video composition processing can be performed in the video center service 30. In this embodiment, when the user triggers the video composition operation, the annotation center service 20 may push the video task to the queue for storage, so that the video service center 20 may consume the video task from the queue for video composition.
The video center service 30 is configured to obtain the commodity materials (including still pictures, commodity descriptions, and the like) from the annotation center service 20, and synthesize the obtained commodity materials into a video file.
It should be noted that in this embodiment of the application, the director center service 10, the annotation center service 20, and the video center service 30 may be separate servers, or may also be a server cluster, or may also be a local server, or may also be a cloud server, and a specific server type may not be limited in this embodiment of the application. The director center service 10, the annotation center service 20, and the video center service 30 may also be a mobile phone, a smart phone, a notebook computer, a desktop computer, a tablet computer, a Personal Digital Assistant (PDA), a media player, a smart television, a wearable electronic device, etc., and the specific type of the terminal device may not be limited in the embodiment of the present application.
Fig. 2 is a schematic flow chart of a video file synthesizing method according to an embodiment of the present application. It should be understood that the flow charts in the embodiments of the present method are not used to limit the order of executing the steps. As can be seen from the figure, the video file composition method provided in this embodiment includes:
and step S20, acquiring a plurality of sets of commodity materials.
Specifically, a set of commodity materials may include a commodity picture and commodity description information, where the commodity description information may include information such as a material id, a material address, a commodity name, and a commodity category.
In this embodiment, when a commodity material part needs to synthesize a corresponding video file with commodity materials, the commodity material part can upload one or more sets of commodity materials to a material receiving service, and the material receiving service stores the commodity materials after receiving the commodity materials, wherein the material receiving service is a service for receiving the commodity materials. When the video needs to be synthesized, a plurality of sets of materials can be simultaneously obtained from the material receiving service, and the received plurality of sets of commodity materials can also be directly used as the commodity materials to be synthesized. The multiple sets of materials obtained from the material receiving service may be selected by the user, or all the materials in the material receiving service may be obtained, and the specific obtaining manner is not limited in this embodiment.
Step S21, creating a video task for each set of commodity material, and associating each created video task with a corresponding commodity material.
Specifically, the video task is used for synthesizing the commodity materials into corresponding video files.
In this embodiment, one video task is created for each set of goods, so that multiple video tasks can be processed in parallel by using a multithreading technology when video files are subsequently synthesized. In a particular scenario, to increase the speed of creation of a video task, the video task may be created by a specialized task creation service.
As an example, one video task 1 may be created for the commodity material a, one video task 2 may be created for the commodity material B, one video task 3 may be created for the commodity material C, and so on.
After a corresponding video task is created for each set of commodity material, each video task can be associated with the commodity material one by one, for example, the commodity material A is associated with the video task 1; associating the commodity material B with the video task 2; the commodity material C is associated with the video task 3.
In this embodiment, by associating the video tasks with the commodity materials, each video task can process the corresponding commodity material without processing other commodity materials.
In one embodiment, when associating the video task with the commodity material, the task id corresponding to the video task may be associated with the commodity material.
In an exemplary embodiment, the method further comprises:
and storing each created video task into a database.
In this embodiment, each created video task can be stored in the database while associating the video task with the commodity material, so that the video task can be directly acquired from the database when the video task needs to be acquired subsequently.
Wherein, the database can be MySQL, MongoDB, Redis, Memcache and the like. In this embodiment, the database is preferably Redis.
In an exemplary embodiment, when the database is Redis, the storing each created video task into the database includes:
and storing each established video task into the Redis in a queue form.
In particular, a queue is a special linear table, which is special in that it allows only delete operations at the front end (front) of the table, while insert operations at the back end (rear) of the table, and, like a stack, a queue is a linear table with restricted operations. The end performing the insert operation is called the tail of the queue, and the end performing the delete operation is called the head of the queue.
In this embodiment, the video tasks are stored in the form of a queue in the Redis, so that the video tasks created first can be processed first, and the video tasks created later can be processed later, thereby avoiding the video tasks waiting for processing for a long time.
Step S22, video tasks to be processed are acquired in parallel through a plurality of video task processing services, and commodity materials related to the target video tasks are synthesized into video files through the video task processing services according to the acquired target video tasks.
Specifically, the video task service is a service for processing a video task. The target video task is a video task obtained by the video task processing service. For example, if the video task acquired by the video task processing service a is the video task 1, the video task 1 is the target video task acquired by the video task processing service a. Similarly, the video task obtained by the video task processing service b is the video task 2, and the video task 2 is the target video task obtained by the video task processing service b.
In a specific scenario, when the video task processing service performs video synthesis on the commodity material according to the target video task, the video task processing service may synthesize the commodity pictures in the commodity material into a video file according to preset animation effect parameters, and may add description information of the commodity into the video file in the process of synthesizing the video file.
Wherein, the animation effect parameters include, but are not limited to, initial state, final state, video duration. The initial state comprises an initial position and a display range of the commodity picture when the initial position is played, and the final state comprises an end position and a display range of the commodity picture when the end position is played. In addition, parameters such as the playing time length, the speed, the frame rate and the like of the video file can be set. In this embodiment, when the video task processing service performs video synthesis according to a video task, the video task processing service may perform organized decomposition on the commodity picture by using imagemap and graphicsmagick according to the animation effect parameter to achieve an animation effect, obtain a plurality of video frames, and then synthesize the decomposed video frames (according to parameters such as a user-defined duration, a speed, and a frame rate) into a video file.
In the embodiment, a video task can be created for each set of commodity materials by simultaneously acquiring a plurality of sets of commodity materials, each created video task is associated with the corresponding commodity material, then, video tasks to be processed can be acquired in parallel through a plurality of video task processing services, and the commodity materials associated with the target video task are synthesized into a video file according to the acquired target video task through each video task processing service. By the video synthesis method, a plurality of video task processing services can simultaneously synthesize a plurality of commodity materials into a plurality of video files without synthesizing one video file, so that the time consumed by video synthesis can be reduced.
In an exemplary embodiment, the method for acquiring video tasks to be processed in parallel by a plurality of video task processing services, and synthesizing commodity materials associated with a target video task into a video file according to the acquired target video task by each video task processing service includes: and acquiring video tasks to be processed from the database in parallel through a plurality of video task processing services, and synthesizing commodity materials associated with the target video tasks into video files according to the acquired target video tasks through each video task processing service.
In this embodiment, when the video task is stored in the database, each video task processing service needs to take the video task from the database first, and then can perform video synthesis according to the obtained video task.
In an exemplary embodiment, in order to conveniently and flexibly increase the number of the video task processing services according to the number of the commodity materials to be synthesized, in this embodiment, a plurality of video task processing services may be deployed in a distributed manner.
In an exemplary implementation manner, referring to fig. 3, the acquiring, by a plurality of video task processing services, video tasks to be processed in parallel, and synthesizing, by each of the video task processing services, a video file from commodity materials associated with an acquired target video task includes:
step S30, selecting a plurality of video task processing services meeting the preset conditions from all the video task processing services deployed in a distributed manner.
Specifically, the preset condition may be flexibly set and modified according to an actual situation, and the preset condition is used to determine whether each video task processing service may be used to process a video task. In this embodiment, the preset condition is that the usage rate of the physical resource of the video task processing service is lower than a preset value. The physical resources include a CPU, a memory, and the like. The preset value can be flexibly set and adjusted according to actual conditions.
As an example, if the preset value is 20%, the video task processing service for processing the video task is selected only if the usage rate of the physical resource of the video task processing service is lower than 20%.
Step S31, video tasks to be processed are acquired in parallel through a plurality of video task processing services, and commodity materials related to the target video tasks are combined into video files according to the acquired target video tasks through the video task processing services.
Specifically, after a plurality of video task processing services are selected and obtained, each video task can be processed through the video task processing services, so that the video file is synthesized.
In the embodiment, the video task is processed by selecting the video task processing service with idle physical resources, so that the equipment resources can be fully utilized, and the processing efficiency of the video task can be improved.
In an exemplary embodiment, the method further comprises: when the video task processing service successfully synthesizes the commodity materials into the video file, setting the state of the video task corresponding to the commodity materials successfully synthesized into the video file as a completion state; and when the video task processing service fails to synthesize the commodity materials into the video file, storing the video tasks corresponding to the commodity materials which are not successfully synthesized into the video file into the queue of the Redis.
In this embodiment, when the video task processing service successfully synthesizes the commodity material into the corresponding video file, in order to facilitate the user to know the processing state of the video task, the state of the video task corresponding to the commodity material that successfully synthesizes the video file may be set to the completion state, the state of the video task corresponding to the commodity material that unsuccessfully synthesizes the video file may be set to the failure state, and the state of the video task corresponding to the commodity material of the video file to be synthesized may be set to the to-be-completed state. Meanwhile, in order to enable the commodity materials of the video file which is not successfully synthesized to be subjected to video synthesis again in time, the video tasks corresponding to the commodity materials of the video file which is not successfully synthesized can be stored in the queue of the Redis, and therefore the subsequent video task processing service can take out the video tasks from the queue again and then carry out video synthesis according to the video tasks.
In an exemplary embodiment, in order that a material provider of a commodity material can obtain a synthesized video file in time, in this embodiment, after a corresponding video file is successfully synthesized from the commodity material, the successfully synthesized video file is sent to the material provider of the commodity material of the successfully synthesized video file.
In an exemplary embodiment, in order to avoid long waiting time of a material provider for a video file, the material provider for transmitting a successfully composed video file to commodity material of the successfully composed video file includes:
and sending the successfully synthesized video file to a material provider of the commodity material of the successfully synthesized video file in an asynchronous mode.
In the embodiment, the synthesized video file is sent to the material provider in an asynchronous mode, so that the material provider does not need to wait for the successful synthesis of the video file, and the synthesized video file can be obtained in time after the video file is successfully synthesized.
Fig. 4 is a block diagram of a video file synthesizing apparatus 40 according to an embodiment of the present invention.
In this embodiment, the video file composition apparatus 40 includes a series of computer program instructions stored on a memory, which when executed by a processor, can implement the video file composition functions of the embodiments of the present application. In some embodiments, based on the specific operations implemented by the computer program instructions, the video file composition apparatus 40 may be divided into one or more modules, which may be specifically divided as follows:
an obtaining module 41, configured to obtain multiple sets of commodity materials;
the association module 42 is configured to create a video task for each set of commodity material, and associate each created video task with a corresponding commodity material;
and the synthesizing module 43 is configured to concurrently acquire video tasks to be processed by a plurality of video task processing services, and synthesize, by each of the video task processing services, the commodity materials associated with the target video task into a video file according to the acquired target video task.
In an exemplary embodiment, the video file synthesizing apparatus 40 further comprises a storage module.
The storage module is used for storing each created video task into a database;
the synthesizing module 43 is further configured to obtain a video task to be processed from the database in parallel through a plurality of video task processing services, and synthesize a video file from the commodity material associated with the target video task according to the obtained target video task through each of the video task processing services.
In an exemplary embodiment, the database is a Redis, and the storage module is further configured to store each established video task in the form of a queue in the Redis.
In an exemplary embodiment, the video file composition apparatus 40 further includes a setup module.
And the setting module is used for setting the state of the video task corresponding to the commodity material successfully synthesized into the video file as the completion state when the video task processing service successfully synthesizes the commodity material into the video file.
The storage module is further configured to store, when the video task processing service fails to synthesize the commodity material into the video file, the video task corresponding to the commodity material that has not successfully synthesized the video file into the queue of the Redis.
In an exemplary embodiment, the video file composition apparatus 40 further comprises a sending module.
And the sending module is used for sending the successfully synthesized video file to a material provider of the commodity material of the successfully synthesized video file.
In an exemplary embodiment, the sending module is further configured to send the successfully composed video file to a material provider of the commodity material of the successfully composed video file in an asynchronous manner.
In an exemplary embodiment, the plurality of video task processing services are deployed in a distributed manner.
In an exemplary embodiment, the synthesizing module 43 is further configured to select a plurality of video task processing services meeting a preset condition from all the video task processing services deployed in a distributed manner; the method comprises the steps that video tasks to be processed are obtained in parallel through a plurality of video task processing services, and commodity materials related to the target video tasks are combined into a video file through each video task processing service according to the obtained target video tasks.
In an exemplary embodiment, the preset condition is that the usage rate of the physical resources of the video task processing service is lower than a preset value.
In the embodiment, a video task can be created for each set of commodity materials by simultaneously acquiring a plurality of sets of commodity materials, each created video task is associated with the corresponding commodity material, then, video tasks to be processed can be acquired in parallel through a plurality of video task processing services, and the commodity materials associated with the target video task are synthesized into a video file according to the acquired target video task through each video task processing service. By the video synthesis method, a plurality of video task processing services can simultaneously synthesize a plurality of commodity materials into a plurality of video files without synthesizing one video file, so that the time consumed by video synthesis can be reduced.
Fig. 5 schematically shows a hardware architecture diagram of a computer device 11 suitable for implementing the video file composition method according to an embodiment of the present application. In the present embodiment, the computer device 11 is a device capable of automatically performing numerical calculation and/or information processing in accordance with a command set or stored in advance. For example, the server may be a tablet computer, a notebook computer, a desktop computer, a rack server, a blade server, a tower server, or a cabinet server (including an independent server or a server cluster composed of multiple servers). As shown in fig. 5, the computer device 11 includes at least, but is not limited to: the memory 120, processor 121, and network interface 122 may be communicatively linked to each other by a system bus. Wherein:
the memory 120 includes at least one type of computer-readable storage medium, which may be volatile or non-volatile, and particularly, includes a flash memory, a hard disk, a multimedia card, a card type memory (e.g., SD or DX memory, etc.), a Random Access Memory (RAM), a Static Random Access Memory (SRAM), a Read Only Memory (ROM), an Electrically Erasable Programmable Read Only Memory (EEPROM), a Programmable Read Only Memory (PROM), a magnetic memory, a magnetic disk, an optical disk, and the like. In some embodiments, the storage 120 may be an internal storage module of the computer device 11, such as a hard disk or a memory of the computer device 11. In other embodiments, the memory 120 may also be an external storage device of the computer device 11, such as a plug-in hard disk, a Smart Media Card (SMC), a Secure Digital (SD) Card, a Flash memory Card (Flash Card), and the like, which are provided on the computer device 11. Of course, the memory 120 may also include both internal and external memory modules of the computer device 11. In this embodiment, the memory 120 is generally used for storing an operating system installed in the computer device 11 and various types of application software, such as program codes of a video file composition method. In addition, the memory 120 may also be used to temporarily store various types of data that have been output or are to be output.
Processor 121 may be a Central Processing Unit (CPU), controller, microcontroller, microprocessor, or other video file compositing chip in some embodiments. The processor 121 is generally used for controlling the overall operation of the computer device 11, such as performing control and processing related to data interaction or communication with the computer device 11. In this embodiment, the processor 121 is configured to execute the program code stored in the memory 120 or process data.
Network interface 122 may comprise a wireless network interface or a wired network interface, with network interface 122 typically being used to establish communication links between computer device 11 and other computer devices. For example, the network interface 122 is used to connect the computer device 11 with an external terminal via a network, establish a data transmission channel and a communication link between the computer device 11 and the external terminal, and the like. The network may be a wireless or wired network such as an Intranet (Intranet), the Internet (Internet), a Global System of Mobile communication (GSM), Wideband Code Division Multiple Access (WCDMA), a 4G network, a 5G network, Bluetooth (Bluetooth), or Wi-Fi.
It should be noted that FIG. 5 only shows a computer device having components 120-122, but it should be understood that not all of the shown components are required to be implemented, and that more or fewer components may be implemented instead.
In this embodiment, the video file composition method stored in the memory 120 may be divided into one or more program modules and executed by one or more processors (in this embodiment, the processor 121) to complete the present application.
Embodiments of the present application provide a computer-readable storage medium, on which a computer program is stored, where the computer program, when executed by a processor, implements the steps of the video file synthesis method in the embodiments.
In this embodiment, the computer-readable storage medium includes a flash memory, a hard disk, a multimedia card, a card type memory (e.g., SD or DX memory, etc.), a Random Access Memory (RAM), a Static Random Access Memory (SRAM), a Read Only Memory (ROM), an Electrically Erasable Programmable Read Only Memory (EEPROM), a Programmable Read Only Memory (PROM), a magnetic memory, a magnetic disk, an optical disk, and the like. In some embodiments, the computer readable storage medium may be an internal storage unit of the computer device, such as a hard disk or a memory of the computer device. In other embodiments, the computer readable storage medium may be an external storage device of the computer device, such as a plug-in hard disk, a Smart Media Card (SMC), a Secure Digital (SD) Card, a Flash memory Card (Flash Card), and the like provided on the computer device. Of course, the computer-readable storage medium may also include both internal and external storage devices of the computer device. In this embodiment, the computer-readable storage medium is generally used to store an operating system and various types of application software installed in the computer device, for example, the program code of the video file composition method in the embodiment, and the like. Further, the computer-readable storage medium may also be used to temporarily store various types of data that have been output or are to be output.
The above-described embodiments of the apparatus are merely illustrative, and the units described as separate parts may or may not be physically separate, and the parts displayed as units may or may not be physical units, may be located in one place, or may be distributed on at least two network units. Some or all of the modules can be screened out according to actual needs to achieve the purpose of the scheme of the embodiment of the application. One of ordinary skill in the art can understand and implement it without inventive effort.
Through the above description of the embodiments, those skilled in the art will clearly understand that each embodiment can be implemented by software plus a general hardware platform, and certainly can also be implemented by hardware. It will be understood by those skilled in the art that all or part of the processes of the methods of the embodiments described above can be implemented by hardware related to instructions of a computer program, which can be stored in a computer readable storage medium, and when executed, can include the processes of the embodiments of the methods described above. The storage medium may be a magnetic disk, an optical disk, a Read-only memory (ROM), a Random Access Memory (RAM), or the like.
Finally, it should be noted that: the above embodiments are only used for illustrating the technical solutions of the present application, and not for limiting the same; although the present application has been described in detail with reference to the foregoing embodiments, it should be understood by those of ordinary skill in the art that: the technical solutions described in the foregoing embodiments may still be modified, or some or all of the technical features may be equivalently replaced; and the modifications or the substitutions do not make the essence of the corresponding technical solutions depart from the scope of the technical solutions of the embodiments of the present application.

Claims (12)

1. A method for synthesizing a video file, comprising:
acquiring a plurality of sets of commodity materials;
creating a video task for each set of commodity materials, and associating each created video task with the corresponding commodity material;
the method comprises the steps that video tasks to be processed are obtained in parallel through a plurality of video task processing services, and commodity materials related to the target video tasks are combined into a video file through each video task processing service according to the obtained target video tasks.
2. The method of synthesizing a video file according to claim 1, further comprising:
storing each created video task into a database;
the method comprises the following steps of acquiring video tasks to be processed in parallel through a plurality of video task processing services, and synthesizing commodity materials related to the target video tasks into video files according to the acquired target video tasks through each video task processing service, wherein the video tasks to be processed comprise:
and acquiring video tasks to be processed from the database in parallel through a plurality of video task processing services, and synthesizing commodity materials associated with the target video tasks into video files according to the acquired target video tasks through each video task processing service.
3. A method for synthesizing a video file according to claim 2, wherein the database is Redis, and the storing each created video task into the database comprises:
and storing each established video task into the Redis in a queue form.
4. A video file composition method according to claim 3, wherein the method further comprises:
when the video task processing service successfully synthesizes the commodity materials into the video file, setting the state of the video task corresponding to the commodity materials successfully synthesized into the video file as a completion state;
and when the video task processing service fails to synthesize the commodity materials into the video file, storing the video tasks corresponding to the commodity materials which are not successfully synthesized into the video file into the queue of the Redis.
5. The method of synthesizing a video file according to claim 4, further comprising:
and sending the successfully synthesized video file to a material provider of the commodity material of the successfully synthesized video file.
6. The video file composition method according to claim 5, wherein the material provider that transmits the successfully composed video file to the commodity material of the successfully composed video file comprises:
and sending the successfully synthesized video file to a material provider of the commodity material of the successfully synthesized video file in an asynchronous mode.
7. The video file composition method according to any one of claims 1 to 6, wherein the plurality of video task processing services are deployed in a distributed manner.
8. The video file synthesis method according to claim 7, wherein the obtaining video tasks to be processed in parallel by a plurality of video task processing services, and synthesizing the commodity material associated with the target video task into a video file according to the obtained target video task by each of the video task processing services comprises:
selecting a plurality of video task processing services meeting preset conditions from all the video task processing services deployed in a distributed manner;
the method comprises the steps that video tasks to be processed are obtained in parallel through a plurality of video task processing services, and commodity materials related to the target video tasks are combined into a video file through each video task processing service according to the obtained target video tasks.
9. The video file composition method according to claim 8, wherein the predetermined condition is that a usage rate of physical resources of the video task processing service is lower than a predetermined value.
10. A video file synthesizing apparatus, comprising:
the acquisition module is used for acquiring a plurality of sets of commodity materials;
the association module is used for creating a video task for each set of commodity materials and associating each created video task with the corresponding commodity material;
and the synthesis module is used for acquiring video tasks to be processed in parallel through a plurality of video task processing services, and synthesizing the commodity materials associated with the target video tasks into video files according to the acquired target video tasks through each video task processing service.
11. A computer device comprising a memory, a processor and a computer program stored on the memory and executable on the processor, the processor implementing the steps of the method of any one of claims 1 to 9 when executing the computer program.
12. A computer-readable storage medium, on which a computer program is stored, which, when being executed by a processor, carries out the steps of the method of any one of claims 1 to 9.
CN202210246945.6A 2022-03-14 2022-03-14 Video file synthesis method and device Pending CN114640806A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202210246945.6A CN114640806A (en) 2022-03-14 2022-03-14 Video file synthesis method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202210246945.6A CN114640806A (en) 2022-03-14 2022-03-14 Video file synthesis method and device

Publications (1)

Publication Number Publication Date
CN114640806A true CN114640806A (en) 2022-06-17

Family

ID=81946995

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202210246945.6A Pending CN114640806A (en) 2022-03-14 2022-03-14 Video file synthesis method and device

Country Status (1)

Country Link
CN (1) CN114640806A (en)

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20100153963A1 (en) * 2008-12-12 2010-06-17 Subbarao Kakarlamudi Workload management in a parallel database system
CN106686352A (en) * 2016-12-23 2017-05-17 北京大学 Real-time processing method of multiple video data on multi-GPU (multiple graphics processing unit) platform
CN109214855A (en) * 2018-07-11 2019-01-15 腾讯科技(北京)有限公司 Material method of reseptance, apparatus and system
CN111598672A (en) * 2020-07-27 2020-08-28 南京梦饷网络科技有限公司 Method, computing device, and computer-readable storage medium for synthesizing video
CN112351337A (en) * 2021-01-04 2021-02-09 腾讯科技(深圳)有限公司 Video quality inspection method and device, computer equipment and storage medium
CN113395541A (en) * 2020-03-13 2021-09-14 北京密境和风科技有限公司 Video file generation method, device and system

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20100153963A1 (en) * 2008-12-12 2010-06-17 Subbarao Kakarlamudi Workload management in a parallel database system
CN106686352A (en) * 2016-12-23 2017-05-17 北京大学 Real-time processing method of multiple video data on multi-GPU (multiple graphics processing unit) platform
CN109214855A (en) * 2018-07-11 2019-01-15 腾讯科技(北京)有限公司 Material method of reseptance, apparatus and system
CN113395541A (en) * 2020-03-13 2021-09-14 北京密境和风科技有限公司 Video file generation method, device and system
CN111598672A (en) * 2020-07-27 2020-08-28 南京梦饷网络科技有限公司 Method, computing device, and computer-readable storage medium for synthesizing video
CN112351337A (en) * 2021-01-04 2021-02-09 腾讯科技(深圳)有限公司 Video quality inspection method and device, computer equipment and storage medium

Similar Documents

Publication Publication Date Title
CN113038287B (en) Method and device for realizing multi-user video live broadcast service and computer equipment
CN108989885A (en) Video file trans-coding system, dividing method, code-transferring method and device
CN105009153A (en) Systems, methods, and computer-readable media for searching for events from a computer-implemented calendar
CN110826002B (en) Information sharing method, device, terminal and storage medium
CN105005599A (en) Photograph sharing method and mobile terminal
CN112532896A (en) Video production method, video production device, electronic device and storage medium
CN113345054A (en) Virtual image decorating method, detection method and device
KR101687828B1 (en) System and method for generating electronic document
CN106953924B (en) Processing method of shared information and shared client
EP2997715B1 (en) Transmitting information based on reading speed
CN112714338B (en) Video transmission method, video playing method, video transmission device, video playing device, computer equipment and storage medium
CN114154000A (en) Multimedia resource publishing method and device
CN112422604B (en) File uploading method, device and system and computer equipment
CN114640806A (en) Video file synthesis method and device
CN110415318B (en) Image processing method and device
CN104936002A (en) Screen recording method and screen recording device
CN111599449B (en) Automatic playing method, device and equipment of electronic image and storage medium
CN115170700A (en) Method for realizing CSS animation based on Flutter framework, computer equipment and storage medium
CN114371866A (en) Version reconfiguration test method, device and equipment of service system
CN113794846A (en) Video cloud clipping method and device and cloud clipping server
CN113973235A (en) Interactive information display method and device and computer equipment
CN112560938A (en) Model training method and device and computer equipment
US20230276103A1 (en) Bullet-screen-comment-based check-in implementation and creation
CN115658051A (en) Material synthesizing method and device, electronic device and storage medium
CN116668768A (en) Video processing method and electronic equipment

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