Method and apparatus for generating media, device, and storage medium

By acquiring and playing generated segments during the media generation process, the problem of long media content generation time is solved, and the generation and playback efficiency is improved.

WO2025251806A1PCT designated stage Publication Date: 2025-12-11BEIJING ZITIAO NETWORK TECH CO LTD
View PDF 4 Cites 0 Cited by

Patent Information

Application Number
PCT/CN2025/091594
Authority / Receiving Office
WO · WO
Patent Type
Applications
Current Assignee / Owner
Priority Date
2024-06-04
Filing Date
2025-04-27
Publication Date
2025-12-11

AI Technical Summary

Technical Problem

In existing technologies, media content generation takes a long time, resulting in a poor generation and playback experience.

Method used

The first device sends a media generation request to the second device, and during the process of the second device generating media content, it acquires and plays the generated segments, thereby realizing the streaming processing of media content.

Benefits of technology

It improves the efficiency of media content generation and playback, and supports real-time playback of generated segments during the generation process.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN2025091594_11122025_PF_FP_ABST
    Figure CN2025091594_11122025_PF_FP_ABST
Patent Text Reader

Abstract

The embodiments of the present disclosure relate to a method and apparatus for generating media, a device, and a storage medium. The method provided herein comprises: a first device sending a media generation request to a second device; before the second device generates complete media content based on the media generation request, acquiring a first snippet of the media content generated by the second device; and in response to receiving a playback request, playing the first snippet on the first device while the second device generates a second snippet of the media content. In this way, the embodiments of the present disclosure allow for the playback of media content while the media content is being generated, thereby improving the efficiency of media content generation and playback.
Need to check novelty before this filing date? Find Prior Art

Description

Method, device, apparatus and storage medium for generating media

[0001] The present application claims priority to the Chinese patent application No. 202410719055.1, filed on June 4, 2024, entitled "Method, device, apparatus and storage medium for generating media", the whole content of which is incorporated herein by reference. TECHNICAL FIELD

[0002] The example embodiments of the present disclosure generally relate to the field of Internet, and in particular, to a method, device, apparatus and computer readable storage medium for generating media. BACKGROUND

[0003] In recent years, with the rapid development of computer technology, people can use artificial intelligence technology to create various types of media content. Such generation technology greatly reduces the creation threshold of people and can improve the efficiency of media creation. SUMMARY

[0004] In a first aspect of the present disclosure, a method for generating media content is provided. The method comprises: sending, by a first device, a media generation request to a second device; obtaining a first segment of the media content generated by the second device before the second device generates a complete media content based on the media generation request; and in response to receiving a play request, playing the first segment at the first device while the second device generates a second segment of the media content.

[0005] In a second aspect of the present disclosure, a method for generating media content is provided. The method comprises: receiving a media generation request from a first device; generating a first segment of the media content based on the media generation request; and in response to completing the generation of the first segment, providing the first segment to the first device before generating a complete media content.

[0006] In a third aspect of the present disclosure, an apparatus for generating media content is provided. The apparatus comprises: a sending module configured to send, by a first device, a media generation request to a second device; an obtaining module configured to obtain a first segment of the media content generated by the second device before the second device generates a complete media content based on the media generation request; and a playing module configured to play the first segment at the first device while the second device generates a second segment of the media content in response to receiving a play request.

[0007] In a fourth aspect of the disclosure, an apparatus for generating media content is provided. The apparatus includes a receiving module configured to receive a media generation request from a first device; a generating module configured to generate a first segment of the media content based on the media generation request; and a providing module configured to provide the first segment to the first device before generating a complete media content in response to completing generating the first segment.

[0008] In a fifth aspect of the disclosure, an electronic device is provided. The device includes at least one processing unit; and at least one memory coupled to the at least one processing unit and storing instructions for execution by the at least one processing unit. The instructions, when executed by the at least one processing unit, cause the device to perform the method of the first aspect and the second aspect.

[0009] In a sixth aspect of the disclosure, a computer-readable storage medium is provided. The computer-readable storage medium has stored thereon a computer program, which is executable by a processor to implement the method of the first aspect and the second aspect.

[0010] In a seventh aspect of the disclosure, a computer program product is provided. The computer program product includes computer executable instructions, wherein the computer executable instructions, when executed by a processor, implement the method of the first aspect or the second aspect.

[0011] It should be understood that the contents described in this section are not intended to limit the key features or important features of the embodiments of the disclosure, nor are they used to limit the scope of the disclosure. Other features of the disclosure will become apparent through the following description. BRIEF DESCRIPTION OF DRAWINGS

[0012] The above and other features, advantages, and aspects of embodiments of the present disclosure will become more apparent by describing in detail exemplary embodiments thereof with reference to the attached drawings in which:

[0013] FIG. 1 shows a schematic diagram of an example environment in which embodiments according to the present disclosure can be implemented;

[0014] FIG. 2 shows a flowchart of an example media content generation process according to some embodiments of the present disclosure;

[0015] FIG. 3 shows an example interface according to some embodiments of the present disclosure;

[0016] FIG. 4A and FIG. 4B show a flowchart of an example process of generating media content according to some embodiments of the present disclosure;

[0017] FIG. 5A and FIG. 5B show a schematic structural block diagram of an example apparatus for generating media content according to some embodiments of the present disclosure; and

[0018] FIG. 6 illustrates a block diagram of an electronic device that can implement various embodiments of the disclosure. DETAILED DESCRIPTION

[0019] Embodiments of the disclosure will be described in more detail with reference to the accompanying drawings. While certain embodiments of the disclosure will be illustrated herein and described, it is to be understood that the disclosure is not limited to the embodiments set forth herein, but applies to any metal object, and thus generally to all compatible metal objects, as broadly described herein. Furthermore, the various characteristics can be combined in various ways. It will be apparent to those skilled in the art that the disclosure can be practiced without necessarily being limited to the specific embodiments illustrated and described. It is therefore intended that the disclosure not be limited, in all respects, to the specifics of the embodiments described herein, but rather that the scope of the disclosure be measured by the breadth of the appended claims.

[0020] It is noted that the headings provided herein are not limitations of the various embodiments of the disclosure. The various embodiments are described throughout this document and can be included under any heading. Furthermore, embodiments described in any heading can be combined with any other embodiment described in the same heading and / or a different heading in any manner.

[0021] In the description of embodiments of the disclosure, the term "including" and its analogs are to be understood explicitly as the inclusion of half or more of something. The term "based on" is to be understood as "based at least in part on". The term "one embodiment" or "the embodiment" is to be understood as "at least one embodiment". The term "some embodiments" is to be understood as "at least some embodiments". Other explicit and implicit definitions can also be included below. The terms "first", "second", etc. can refer to different or the same objects. Other explicit and implicit definitions can also be included below.

[0022] Data of users, acquisition and / or use of data, etc. can be involved in embodiments of the disclosure. These aspects all comply with corresponding laws and regulations and relevant provisions. In embodiments of the disclosure, all data collection, acquisition, processing, processing, forwarding, use, etc. are carried out on the premise that the user is aware of and confirms. Accordingly, when implementing various embodiments of the disclosure, the type of data or information that can be involved, the scope of use, the use scenario, etc. should be informed to the user and authorized by the user in a proper manner according to relevant laws and regulations. The specific informing and / or authorization manner can vary according to the actual situation and application scenario, and the scope of the disclosure is not limited in this respect.

[0023] In the specification and embodiments of the present disclosure, if personal information processing is involved, the processing will be performed on the premise of legality (for example, obtaining the consent of the subject of personal information, or being necessary for the performance of a contract, etc.), and will be processed only within the prescribed or agreed range. Users refuse to process personal information other than the necessary information required for basic functions, which will not affect the user's use of basic functions.

[0024] As mentioned above, people can use artificial intelligence technology to create various types of media content, such as video content, music content, etc. Such generation technology greatly reduces the creation threshold of people and can improve the efficiency of media creation. However, the generation of media content currently requires a long time, and people need to wait for the media content to be generated before they can play the media content, which greatly affects the generation and playback experience of media content.

[0025] Embodiments of the present disclosure propose a scheme for generating media. According to the scheme, a media generation request is sent from a first device to a second device; before the second device generates complete media content based on the media generation request, a first segment of the media content generated by the second device is obtained; and in response to receiving a playback request, the first segment is played at the first device while the second device generates a second segment of the media content.

[0026] In this way, embodiments of the present disclosure can support the playback of the generated segment during the generation process of the media content, thereby improving the generation and playback efficiency of the media content.

[0027] Various example implementations of the scheme are described in further detail below in conjunction with the accompanying drawings.

[0028] Example environment

[0029] FIG. 1 shows a schematic diagram of an example environment 100 in which embodiments of the present disclosure can be implemented. As shown in FIG. 1, the example environment 100 can include a first device 110. As an example, the first device 110 can be a terminal device of a user 140.

[0030] In this example environment 100, the first device 110 can run an application 120 that supports interface interaction. The application 120 can be any appropriate type of application for interface interaction, examples of which can include but are not limited to a media application or other appropriate application. The user 140 can interact with the application 120 via the first device 110 and / or its attached devices.

[0031] In the environment 100 of FIG. 1, if the application 120 is in an active state, the first device 110 can present an interface 150 for supporting interface interaction through the application 120.

[0032] In some embodiments, the first device 110 communicates with the second device 130 to enable provisioning of services of the application 120. The first device 110 can be any type of mobile terminal, fixed terminal, or portable terminal including a mobile handset, a tablet computer, a laptop computer, a notebook computer, a netbook computer, a tablet computer, a media computer, a multimedia tablet, a palmtop computer, a portable gaming terminal, a VR / AR device, a Personal Communication System (PCS) terminal, a personal navigation device, a Personal Digital Assistant (PDA), an audio / video player, a digital camera / camcorder, a positioning device, a television receiver, a radio broadcast receiver, an electronic book device, a game device, or any combination thereof, including accessories and peripherals of these devices, or any combination thereof. In some embodiments, the first device 110 can also be capable of supporting any type of interface to a user (such as "wearable" circuitry, etc.).

[0033] As an example, the second device 130 can be, for example, a remote device. For example, the second device 130 can be a standalone physical server, a server cluster or distributed system composed of multiple physical servers, a cloud server providing cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communications, middleware services, domain name services, security services, content distribution networks, and basic cloud computing services such as big data and artificial intelligence platforms, etc. The second device 130 can include, for example, a computing system / server such as a mainframe, an edge computing node, a computing device in a cloud environment, etc. The second device 130 can provide background services for the application 120 in the first device 110 that supports virtual scenarios.

[0034] A communication connection can be established between the second device 130 and the first device 110. The communication connection can be established by wired or wireless means. The communication connection can include, but is not limited to, a Bluetooth connection, a mobile network connection, a Universal Serial Bus (USB) connection, a Wireless Fidelity (WiFi) connection, etc., and embodiments of the present disclosure are not limited in this regard. In embodiments of the present disclosure, the second device 130 and the first device 110 can implement signaling interaction through the communication connection therebetween.

[0035] It should be understood that the structure and function of the various elements in the environment 100 are described for illustrative purposes only, and do not imply any limitation on the scope of the present disclosure.

[0036] Some example embodiments of the present disclosure will be described below with continued reference to the accompanying drawings.

[0037] Generation of media content

[0038] For convenience of description, the following will describe the process of media content generation and playing according to embodiments of the present disclosure by taking music content as an example of media content. It should be understood that such process is also applicable to time-sequential media content such as video content.

[0039] The following will describe an example process of generating media content according to some embodiments of the present disclosure with reference to FIG. 2 and FIG. 3. FIG. 2 shows a flowchart of a process 200 according to some embodiments of the present disclosure.

[0040] As shown in FIG. 2, the process 200 can involve a plurality of components or modules, for example, a client 201, an interface service 202, a task queue 203, a generation service 204, a first storage 205 and a second storage 206.

[0041] As an example, the client 201 can be deployed at the first device 110 as shown in FIG. 1, for example. The interface service 202 and the task queue 203 can be provided or managed by the second device 130, for example. The generation service 204, the first storage 205 and the second storage 206 can be accessed or invoked by the generation service 130.

[0042] As shown in FIG. 2, the client 201 can send a media generation request to the interface service 202 of the second device 130, such media generation request can include a set of generation parameters. FIG. 3 shows an example generation interface 300 according to some embodiments of the present disclosure, which can be provided by the client 201.

[0043] As shown in FIG. 3, the client 201 can provide one or more controls for configuring generation parameters, for example, a control 310, a control 320, a control 330 and a control 340. The client 201 can obtain generation parameters via the above controls, and can send a media generation request to the interface service 202 in response to a user preset operation. As an example, such generation parameters can include lyrics, style, timbre, name, etc.

[0044] Continuing to refer to FIG. 2, the interface service 202 can create a corresponding task based on the received media generation request, and can return a task identification corresponding to the task to the client 201. Additionally, the interface service 202 can also register the asynchronous task to the task queue 203.

[0045] Further, as shown, the task queue 203 can schedule the submitted tasks, reasonably allocate task priorities and distribute the tasks to the generation service 204. The task queue 203 can also track and manage the status of all tasks, and actively notify the interface service 202 when the status changes.

[0046] For example, when a media generation task submitted by the client 201 is submitted to the generation service 204 for execution, the generation service 204 can stream back a segment of the media content. Specifically, when the generation service 204 completes generation of a first segment of a preset length, the generation service 204 can return the generated first segment to the task queue 203.

[0047] Further, if the returned first segment is the first segment of the media content, the task queue 203 can also modify the status to a processing status (processing) and can generate a resource address corresponding to the media content. In some embodiments, the resource address can be a streaming media address. Further, the task queue 203 can upload the generated first segment to the first storage 205.

[0048] In addition, if the returned segment is a subsequent segment of the media content, the task queue 203 can also perform splicing processing on the segment. For example, the task queue 203 can receive the current segment by superimposing the beginning part of the returned segment and the end part of the previous segment of the segment. For example, the task queue 203 can use a cross-fade technique to cross superimpose the tail and the head of the previous and subsequent segments for a certain time length, so as to achieve seamless splicing between the segments. Further, the task queue 203 can upload the processed segment file to the first storage 205.

[0049] Further, after the generation service 204 completes generation of the complete media content (for example, music content), the task queue 203 can generate the complete media content based on all the received segments, and can upload the complete media content to the second storage 206. Accordingly, the second storage 206 can return an identifier corresponding to the media content, for example, a music identifier.

[0050] In some embodiments, the task queue 203 can also trigger the first storage 205 to delete one or more stored segments. Further, the task queue 203 can correspondingly mark the task as a finish status.

[0051] With reference to FIG. 2, after obtaining the task identifier, the client 201 can poll the task status based on the task identifier. For example, the client 201 can periodically send a status query request about the submitted media generation request to the interface service 202.

[0052] Accordingly, the interface service 202 can determine the status of the corresponding task based on the task identifier. In some embodiments, the task can correspond to three possible statuses, namely, a queueing status (queueing), a processing status (processing), and a finish status (finish).

[0053] Accordingly, the queuing status indicates that the corresponding media generation request has not been submitted to the generation service 204, or the generation service 204 has not completed the generation of the first segment. The processing status indicates that the generation service 204 has completed the generation of the first segment, and has not completed the generation of the complete media content. The completion status indicates that the generation service has completed the generation of the complete media content.

[0054] In response to determining the media generation request is not in the processing status, the interface service 202 can return the resource address corresponding to the media content to the client 201. Additionally, the interface service 202 can also send the lyrics and title information of the media content.

[0055] Further, as shown in FIG. 2, after obtaining the resource address, the client 201 can play the first segment of the media content based on the resource address. Specifically, as shown in FIG. 3, the electronic device 110 can receive a user selection of the media content 360, and trigger playing one or more segments generated based on the media content 360.

[0056] In some embodiments, while other segments of the media content are being generated, the electronic device 110 can play the segment that can be obtained based on the resource address. In some embodiments, the electronic device 110 can also display the progress information 350 in the interface 300 to indicate the progress of the generation of the media content.

[0057] In some embodiments, the electronic device 110 can also display the description information 370 of the generated media content, such as the cover, lyrics, title, etc.

[0058] In some embodiments, the electronic device 110 can also provide a play control component 380 to support user control of the play process of the media content. For example, the electronic device 110 can support user fast forward or rewind operations in the already generated segment part.

[0059] The specific implementation of the client 201 playing the media content based on the resource address will be described below with reference to FIG. 2. As shown in FIG. 2, after obtaining the resource address, the client 201 can send the resource address to the interface service 202. Further, the interface service 202 can query the segment corresponding to the resource address. Further, the interface service 202 can request the segment from the first storage 205, and obtain the corresponding segment file. Accordingly, the interface service 202 can send the obtained segment file to the client 201.

[0060] In some embodiments, the client 201 can also directly access the first storage 205 through the resource address to obtain the segment file to be played, for example.

[0061] With reference back to FIG. 2, after the complete media content is generated, the task can be marked as a completed state. Accordingly, the interface service 202 can return an updated resource address of the media content in response to a polling request from the client 201, so that the client 201 can obtain the complete media content stored in the second storage 206.

[0062] Embodiments of the present disclosure can support playing of the generated segments during the generation of the media content, thereby improving the generation and playing efficiency of the media content.

[0063] Example process

[0064] FIG. 4A illustrates a flowchart of an example process 400A of generating media content, according to some embodiments of the present disclosure. The process 400A can be implemented at the first device 110. The process 400A is described below with reference to FIG. 1.

[0065] As shown in FIG. 4A, at block 410, the first device 110 sends a media generation request to the second device.

[0066] At block 420, the first device 110 obtains a first segment of the media content generated by the second device before the second device generates the complete media content based on the media generation request.

[0067] At block 430, the first device 110 plays the first segment at the first device while the second device generates a second segment of the media content in response to receiving a play request.

[0068] In some embodiments, the method further includes presenting progress information in the generation interface, the progress information indicating a progress of the generation of the media content.

[0069] In some embodiments, obtaining the first segment of the media content generated by the second device includes obtaining a resource address corresponding to the media generation request from the second device, and obtaining the first segment generated by the second device by accessing the resource address.

[0070] In some embodiments, obtaining the resource address corresponding to the media generation request from the second device includes querying a status of the media generation request from the second device, and obtaining the resource address from the second device, wherein the resource address is returned by the second device in response to the media generation request being in a processing state.

[0071] In some embodiments, querying the status of the media generation request from the second device includes obtaining a task identification from the second device, the task identification corresponding to a task created by the second device based on the generation request, and querying the status of the media generation request from the second device based on the task identification.

[0072] In some embodiments, the resource address comprises a streaming media address corresponding to the media content.

[0073] In some embodiments, the first segment or the second segment has a preset time length.

[0074] In some embodiments, the media generation request indicates a set of generation parameters.

[0075] FIG. 4B illustrates a flowchart of an example process 400B of generating media content, according to some embodiments of the present disclosure. The process 400B can be implemented at the second device 130. The process 400B is described below with reference to FIG. 1.

[0076] As shown in FIG. 4B, at block 440, the second device 130 receives the media generation request from the first device.

[0077] At block 450, the second device 130 generates the first segment of the media content based on the media generation request.

[0078] At block 460, the second device 130 provides the first segment to the first device before generating the complete media content, in response to completing the generation of the first segment.

[0079] In some embodiments, providing the first segment to the first device comprises: associating the first segment to a resource address corresponding to the media content; and providing the resource address to the first device for the first device to obtain the first segment via the resource address.

[0080] In some embodiments, providing the resource address to the first device comprises: receiving a query request from the first device, the query request being used to query a status of the media generation request; and providing the resource address to the first device in response to the media generation request being in a processing status.

[0081] In some embodiments, receiving the query request from the first device comprises: creating a task corresponding to the generation request; sending a task identification corresponding to the task to the first device; and receiving the query request initiated based on the task from the first device.

[0082] In some embodiments, the method further comprises: marking the media generation request as in a processing status in response to completing the generation of the first segment of the media content.

[0083] In some embodiments, the resource address is a streaming media address.

[0084] In some embodiments, the first device is further configured to: play the first segment at the first device while generating the second segment of the media content in response to receiving the play request.

[0085] In some embodiments, the method further includes: in response to completing generation of the third segment of the media content, updating the third segment by superimposing the first portion of the first segment and the second portion of the third segment, the third segment being a next segment of the first segment in the media content.

[0086] In some embodiments, the method includes: storing at least one segment of the media content in the first storage space before completing generation of the complete media content; and in response to completing generation of the complete media content by the device, deleting the at least one segment from the first storage space and storing the media content in the second storage space.

[0087] In some embodiments, the first segment has a preset time length.

[0088] Example apparatus and device

[0089] Embodiments of the present disclosure also provide a corresponding apparatus for implementing the above method or process. FIG. 5A shows a schematic structural block diagram of an example apparatus 500A for generating media content, according to certain embodiments of the present disclosure. The apparatus 500A can be implemented as or included in the first device 110. Various modules / components in the apparatus 500A can be implemented by hardware, software, firmware, or any combination thereof.

[0090] As shown in FIG. 5A, the apparatus 500A includes a sending module 510 configured to send, by the first device, a media generation request to a second device; an obtaining module 520 configured to obtain, before the second device generates a complete media content based on the media generation request, a first segment of the media content generated by the second device; and a playing module 530 configured to, in response to receiving a playing request, play the first segment at the first device while the second device generates a second segment of the media content.

[0091] In some embodiments, the apparatus 500A further includes a presenting module configured to present, in a generation interface, progress information indicating a generation progress of the media content.

[0092] In some embodiments, the obtaining module 520 is further configured to: obtain, from the second device, a resource address corresponding to the media generation request; and obtain the first segment generated by the second device by accessing the resource address.

[0093] In some embodiments, the obtaining module 520 is further configured to: query, from the second device, a status of the media generation request; and obtain, from the second device, the resource address, wherein the resource address is returned by the second device in response to the media generation request being in a processing status.

[0094] In some embodiments, the obtaining module 520 is further configured to: obtain, from the second device, a task identifier, the task identifier corresponding to a task created by the second device based on the generation request; and query, based on the task identifier, the second device for a status of the media generation request.

[0095] In some embodiments, the resource address comprises a streaming media address corresponding to the media content.

[0096] In some embodiments, the first segment or the second segment has a preset time length.

[0097] In some embodiments, the media generation request indicates a set of generation parameters.

[0098] Embodiments of the present disclosure also provide a corresponding apparatus for implementing the above method or process. FIG. 5B shows a schematic structural block diagram of an example apparatus 500B for generating media content, according to certain embodiments of the present disclosure. The apparatus 500B can be implemented as or included in the second device 130. Various modules / components in the apparatus 500B can be implemented by hardware, software, firmware, or any combination thereof.

[0099] As shown in FIG. 5B, the apparatus 500B includes a receiving module 540 configured to receive, from a first device, a media generation request; a generating module 550 configured to generate, based on the media generation request, a first segment of media content; and a providing module 560 configured to provide, in response to completion of generating the first segment, the first segment to the first device before generating a complete media content.

[0100] In some embodiments, the providing module 560 is further configured to: associate the first segment to a resource address corresponding to the media content; and provide the resource address to the first device for the first device to obtain the first segment via the resource address.

[0101] In some embodiments, the receiving module 540 is further configured to: receive, from the first device, a query request, the query request being used to query a status of the media generation request; and provide, in response to the media generation request being in a processing state, the resource address to the first device.

[0102] In some embodiments, the receiving module 540 is further configured to: create a task corresponding to the generation request; send, to the first device, a task identifier corresponding to the task; and receive, from the first device, a query request initiated based on the task identifier.

[0103] In some embodiments, the generating module 550 is further configured to: in response to completion of generating a first segment of the media content, mark the media generation request as being in a processing state.

[0104] In some embodiments, the resource address is a streaming media address.

[0105] In some embodiments, the generating module 550 is further configured to, in response to receiving the play request, play the first segment at the first device while generating the second segment of the media content.

[0106] In some embodiments, the generating module 550 is further configured to, in response to completing the third segment of the media content, update the third segment by superimposing the first portion of the first segment and the second portion of the third segment, the third segment being a next segment of the first segment in the media content.

[0107] In some embodiments, at least one segment of the media content is stored in the first storage space before completing the generation of the complete media content; in response to completing the device complete media content, the at least one segment is deleted from the first storage space and the media content is stored to the second storage space.

[0108] In some embodiments, the first segment has a preset time length.

[0109] FIG. 6 illustrates a block diagram of an electronic device 600 in which one or more embodiments of the disclosure can be implemented. It should be understood that the electronic device 600 illustrated in FIG. 6 is merely exemplary and should not be construed as limiting the functionality and scope of the embodiments described herein. The electronic device 600 illustrated in FIG. 6 can be used to implement the first device 110 and / or the second device 130 of FIG. 1.

[0110] As shown in FIG. 6, the electronic device 600 is in the form of a general electronic device. The components of the electronic device 600 can include, but are not limited to, one or more processors or processing units 610, a memory 620, a storage device 730, one or more communication units 640, one or more input devices 650, and one or more output devices 660. The processing unit 610 can be an actual or virtual processor and is capable of performing various processing according to programs stored in the memory 620. In a multi-processor system, multiple processing units perform computer-executable instructions in parallel to improve the parallel processing capability of the electronic device 600.

[0111] The electronic device 600 typically includes a plurality of computer storage media. Such media can be any available media that is accessible by the electronic device 600 and includes both volatile and nonvolatile media, removable and non-removable media. The memory 620 can be volatile (such as register, cache, RAM), non-volatile (such as ROM, EEPROM, flash memory), or some combination of the two. The storage device 630 can be a removable or non-removable media, and can include machine-readable media, such as flash drives, magnetic disks, or any other media that can be used to store information and / or data and that can be accessed by the electronic device 600.

[0112] The electronic device 600 can further include additional removable / non-removable, volatile / non-volatile storage media. Although not shown in FIG. 6, a disk drive for reading from or writing to a removable, non- volatile magnetic disk (e.g., a "floppy disk"), and an optical disk drive for reading from or writing to a removable, non-volatile optical disk (e.g., a CD-ROM) can be provided. In such instances, each drive can be connected to the bus (not shown) by one or more data media interfaces. The memory 620 can include a computer program product 625 having one or more program modules configured to carry out the various methods or actions of the various embodiments of the present disclosure.

[0113] The communication unit 640 enables communications with other electronic devices over a communication medium. Additionally, the functionality of the components of the electronic device 600 can be implemented in a single computing cluster or a plurality of computer machines that are capable of communicating with one another over a communication connection. As such, the electronic device 600 can operate in a networked environment using logical connections to one or more other servers, network personal computers (PCs), or another network nodes.

[0114] The input device 650 can be one or more input devices, such as a mouse, a keyboard, a trackball, etc. The output device 660 can be one or more output devices, such as a display, a speaker, a printer, etc. The electronic device 600 can also communicate with one or more external devices (not shown) such as a storage device, a display device, etc. through the communication unit 640, as needed, one or more devices that enable a user to interact with the electronic device 600, or any devices (e.g., a network card, a modem, etc.) that enable the electronic device 600 to communicate with one or more other electronic devices. Such communication can be carried out via an input / output (I / O) interface (not shown).

[0115] According to an example implementation of the present disclosure, a computer readable storage medium is provided having computer executable instructions stored thereon, where the computer executable instructions are executed by a processor to implement the method described above. According to an example implementation of the present disclosure, a computer program product is also provided that is tangibly stored on a non-transitory computer readable medium and includes computer executable instructions, where the computer executable instructions are executed by a processor to implement the method described above.

[0116] The computer readable program instructions can also be loaded onto a computer, other programmable data processing apparatus, or other device to cause a series of operational steps to be performed on the computer, other programmable apparatus or other device to produce a computer implemented process such that the instructions which execute on the computer or other programmable apparatus provide processes for implementing the functions / acts specified in the flowchart and / or block diagram block or blocks.

[0117] The computer readable program instructions can also be loaded onto a computer, other programmable data processing apparatus, or other device to cause a series of operational steps to be performed on the computer, other programmable apparatus or other device to produce a computer implemented process such that the instructions which execute on the computer or other programmable apparatus provide processes for implementing the functions / acts specified in the flowchart and / or block diagram block or blocks.

[0118] The computer readable program instructions can also be loaded onto a computer, other programmable data processing apparatus, or other device to cause a series of operational steps to be performed on the computer, other programmable apparatus or other device to produce a computer implemented process such that the instructions which execute on the computer or other programmable apparatus provide processes for implementing the functions / acts specified in the flowchart and / or block diagram block or blocks.

[0119] The computer program product of the present disclosure can have a signal including said computer program. This signal can be electronic, electromagnetic, optical, or any other suitable type of signal. Such a signal can be provided through a communication connection, such as electrical wiring, optical fiber, wireless interface, etc. Examples of computer program products include computer program implemented on a personal computer, server, or other networked device. A non-transitory computer readable medium, such as a floppy disk, CD-ROM, DVD-ROM, Blu-ray Disc, hard disk, or memory stick, can also be used to implement the present disclosure. The computer program product of the present disclosure can also be provided as a service to download and use the computer program over a network, such as the Internet.

[0120] Having described several implementations of the present disclosure, it will be clear to those skilled in the art that many modifications, additions, and substitutions are possible without departing from the scope and spirit of the described implementations. Many modifications and variations of the present disclosure are possible in light of the above teachings. It is, therefore, to be understood that within the scope of the appended claims, the present disclosure can be practiced otherwise than as specifically described. While the present disclosure has been described with reference to the implementation figures, it will be understood by those skilled in the art that various changes can be made and equivalents can be substituted for elements thereof without departing from the scope of the present disclosure. In addition, many modifications can be made to adapt a particular situation or material to the teachings of the disclosure without departing from its scope. Therefore, it is contemplated to cover any and all adaptations and modifications falling within the scope of the appended claims. It should also be noted that, in this document, the terms "can", "can not", "may", "may not", "might", "might not", "must", "must not", "need", "need not", "should", "should not", "will", "will not", "would", and "would not" are used in their permissive sense (they mean that there are situations in which the statement can or might be true).

Claims

1. A method for generating media content, comprising: sending, by a first device, a media generation request to a second device; obtaining a first segment of the media content generated by the second device before the second device generates a complete media content based on the media generation request; and playing, at the first device, the first segment while the second device generates a second segment of the media content in response to receiving a play request. 2.The method of claim 1, further comprising: presenting progress information in a generation interface, the progress information indicating a progress of the media content generation. 3.The method of claim 1, wherein obtaining the first segment of the media content generated by the second device comprises: obtaining, from the second device, a resource address corresponding to the media generation request; and obtaining the first segment generated by the second device by accessing the resource address. 4.The method of claim 3, wherein obtaining, from the second device, the resource address corresponding to the media generation request comprises: inquiring, from the second device, a status of the media generation request; and obtaining the resource address from the second device, wherein the resource address is returned by the second device in response to the media generation request being in a processing status. 5.The method of claim 4, wherein inquiring, from the second device, the status of the media generation request comprises: obtaining, from the second device, a task identification corresponding to a task created by the second device based on the generation request; and inquiring, from the second device, the status of the media generation request based on the task identification. 6.The method of claim 3, wherein the resource address comprises a streaming media address corresponding to the media content. 7.The method of claim 1, wherein the first segment or the second segment has a preset time length. 8.The method of claim 1, wherein the media generation request indicates a set of generation parameters. 9.A method for generating media content, comprising: receiving, from a first device, a media generation request; generating a first segment of a media content based on the media generation request; and providing, to the first device, the first segment before generating a complete media content in response to completing generating the first segment. 10.The method of claim 9, wherein providing, to the first device, the first segment comprises: associating the first segment to a resource address corresponding to the media content; and providing, to the first device, the resource address for the first device to obtain the first segment via the resource address. 11.The method of claim 10, wherein providing, to the first device, the resource address comprises: receiving, from the first device, a query request for querying a status of the media generation request; and providing, to the first device, the resource address in response to the media generation request being in a processing status. 12.The method of claim 11, wherein receiving, from the first device, the query request comprises: ​ ​ ​ ​ ​ ​ ​ creating a task corresponding to the generation request; sending a task identification corresponding to the task to the first device; and receiving, from the first device, the query request initiated based on the task.

13. The method of claim 11, further comprising: in response to completing generation of a first segment of the media content, marking the media generation request as in-process.

14. The method of claim 10, wherein the resource address is a streaming media address.

15. The method of claim 9, wherein the first device is further configured to: in response to receiving a play request, playing the first segment at the first device while a second segment of the media content is being generated.

16. The method of claim 9, further comprising: in response to completing generation of a third segment of the media content, updating the third segment by superimposing a first portion of the first segment and a second portion of the third segment, the third segment being a next segment of the first segment in the media content.

17. The method of claim 9, further comprising: prior to completing generation of the complete media content, storing at least one segment of the media content in a first storage space; in response to completing generation of the complete media content, deleting the at least one segment from the first storage space and storing the media content to a second storage space.

18. The method of claim 9, wherein the first segment has a preset time length.

19. An apparatus for generating media content, comprising: a sending module configured to send, by a first device, a media generation request to a second device; an obtaining module configured to obtain, by the second device, a first segment of the media content generated by the second device prior to the second device generating a complete media content based on the media generation request; and a playing module configured to play, by the first device, the first segment in response to receiving a play request while a second segment of the media content is being generated by the second device.

20. An apparatus for generating media content, comprising: a receiving module configured to receive, from a first device, a media generation request; a generating module configured to generate, based on the media generation request, a first segment of the media content; and a providing module configured to provide, to the first device, the first segment prior to generating a complete media content in response to completing generation of the first segment.

21. An electronic device, comprising: at least one processing unit; and at least one memory coupled to the at least one processing unit and storing instructions for execution by the at least one processing unit, the instructions when executed by the at least one processing unit cause the electronic device to perform the method of any of claims 1-8 or 9-18.

22. A computer-readable storage medium having stored thereon a computer program executable by a processor to implement the method of any of claims 1-8 or 9-18. ​ 23. A computer program product, the computer program product being tangibly stored in a computer storage medium and comprising computer-executable instructions that, when executed by a device, cause the device to perform the method of any of claims 1-8 or 9-18.

Citation Information

Patent Citations

  • Enhanced block-request streaming system for handling low-latency streaming

    CN104221390A

  • Media processing method and apparatus, and terminal

    CN106375859A

  • Short video production method and system

    CN110266971A

  • Media generation method and device, equipment and storage medium

    CN118714242A