CN115086768B - Control method of multi-SDK player - Google Patents

Control method of multi-SDK player Download PDF

Info

Publication number
CN115086768B
CN115086768B CN202210680276.3A CN202210680276A CN115086768B CN 115086768 B CN115086768 B CN 115086768B CN 202210680276 A CN202210680276 A CN 202210680276A CN 115086768 B CN115086768 B CN 115086768B
Authority
CN
China
Prior art keywords
player
sdk
view
playing
play
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN202210680276.3A
Other languages
Chinese (zh)
Other versions
CN115086768A (en
Inventor
李金国
喻雅倩
雷媛媛
韩轶西
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Sichuan Changhong Electric Co Ltd
Original Assignee
Sichuan Changhong Electric Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Sichuan Changhong Electric Co Ltd filed Critical Sichuan Changhong Electric Co Ltd
Priority to CN202210680276.3A priority Critical patent/CN115086768B/en
Publication of CN115086768A publication Critical patent/CN115086768A/en
Application granted granted Critical
Publication of CN115086768B publication Critical patent/CN115086768B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N21/00Selective content distribution, e.g. interactive television or video on demand [VOD]
    • H04N21/40Client devices specifically adapted for the reception of or interaction with content, e.g. set-top-box [STB]; Operations thereof
    • H04N21/43Processing of content or additional data, e.g. demultiplexing additional data from a digital video stream; Elementary client operations, e.g. monitoring of home network or synchronising decoder's clock; Client middleware
    • H04N21/443OS processes, e.g. booting an STB, implementing a Java virtual machine in an STB or power management in an STB
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N21/00Selective content distribution, e.g. interactive television or video on demand [VOD]
    • H04N21/40Client devices specifically adapted for the reception of or interaction with content, e.g. set-top-box [STB]; Operations thereof
    • H04N21/47End-user applications
    • H04N21/485End-user interface for client configuration
    • H04N21/4854End-user interface for client configuration for modifying image parameters, e.g. image brightness, contrast
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N21/00Selective content distribution, e.g. interactive television or video on demand [VOD]
    • H04N21/80Generation or processing of content or additional data by content creator independently of the distribution process; Content per se
    • H04N21/81Monomedia components thereof
    • H04N21/8166Monomedia components thereof involving executable data, e.g. software
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02DCLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
    • Y02D10/00Energy efficient computing, e.g. low power processors, power management or thermal management

Abstract

The invention discloses a control method of a multi-SDK player, which comprises the steps of creating a player proxy view, and uniformly operating and managing the player proxy view by a service layer to ignore the playing view state in the SDK player; a unified play entry function is realized in the player agent view, the stop action of the last SDK player is carried out through the play entry function, and the playing of the next SDK player is started; the invention also discloses a control system of the multi-SDK player, which realizes unified management of the playing views of each SDK and solves the problem that the time sequence of the player possibly occurs when each SDK is switched back and forth.

Description

Control method of multi-SDK player
Technical Field
The invention relates to the technical field of software, in particular to a control method and a control system of a multi-SDK player.
Background
Software development kits (abbreviations: SDKs, foreign language acronyms: software Development Kit) are typically a collection of development tools by some software engineers when building application software for a particular software package, software framework, hardware platform, operating system, etc.
In the Android television, the cooperation with each video content party is often involved, in the playing service, resources of a plurality of video content parties are used and played at the same time, and at the moment, the SDKs of the plurality of video content parties are required to be integrated, so that the purpose of playing a plurality of video contents is achieved. Because of the integration of multiple different SDKs, each SDK needs to be docked separately, and the docking modes of the SDKs are inconsistent, how to integrate and manage the players uniformly is a difficult problem in the industry.
Major problems currently exist including: firstly, part of SDKs provide play view and player functions, and part of SDKs only provide player functions, so that the processing flow of play views is inconsistent in integration, and management is not easy; secondly, when the playing state is switched back and forth among a plurality of different SDKs, serious problems such as incapability of playing and the like are easily caused by improper time sequence management of the player.
Disclosure of Invention
Firstly, the method is to solve the problem of how to complete the unified management of the operation of the playing view and avoid the conflict with the interior of the SDK under the condition that the states of the SDK provided by various families are inconsistent; secondly, the problem that when the playing state is switched back and forth before a plurality of SDKs, the time sequence of the player is normal, playing conflict cannot occur and the like is solved.
In order to achieve the above purpose, the invention adopts the following technical scheme: a control method of a multi-SDK player, comprising:
creating a player agent view, and uniformly operating and managing the player agent view by a service layer, and ignoring the playing view state in the SDK player;
and realizing a unified play entry function in the player agent view, and performing stop action of the last SDK player and starting playing of the next SDK player through the play entry function.
As a further improvement of the present invention, for an SDK player that provides a play view, the play view provided by the SDK player is added to a player agent view for management; for an SDK player that does not provide a play view, a play view is created in the player proxy view and added to the player proxy view.
As a further improvement of the present invention, there is also included:
and creating an independent playing thread in the player agent view, and sending all player action instructions to the playing thread for execution, so that all SDK players are ensured to be executed in the playing thread, and the management of playing time sequence is realized.
As a further development of the invention, the playback thread is realized by a HandlerThread or a single-thread pool.
As a further improvement of the invention, the player agent view is ViewGroup and its subclasses in the Android system.
The invention also provides a control system of the multi-SDK player, which is used for realizing the control method of the multi-SDK player, and the control system comprises the following steps:
a player agent view, wherein the player agent view is used for the business layer to perform unified operation management on the player agent view, and ignoring the playing view state in the SDK player; and the playing entry function is used for realizing the unified playing entry function, stopping the last SDK player and starting playing of the next SDK player.
The beneficial effects of the invention are as follows:
the invention can ensure that a developer performs unified management on the play views of all SDKs, and reduces the manpower input in the play view connection when the SDKs are newly accessed; meanwhile, the problem that a player fails due to the time sequence of the player after a developer newly accesses the SDK can be avoided. .
Drawings
Fig. 1 is a flowchart showing the implementation of embodiment 2 of the present invention.
Detailed Description
Embodiments of the present invention will be described in detail below with reference to the accompanying drawings.
Example 1
A control method of a multi-SDK player, comprising the steps of:
and step A, when the SDK is accessed, as part of the SDK provides play view and player functions, part of the SDK only provides player functions, and in order to ensure the requirement of uniform processing on the play view in the service, the play view needs to be uniformly managed. In this embodiment, by creating the player proxy view, the service layer performs unified operation management on the player proxy view, and ignores the play view state in the SDK. For the SDK for providing the playing view, adding the playing view provided by the SDK into the player agent view for management; for SDKs that do not provide a play view, a play view is created in the proxy view and added to the player proxy view. The unified operation management of the proxy view is adopted, so that the unified management of the playing view is achieved.
And B, when the service needs to be switched back and forth among a plurality of SDKs, the player states of all the SDKs are independently managed, so that the problem of player state conflict is easy to occur, and further the problem of playing failure and the like is caused. In this embodiment, based on the player agent view created in step a, a unified play entry function is implemented in the player agent view, through which the stop action of the last SDK player is performed and the playing of the next SDK player is started. Meanwhile, a single playing thread is created in the player agent view, all player action instructions are sent to the playing thread to be executed, all SDKs are guaranteed to be executed in the playing thread, and therefore management of playing time sequence is achieved.
Example 2
As shown in fig. 1, a control method of a multi-SDK player includes:
1. the player agent view creation and management specifically comprises the following steps:
step A, a player agent view is ViewGroup and subclasses thereof in an Android system, in the implementation, taking a FrameLayout as an example, and creating a custom subclass of the FrameLayout as a player agent view class;
step B, before playing the SDK, acquiring a playing view through an interface provided by the SDK, and if the playing view cannot be acquired, creating a playing view for the SDK; and adding the obtained play view into the player agent view through an addView method, so as to display a play picture.
And C, when the SDK playing is switched, if the playing view of the last SDK exists in the player agent view, firstly removing the playing view of the last SDK from the player agent view through a removeView method, and then carrying out the playing view adding flow in the step B.
2. Switching SDK playing time sequence management specifically comprises the following steps:
and step A, when the player agent view frame timeout is initialized, a playing thread PlayerThread is simultaneously created and started, the playing thread is single-threaded and globally unique, and the playing thread is realized by HandlerThread, but the method is not limited to the method.
And B, in the player agent view, a unified play start entry function is realized, all play instructions are sent through the entry function, the entry function can send the play instructions to a play thread, all play related operations are realized to run in the play thread, and the normal time sequence of the player is ensured.
Example 3
A control system for a multiple SDK player for implementing the control method for the multiple SDK player of embodiment 1 or embodiment 2, the control system comprising:
a player agent view, wherein the player agent view is used for the business layer to perform unified operation management on the player agent view, and ignoring the playing view state in the SDK player; and the playing entry function is used for realizing the unified playing entry function, stopping the last SDK player and starting playing of the next SDK player.
The foregoing examples merely illustrate specific embodiments of the invention, which are described in greater detail and are not to be construed as limiting the scope of the invention. It should be noted that it will be apparent to those skilled in the art that several variations and modifications can be made without departing from the spirit of the invention, which are all within the scope of the invention.

Claims (3)

1. A method for controlling a multi-SDK player, comprising:
creating a player agent view, and uniformly operating and managing the player agent view by a service layer, and ignoring the playing view state in the SDK player; for an SDK player providing a play view, adding the play view provided by the SDK player into a player agent view for management; for an SDK player which does not provide a play view, creating a play view in a player agent view and adding the play view to the player agent view;
a unified play entry function is realized in the player agent view, the stop action of the last SDK player is carried out through the play entry function, and the playing of the next SDK player is started; and creating an independent playing thread in the player agent view, and sending all player action instructions to the playing thread for execution, so that all SDK players are ensured to be executed in the playing thread, and the management of playing time sequence is realized.
2. The method of claim 1, wherein the playback thread is implemented by a HandlerThread or a single-threaded pool.
3. The method for controlling an SDK player according to claim 1 or 2, wherein the player agent view is a viewsroup and its subclass in an Android system.
CN202210680276.3A 2022-06-16 2022-06-16 Control method of multi-SDK player Active CN115086768B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202210680276.3A CN115086768B (en) 2022-06-16 2022-06-16 Control method of multi-SDK player

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202210680276.3A CN115086768B (en) 2022-06-16 2022-06-16 Control method of multi-SDK player

Publications (2)

Publication Number Publication Date
CN115086768A CN115086768A (en) 2022-09-20
CN115086768B true CN115086768B (en) 2023-07-25

Family

ID=83254605

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202210680276.3A Active CN115086768B (en) 2022-06-16 2022-06-16 Control method of multi-SDK player

Country Status (1)

Country Link
CN (1) CN115086768B (en)

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102306103A (en) * 2011-08-25 2012-01-04 华南理工大学 Software development kit (SDK) module for Android real time streaming protocol (RTSP) player
CN106775720A (en) * 2016-12-16 2017-05-31 北京小度互娱科技有限公司 The method and apparatus of integrated player SDK and the method and apparatus that player SDK is set
CN109743632A (en) * 2018-12-18 2019-05-10 苏宁易购集团股份有限公司 A method of realizing the multi engine access of media play under the more ecosystems of Android
CN111158629A (en) * 2019-12-24 2020-05-15 苏宁智能终端有限公司 Method and system for seamlessly switching media asset players

Family Cites Families (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107077872A (en) * 2015-03-30 2017-08-18 联发科技(新加坡)私人有限公司 Android carries the method for developing functions and multimedia play system of multimedia player
CN109600652B (en) * 2017-09-30 2022-03-29 中兴通讯股份有限公司 Method for playing multi-channel video by mobile terminal, mobile terminal and readable storage medium

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102306103A (en) * 2011-08-25 2012-01-04 华南理工大学 Software development kit (SDK) module for Android real time streaming protocol (RTSP) player
CN106775720A (en) * 2016-12-16 2017-05-31 北京小度互娱科技有限公司 The method and apparatus of integrated player SDK and the method and apparatus that player SDK is set
CN109743632A (en) * 2018-12-18 2019-05-10 苏宁易购集团股份有限公司 A method of realizing the multi engine access of media play under the more ecosystems of Android
CN111158629A (en) * 2019-12-24 2020-05-15 苏宁智能终端有限公司 Method and system for seamlessly switching media asset players

Also Published As

Publication number Publication date
CN115086768A (en) 2022-09-20

Similar Documents

Publication Publication Date Title
RU2501176C2 (en) Media processor for organising multimedia data
US8606950B2 (en) System and method for transparently processing multimedia data
EP1194840B1 (en) Digital television receiver for managing execution of an application according to an application lifecycle
US20050262254A1 (en) Dynamic redirection of streaming media between computing devices
US8776051B2 (en) Method of providing partially isolated execution environment for multiple applications and digital information apparatus using the same
CN103777999A (en) Android software simulation method and device
WO2022134358A1 (en) Microservice data processing method, apparatus, microservice processing platform, and medium
TWI597662B (en) Storage medium in television system and method for managing applications therein
WO2019071678A1 (en) Live broadcasting method and device
CN102196308B (en) Digital-television-based multi-hardware interface compatible driving system
WO2022095858A1 (en) Data transmission method, and device and medium
CN115086768B (en) Control method of multi-SDK player
WO2018209869A1 (en) Information sharing method and device during miracast, and storage medium
CN102375759B (en) Utilize the method that finite state machine prevents code rewriting
JPH1173334A (en) Data processing method, recording medium and data processor
WO2022152041A1 (en) Video livestreaming functional component loading method, data processing method, and device
CN104066011A (en) Control method of interface switching of intelligent TV and control device thereof
CN109672745A (en) The online control method for playing back of audio and device for FreeRTOS
WO2018103372A1 (en) Driver management method and host machine
KR101166936B1 (en) Method for sharing a graphics display as a resource in an embedded system
CN111131741A (en) Multi-party video call method, system, device and computer readable storage medium
US20130332928A1 (en) Information processing system, information processing method, and computer-readable medium
CN114860131A (en) Control method, device, equipment, medium and product for vehicle-mounted multimedia application
US7716669B2 (en) Concurrent system applications in a multimedia console
CN112306564B (en) Method for realizing intelligent interaction large screen quick start

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant