Video playing method and device, computer device and storage medium

By obtaining video configuration parameters and initial video client templates, the target video format and client template are generated, solving the problem of poor browser video format compatibility and realizing a low-cost and efficient video playback method that is compatible with multiple video formats and playback clients.

CN116567347BActive Publication Date: 2026-02-17HANGZHOU HUACHENG SOFTWARE TECH CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202310353614.7
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2023-03-31
Publication Date
2026-02-17
Estimated Expiration
2043-03-31

AI Technical Summary

Technical Problem

In existing technologies, browsers have poor compatibility with video formats, which necessitates the installation of multiple video playback plugins, increasing the cost of video playback.

Method used

By acquiring video configuration parameters and initial video templates, determining the target video format and template, and generating video playback results, this method provides a way to be compatible with multiple video formats and playback devices. By leveraging the division of labor between the basic player and the template layer, it enables the generation of video playback results and the execution of user operation commands.

Benefits of technology

It reduces development costs, improves development efficiency, and enables low-cost and efficient video playback, is compatible with various video stream formats and playback terminals, and reduces the need for browsers to install multiple plugins.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116567347B_ABST
    Figure CN116567347B_ABST
Patent Text Reader

Abstract

The application relates to a video playing method and device, computer equipment and a storage medium. The method comprises the following steps: acquiring preset video configuration parameters and at least two initial video terminal templates; determining page static resources; wherein the page static resources comprise at least two preset video formats; based on the video configuration parameters, the page static resources are used to determine a target video format corresponding to the video configuration parameters from the preset video formats, and a target video terminal template corresponding to the video configuration parameters is determined from the initial video terminal templates; and a video playing result is generated according to the target video format and the target video terminal template. The method can solve the problem of high video playing cost.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present application relates to the technical field of digital information transmission, and in particular to a video playing method and device, computer equipment and a storage medium. BACKGROUND

[0002] With the rapid development of science and technology, the application scenarios of videos are becoming more and more extensive, and various units, enterprises, families and individuals have different consumption demands for videos. Among them, the browser is an important tool for searching, displaying and delivering information resources, which can present web pages, pictures or videos. However, the browsers of various terminals are not compatible with each other in terms of video formats, and the built-in playing components of various browsers cannot directly meet the needs of developers and need to be developed again. However, in the related art, it is difficult to provide a playing component that can be compatible with all playing formats and all video playing terminals. Most video playing plug-ins can only play one format or type of video, so a browser usually needs to install multiple video playing plug-ins, resulting in high cost of video playing.

[0003] At present, there is no effective solution to the problem of high cost of video playing in the related art. SUMMARY

[0004] Therefore, it is necessary to provide a video playing method, device, computer equipment and storage medium to solve the above technical problems.

[0005] In a first aspect, the present application provides a video playing method. The method comprises:

[0006] obtaining preset video configuration parameters and at least two initial video terminal templates;

[0007] determining page static resources; wherein the page static resources include at least two preset video formats;

[0008] based on the video configuration parameters, determining a target video format corresponding to the video configuration parameters from the preset video formats and a target video terminal template corresponding to the video configuration parameters from the initial video terminal templates by using the page static resources;

[0009] generating a video playing result according to the target video format and the target video terminal template.

[0010] In one embodiment, the video playing result includes at least two function function information, and after the video playing result is generated according to the target video format and the target video terminal template, the method further comprises:

[0011] The preset operation instruction is acquired, the corresponding target function function information in the function function information is triggered according to the operation instruction, and the control information of the video playing result is generated according to the target function function information.

[0012] In one of the embodiments, based on the video configuration parameter, a target video format corresponding to the video configuration parameter is determined from the preset video format, including:

[0013] An initial address corresponding to the page static resource is acquired.

[0014] The video configuration parameter is translated into an initial address suffix, a target address is generated according to the initial address and the initial address suffix, and a target video format corresponding to the video configuration parameter is determined from the preset video format according to the target address.

[0015] In one of the embodiments, after the target address is generated according to the initial address and the initial address suffix, the method further includes,

[0016] The page static resource is called according to the target address, and in the case that the page static resource calling is detected to be successful, success callback information generated by the page static resource is acquired;

[0017] In response to the acquired success callback information, video segment template indication information is acquired.

[0018] The corresponding target video segment template is determined from the initial video segment template according to the video segment template indication information and the video configuration parameter.

[0019] In one of the embodiments, the target video segment template includes a default attribute parameter, the video configuration parameter includes a target attribute parameter, and the method further includes:

[0020] Based on the video configuration parameter, an initial video segment template corresponding to the video configuration parameter is determined from the initial video segment template.

[0021] In the case that the default attribute parameter is detected to be the same as the target attribute parameter, the initial video segment template is subjected to a template updating operation according to the default attribute parameter, and the target video segment template is generated.

[0022] In the case that the default attribute parameter is detected to be different from the target attribute parameter, the initial video segment template is subjected to a template updating operation according to the target attribute parameter, and the target video segment template is generated.

[0023] In one of the embodiments, the video playing result is generated according to the target video format and the target video segment template, including:

[0024] A player function corresponding to at least one player component is acquired, the player function is subjected to an encapsulation processing, and a player function group is generated.

[0025] According to the video configuration parameter and the target video terminal template, a player function group is called, and a video playing result is generated according to the target video format by using the player function group.

[0026] In a second aspect, the present application further provides a video playing device. The device comprises:

[0027] An acquisition module is configured to acquire preset video configuration parameters and at least two initial video terminal templates, and determine page static resources, wherein the page static resources comprise at least two preset video formats.

[0028] A calculation module is configured to determine, based on the video configuration parameters, a target video format corresponding to the video configuration parameters from the preset video formats by using the page static resources, and a target video terminal template corresponding to the video configuration parameters from the initial video terminal templates.

[0029] A generation module is configured to generate a video playing result according to the target video format and the target video terminal template.

[0030] In a third aspect, the present application further provides a computer device. The computer device comprises a memory and a processor, the memory stores a computer program, and the processor implements the following steps when executing the computer program:

[0031] The preset video configuration parameters and at least two initial video terminal templates are acquired.

[0032] The page static resources are determined, wherein the page static resources comprise at least two preset video formats.

[0033] Based on the video configuration parameters, a target video format corresponding to the video configuration parameters is determined from the preset video formats by using the page static resources, and a target video terminal template corresponding to the video configuration parameters is determined from the initial video terminal templates.

[0034] A video playing result is generated according to the target video format and the target video terminal template.

[0035] In a fourth aspect, the present application further provides a computer readable storage medium. The computer readable storage medium stores a computer program, and the computer program is executed by a processor to implement the following steps:

[0036] The preset video configuration parameters and at least two initial video terminal templates are acquired.

[0037] The page static resources are determined, wherein the page static resources comprise at least two preset video formats.

[0038] determine a target video format corresponding to the video configuration parameter from preset video formats and a target video end template corresponding to the video configuration parameter from initial video end templates based on the video configuration parameter;

[0039] generate a video playing result according to the target video format and the target video end template.

[0040] The video playing method, device, computer device and storage medium can first acquire a video configuration parameter input by a user, then determine a target video format from preset video formats and a target video end template from initial video end templates according to the video configuration parameter, and finally generate a video playing result according to the target video format and the target video end template. The video playing method, device, computer device and storage medium can realize the adaptation of different video formats and different video playing ends based on a basic player, provide a video playing method that can be compatible with various video stream formats and various playing ends, avoid the high video playing cost caused by the need of installing multiple video playing plug-ins in one browser, reduce the development cost and the developer's interfacing cost, effectively improve the efficiency of the developer, and thus solve the problem of high video playing cost and realize a low-cost and efficient video playing method. BRIEF DESCRIPTION OF DRAWINGS

[0041] Figure 1 a flowchart of a video playing method in one embodiment;

[0042] Figure 2 a flowchart of a video playing method in another embodiment;

[0043] Figure 3 a flowchart of a video playing method in another embodiment;

[0044] Figure 4 a structural diagram of a video playing method in one preferred embodiment;

[0045] Figure 5 a structural block diagram of a video playing device in one embodiment;

[0046] Figure 6 an internal structural diagram of a computer device in one embodiment. DETAILED DESCRIPTION

[0047] To make the objects, technical solutions and advantages of the present application clearer, the present application will be further described in detail below with reference to the drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present application and should not be used to limit the present application.

[0048] In one embodiment, as shown in FIG. 1, a video playing method comprises the following steps. Figure 1As shown, a video playing method is provided, Figure 1 is a flowchart of a video playing method according to an embodiment of the present application, comprising the following steps:

[0049] In step S110, preset video configuration parameters and at least two initial video terminal templates are acquired; page static resources are determined; the page static resources include at least two preset video formats;

[0050] The preset video configuration parameters are acquired by user input, and the video configuration parameters are used to indicate the video stream format required in the current video playing application scenario and the user's personalized information, etc. The preset video terminal templates include H5 terminal templates and web terminal templates, etc. If other types of templates are needed, they can be added. The page static resources are applied to the present application in the form of a video player, which includes multiple preset video formats such as HLS, FLV, and rtsp, etc. If other types of templates are needed, they can be added and processed.

[0051] In step S120, based on the video configuration parameters, the page static resources are used to determine a target video format corresponding to the video configuration parameters from the preset video formats, and a target video terminal template corresponding to the video configuration parameters is determined from the initial video terminal templates.

[0052] The corresponding target video format is selected from the multiple page static resources, i.e. the multiple video formats of the basic player, based on the video configuration parameters, and the target video terminal template corresponding to the video configuration parameters is determined from the preset video terminal templates. Specifically, in actual application, the page static resources are applied in the form of a basic player, and the video terminal templates are deployed in a template layer, wherein the template layer includes multiple preset video terminal templates, and new video terminal templates can also be added according to actual needs. The developer can listen to the status of the basic player at this time through the template layer, the template layer and the basic player are connected through an inline frame element such as iframe, the corresponding target video format is selected from the multiple video formats of the basic player according to the video configuration parameters, and the corresponding target video terminal template is selected in the template layer based on the video configuration parameters. This step selects the video format and the video terminal template through the video configuration parameters, thereby not only realizing the same playing of multiple video protocols, reducing the additional numerous player library components integrated by the developer due to different video stream protocols, but also realizing that the application environment of the video terminal does not need to be specially considered, but the template layer is self-adapted, thereby facilitating the rapid application of the developer.

[0053] In step S130, a video playing result is generated according to the target video format and the target video terminal template.

[0054] The video playing result is provided to the user to play the corresponding format of the video in the corresponding video terminal environment.

[0055] By steps S110 to S130, by acquiring the video configuration parameter, determining the target video format corresponding to the video configuration parameter and the target video end template corresponding to the video configuration parameter using the page static resource, the adaptation of different video formats and different video playing ends can be realized based on the basic player, a video playing method compatible with various video stream formats and various playing ends is provided, the phenomenon of high video playing cost caused by the need of installing multiple video playing plug-ins in one browser is avoided, the development cost is reduced, the developer's interfacing cost is directly reduced, the developer's efficiency is effectively improved, the problem of high video playing cost is solved, and a low-cost and efficient video playing method is realized.

[0056] In one embodiment, the video playing method further comprises: the video playing result comprises at least two function function information.

[0057] The preset operation instruction is acquired, the corresponding target function function information in the function function information is triggered according to the operation instruction, and the control information of the video playing result is generated according to the target function function information.

[0058] Specifically, taking an actual operation as an example, a plurality of video end templates are deployed in a template layer, a basic player is used to deploy page static resources to a server, further, the template layer includes a plurality of preset video end templates, the basic player includes a plurality of preset video formats, and the template layer and the basic player are connected through an inline frame element such as iframe. On the one hand, after the basic player obtains an operation instruction input by a user, the operation instruction is converted into a message information defined in advance, the message information is transmitted to the template layer through a channel such as iframe, and a corresponding function function information is triggered, wherein the operation instruction includes playing, pausing, sound off, and the like, and the function function information is deployed in the video end template and is used to implement a function corresponding to the operation instruction. On the other hand, the template layer can expose a related configuration of a playing component to the user, so that the user can listen to a working state of the player component at this time, can flexibly call a function of the player component, can also translate the message information sent by the basic player into a corresponding function function, and expose the function to a developer for use in combination with other businesses. As can be seen, the basic player and the template layer in the application have clear division of labor, wherein the basic layer is used to generate a video playing result according to a video configuration parameter and obtain an operation instruction input by a user, and send the operation instruction to the template layer, and the template layer is used to establish a connection with the basic player, and trigger a corresponding function function information according to the operation instruction, so that the generation of the video playing result and the execution of the operation instruction of the user can be efficiently implemented. Further, the method in the application provides high flexibility for the operation of the user, and the user can input the operation instruction into the basic player, or directly flexibly call a function of the basic player and listen to the basic player in the template layer.

[0059] In one embodiment, a method for video playing is provided, Figure 2 For another flowchart of a video playing method of the application, as shown in the figure, the flow includes the following steps:

[0060] In step S210, an initial address corresponding to the page static resource is obtained; a video configuration parameter is translated into an initial address suffix, a target address is generated according to the initial address and the initial address suffix, and a target video format corresponding to the video configuration parameter is determined from the preset video format according to the target address.

[0061] Specifically, in actual operation, the basic player is deployed in the server for page static resources, after obtaining the initial address corresponding to the basic player at the template layer, the video configuration parameters input by the user are translated into the suffix of the initial address, the initial address and the suffix of the initial address are spliced to obtain the target address, the target address is used to point to the corresponding basic player, further, the basic player obtains the query parameter in the target address, and generates videos of different formats according to the query parameter, and encapsulates the function functions of different video players into the same API function. As can be seen, the function of directly accessing through the target address is provided in the present application, using the method, the user can directly use the provided address to complete the basic video playing requirement, improving the access efficiency of the developer and the user. Moreover, according to the video configuration parameters input by the user, the corresponding target video format can be selected from the pre-set basic player, avoiding the problem that all playing formats cannot be compatible in the prior art.

[0062] In one embodiment, a method for video playing is provided, Figure 3 For another flowchart of the video playing method of the present application, as shown in the figure, the flow includes the following steps:

[0063] In step S220, the page static resource is called according to the target address, and in the case that the calling of the page static resource is detected to be successful, the success callback information generated by the page static resource is obtained; in response to the obtained success callback information, the video end template indication information is obtained; and according to the video end template indication information and the video configuration parameters, the corresponding target video end template is determined from the initial video end template.

[0064] Specifically, after the target address is generated, the template layer creates a channel in the form of an iframe to connect the target address, after the connection is successful, the basic player triggers a success callback and sends a success callback information, after the template layer receives the success callback information, the video end template indication information is obtained, the video end template indication information can be used to indicate the environment type of the current browser and other video playback ends, the playback end environment type corresponds to the target video end template, the template is generated according to the browser environment type and the video configuration parameter, and the corresponding function is added to the control of the template style. Further, the page static resource in the application can be provided to the user in the form of the target address or URL, each user can watch live video on multiple terminal applications such as applets, wechat, APP and web, or provide NPM package, original JS file and other ways to the user, so that the secondary development of adapting the business is carried out. As can be seen, the application uses the target address, that is, the URL parameter to uniformly encapsulate different video formats (h265, h254, etc.) and different video stream formats (HLS, FLV and rtsp, etc.), and provides the same access interface, which improves the efficiency of the developer access and reduces the cost of the developer access.

[0065] In one embodiment, the target video end template includes a default attribute parameter, the video configuration parameter includes a target attribute parameter, and the video playback method further includes:

[0066] Based on the video configuration parameter, an initial video end template corresponding to the video configuration parameter is determined from the initial video end template;

[0067] When it is detected that the default attribute parameter is the same as the target attribute parameter, a template update operation is performed on the initial video end template according to the default attribute parameter, and the target video end template is generated;

[0068] When it is detected that the default attribute parameter is different from the target attribute parameter, a template update operation is performed on the initial video end template according to the target attribute parameter, and the target video end template is generated.

[0069] Specifically, the default attribute parameter and the target attribute parameter are used to indicate the personalized settings of the video playing interface, such as color, button size, etc., wherein the default attribute parameter is a plurality of attributes in the video terminal template, and the target attribute parameter is the personalized parameter setting selected by the user in the video configuration parameter. When the default attribute parameter is the same as the target attribute parameter, the target video terminal template can be generated according to the default attribute parameter; when the default attribute parameter is different from the target attribute parameter, the default attribute parameter can be replaced by the corresponding target attribute parameter, that is, the initial video terminal template is updated according to the target attribute parameter to generate the target video terminal template. In this application, a set of template players can be provided, a basic playing library can be introduced, a set of formed templates can be exposed to the user, the developer can generate a personalized player component style meeting the needs of the developer by using only a few configurations, and a unified interface is provided to the developer, allowing the developer to pull the code for secondary development, greatly reducing the access difficulty and access cost of the developer.

[0070] In one embodiment, the video playing method further comprises:

[0071] obtaining a player function corresponding to at least one player component, encapsulating the player function to generate a player function group;

[0072] calling the player function group according to the video configuration parameter and the target video terminal template, and generating a video playing result according to the target video format by using the player function group.

[0073] Specifically, the basic player includes a plurality of player components, such as HLS player, rtsp player and FLV player, to provide playing function, and the plurality of player functions corresponding to the plurality of player components are encapsulated to obtain the player function group. When the player function corresponding to the video configuration parameter is called in the template layer, the basic player calls the playing function corresponding to the stream format according to the player of the stream format, and generates a video playing result according to the target video format. In this step, for the template layer, it is to call the corresponding playing function in the basic player, which improves the efficiency of function calling and facilitates use.

[0074] The embodiment also provides a specific embodiment of a video playing method, as shown in Figure 4 , which is a structural schematic diagram of the video playing method in a preferred embodiment. Figure 4

[0075] ​First, taking the actual operation as an example, a plurality of video end templates are deployed in the template layer, the basic player is the page static resource deployed to the server, further, the template layer includes a plurality of preset video end templates, the basic player includes a plurality of preset video formats, and the template layer and the basic player are connected through an inline frame element such as iframe. The core function of the playing template layer is that, on the one hand, the url of the basic player, i.e. the target address, is introduced by using iframe, the related configurations of the playing component are exposed to the developer, so that the developer can listen to the state of the player component at this time and can flexibly call the functions of the player component, for example, a preset operation document is provided to the user, and the user can control the player according to the operation document; on the other hand, different theme template style controls are generated according to the user's configuration and the browser, and corresponding function response functions are added to the corresponding controls.

[0076] Secondly, after the template layer obtains the video configuration parameters input by the user, the video configuration parameters are parsed, and the video configuration parameters are translated into an initial address suffix. The initial address suffix is spliced to the initial address of the basic player to obtain a target address corresponding to the video configuration parameters, and a channel in the form of iframe is created to connect the target address. The template layer continuously listens to the state of the basic player, and if the success callback information sent by the basic player is obtained, i.e. the basic player triggers the success callback, the template layer automatically obtains the current browser environment, i.e. the video end template indication information, determines the corresponding target video end template from the initial video end template according to the video end template indication information and the video configuration parameters, and adds corresponding functions to the template style controls; if the connection between the basic player and the template layer fails, the connection failure information will be sent to the port corresponding to the related technical personnel to remind the related technical personnel to handle. After the connection is successful, the basic player obtains the access parameters in the target address, such as the query parameters, determines the corresponding target video format from the preset video format according to the access parameters, and encapsulates the function functions of different video players into the same API function for easy calling. After the basic player obtains the operation instruction input by the user (such as starting, pausing, screenshot, etc.), the operation instruction is converted into preset message information and the message information is transmitted to the template layer, the template layer triggers the corresponding target function function information according to the message information, realizes the operation of the user, and further, the user or the developer can listen to the state of the basic player at this time through the template layer, and can directly and flexibly call the functions of the basic player.

[0077] Finally, the template layer and the base player in the present application are not perceived by external users or external developers when maintenance and upgrade operations are required, i.e., the external users or external developers can directly use the latest base library code without modifying their business code, thereby reducing the code change cost caused by the update and maintenance operations of the developers.

[0078] It should be understood that, although each step in the flowchart involved in each embodiment as described above is shown in sequence according to the arrow, these steps are not necessarily executed in the order indicated by the arrow. Unless otherwise specified herein, the execution of these steps is not strictly limited in sequence, and these steps can be executed in other orders. Moreover, at least part of the steps in the flowchart involved in each embodiment as described above can include multiple steps or stages, which are not necessarily executed at the same time, but can be executed at different times, and the execution order of these steps or stages is not necessarily sequential, but can be alternately or alternately executed with at least part of other steps or steps or stages in other steps.

[0079] Based on the same inventive concept, the present application also provides a video playing device for implementing the above-mentioned designed video playing method. The implementation scheme for solving the problem provided by the device is similar to the implementation scheme described in the above method, so the specific limitations in one or more video playing device embodiments provided below can refer to the limitations of the video playing method in the above text, which will not be repeated here.

[0080] In one embodiment, as shown in Figure 5 A video playing device is provided, comprising: an acquisition module 51, a calculation module 52, and a generation module 53, wherein:

[0081] The acquisition module 51 acquires preset video configuration parameters and at least two initial video terminal templates, and determines page static resources; wherein the page static resources include at least two preset video formats;

[0082] The calculation module 52 determines a target video format corresponding to the video configuration parameters from the preset video formats and a target video terminal template corresponding to the video configuration parameters from the initial video terminal templates based on the video configuration parameters and the page static resources;

[0083] The generation module 53 generates a video playing result according to the target video format and the target video terminal template.

[0084] Specifically, the acquisition module 51 is connected with the calculation module 52, the acquisition module 51 is used for acquiring a preset video configuration parameter, the video configuration parameter is used for indicating a required video stream format and personalized information of a user, and a preset video terminal template includes an H5 terminal template and a web terminal template. If other types of templates are needed, they can be added. Page static resources are applied to the present application in the form of a video player, the video player includes a plurality of preset video formats, such as HLS, FLV, and rtsp. If other types of templates are needed, they can be added and processed. The acquisition module 51 sends the video configuration parameter to the calculation module 52, the calculation module 52 selects a corresponding target video format from a plurality of page static resources, that is, a plurality of video formats of a basic player, according to the video configuration parameter, and determines a target video terminal template corresponding to the video configuration parameter from a preset video terminal template. The calculation module 52 sends the target video format and the target video terminal template to the generation module 53, and the generation module 53 generates a video playing result according to the target video format and the target video terminal template.

[0085] Through the above video playing device, on the one hand, the developer's docking cost can be directly reduced, and the developer's efficiency can be improved, without considering in advance the difference in use in different port environments, and all playing formats and all end playing components can be compatible. On the other hand, the video configuration parameter input by the user can specify the user's demand in multiple aspects, and has higher flexibility. Further, the present scheme provides a plurality of adapted port environments and a plurality of adapted video formats, so that the developer can generate a version conforming to the business through simple configuration, and the access difficulty and access cost of the user or the developer are greatly reduced.

[0086] The above modules can be all or partially realized by software, hardware, and a combination thereof. The above modules can be embedded in or independent of a processor in the computer device in a hardware form, or can be stored in a memory in the computer device in a software form, so as to be called and executed by the processor to perform the operations corresponding to the above modules.

[0087] In one embodiment, a computer device is provided, which can be a terminal, and an internal structure diagram of the computer device can be as shown in FIG. 1. Figure 6As shown in the figure. The computer device includes a processor, a memory, a communication interface, a display screen and an input device connected through a system bus. Among them, the processor of the computer device is used to provide computing and control capabilities. The memory of the computer device includes a non-volatile storage medium, an internal memory. The non-volatile storage medium stores an operating system and a computer program. The internal memory provides an environment for the operating system and the computer program in the non-volatile storage medium to run. The communication interface of the computer device is used to communicate with external terminals in a wired or wireless manner. Wireless mode can be achieved through WIFI, mobile cellular network, NFC (near field communication) or other technologies. The computer program is executed by the processor to implement a video playing method. The display screen of the computer device can be a liquid crystal display screen or an electronic ink display screen. The input device of the computer device can be a touch layer overlaid on the display screen, or a key, trackball or touchpad arranged on the shell of the computer device, or an external keyboard, touchpad or mouse, etc.

[0088] Those skilled in the art can understand that, Figure 6 The skilled in the art can understand that,

[0089] Those skilled in the art should understand that each technical feature of the above-mentioned embodiments can be combined arbitrarily, in order to make the description simple, each technical feature in the above-mentioned embodiments has not been described all possible combinations, however, as long as the combination of these technical features does not exist contradictory, should be considered as the scope of the present application.

[0090] The above-mentioned embodiments only express several implementation manners of the present application, and the description is more specific and detailed, but it should not be understood as a limitation to the scope of the patent. It should be pointed out that for ordinary skilled in the art, without departing from the concept of the present application, a number of variations and improvements can be made, which are all within the scope of the present application. Therefore, the scope of protection of the patent of the present application should be subject to the appended claims.

Claims

1. A video playing method, characterized in that, The method comprises: acquiring preset video configuration parameters and at least two initial video terminal templates deployed on a template layer; determining page static resources; wherein the page static resources are a basic player, the page static resources comprise at least two preset video formats; and the page static resources and the template layer are connected through inline frame elements; based on the video configuration parameters, determining a target video format corresponding to the video configuration parameters from the preset video formats by using the page static resources, and determining a target video terminal template corresponding to the video configuration parameters from the initial video terminal templates; generating a video playing result according to the target video format and the target video terminal template, comprising: acquiring a player function corresponding to at least one player component, encapsulating the player function, and generating a player function group; calling the player function group according to the video configuration parameters and the target video terminal template, and generating a video playing result according to the target video format by using the player function group.

2. The method of claim 1, wherein, The video playing result comprises at least two function function information, and after the video playing result is generated according to the target video format and the target video terminal template, the method further comprises: acquiring a preset operation instruction, triggering corresponding target function function information in the function function information according to the operation instruction, and generating control information of the video playing result according to the target function function information.

3. The method of claim 1, wherein, The method of determining a target video format corresponding to the video configuration parameters from the preset video formats based on the video configuration parameters comprises: acquiring an initial address corresponding to the page static resources; translating the video configuration parameters into an initial address suffix, generating a target address according to the initial address and the initial address suffix, and determining a target video format corresponding to the video configuration parameters from the preset video formats according to the target address.

4. The method of claim 3, wherein, After the target address is generated according to the initial address and the initial address suffix, the method further comprises: calling the page static resources according to the target address, acquiring success callback information generated by the page static resources in a case where the page static resources are detected to be successfully called; acquiring video terminal template indication information in response to the acquired success callback information; determining a corresponding target video terminal template from the initial video terminal templates according to the video terminal template indication information and the video configuration parameters.

5. The method of claim 1, wherein, The target video terminal template comprises default attribute parameters, the video configuration parameters comprise target attribute parameters, and the method further comprises: determining an initial video terminal template corresponding to the video configuration parameters from the initial video terminal templates based on the video configuration parameters; performing a template updating operation on the initial video terminal template according to the default attribute parameters and generating the target video terminal template in a case where the default attribute parameters are detected to be the same as the target attribute parameters; and When it is detected that the default attribute parameter is different from the target attribute parameter, a template updating operation is performed on the initial video terminal template according to the target attribute parameter, and the target video terminal template is generated.

6. A video playback device, comprising: The apparatus comprises: An acquisition module acquires preset video configuration parameters and at least two initial video terminal templates deployed in a template layer; determines page static resources; wherein the page static resources are a basic player, and the page static resources include at least two preset video formats; the page static resources and the template layer are connected through inline frame elements; A calculation module determines a target video format corresponding to the video configuration parameters from the preset video formats and a target video terminal template corresponding to the video configuration parameters from the initial video terminal templates based on the video configuration parameters and the page static resources; A generation module generates a video playing result according to the target video format and the target video terminal template; The generation module is further configured to acquire a player function corresponding to at least one player component, encapsulate the player function to generate a player function group, call the player function group according to the video configuration parameters and the target video terminal template, and generate a video playing result according to the target video format by using the player function group. 7.A computer device, comprising a memory and a processor, wherein the memory stores a computer program, and the computer device is configured to perform the method according to any one of claims 1-6 when the computer program is executed by the processor. The processor executes the computer program to implement the steps of the method in any one of claims 1 to 5.

8. A computer-readable storage medium having stored thereon a computer program, characterized in that, The computer program is executed by the processor to implement the steps of the method in any one of claims 1 to 5.

9. A computer program product comprising a computer program, characterized in that, The computer program is executed by the processor to implement the steps of the method in any one of claims 1 to 5.

Citation Information

Patent Citations

  • Server, static video playing page generation method, device and system

    CN105847870A

  • Parameter processing method and device for webpage rendering

    CN107423340A