CN107613369A - Video broadcasting method, device and electronic equipment based on GStreamer frameworks - Google Patents

Video broadcasting method, device and electronic equipment based on GStreamer frameworks Download PDF

Info

Publication number
CN107613369A
CN107613369A CN201710934925.7A CN201710934925A CN107613369A CN 107613369 A CN107613369 A CN 107613369A CN 201710934925 A CN201710934925 A CN 201710934925A CN 107613369 A CN107613369 A CN 107613369A
Authority
CN
China
Prior art keywords
data
caching
pointer
decoder object
unit
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.)
Granted
Application number
CN201710934925.7A
Other languages
Chinese (zh)
Other versions
CN107613369B (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.)
Qingdao Hisense Electronics Co Ltd
Original Assignee
Qingdao Hisense Electronics 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 Qingdao Hisense Electronics Co Ltd filed Critical Qingdao Hisense Electronics Co Ltd
Priority to CN201710934925.7A priority Critical patent/CN107613369B/en
Publication of CN107613369A publication Critical patent/CN107613369A/en
Application granted granted Critical
Publication of CN107613369B publication Critical patent/CN107613369B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Landscapes

  • Compression Or Coding Systems Of Tv Signals (AREA)
  • Two-Way Televisions, Distribution Of Moving Picture Or The Like (AREA)

Abstract

This disclosure relates to a kind of video broadcasting method based on GStreamer frameworks, device and electronic equipment.Wherein, methods described includes:By specifying caching to obtain video data;Call decoder plug-in unit to be decoded to obtain decoding data to the video data, and the decoding data is stored to the output set to the decoder plug-in unit and cached;Player plug-in unit is obtained by the media decoder object of the specified caching push, and calling the display interface encapsulated in the media decoder object to carry out video playback to the decoding data in the output caching, the media decoder object creates for structure video playback application program.The video broadcasting method based on GStreamer frameworks, device and the electronic equipment provided using the disclosure can effectively improve Video processing efficiency, and then lift video playback performance.

Description

Video broadcasting method, device and electronic equipment based on GStreamer frameworks
Technical field
This disclosure relates to technical field of video processing, more particularly to a kind of video playback side based on GStreamer frameworks Method, device and electronic equipment.
Background technology
GStreamer frameworks are a kind of multimedia frameworks increased income, and have good professional platform independence, can easily move Various operating systems (such as Android system, linux system) are planted, and are widely used in the structure of video playback application program In building.
At present, the flow for the GStreamer frameworks that video playback application builds are followed is:By GStreamer frames The GstBuffer that frame is specified carries out data transfer between all types of plug-in units (such as decoder plug-in unit, player plug-in unit).
Specifically, as shown in figure 1, obtaining video data by GstBuffer, video data is then copied to decoder Input-buffer set by plug-in unit, video data is decoded with this to obtain decoding data, and stored to decoder plug-in unit institute The output caching of setting, finally returns GstBuffer, and then decoding data is passed through by decoding data by output cached copies again GstBuffer pushes (push) to player plug-in unit (VideoSink) progress video playback.
From the foregoing, it will be observed that copy procedure, especially second of copy procedure twice in video playback application builds be present, Because decoding data is yuv format, generally there is huger data volume, if each frame decoding data are required for by exporting Cached copies return GstBuffer, not only reduce the efficiency of Video processing, and also create the interim card of video playback, seriously Influence video playback performance.
Therefore, also there is the inefficient limitation of Video processing in existing video playback.
The content of the invention
In order to solve the above-mentioned technical problem, a purpose of the disclosure is to provide a kind of based on GStreamer frameworks Video broadcasting method, device and electronic equipment.
Wherein, technical scheme is used by the disclosure:
A kind of video broadcasting method based on GStreamer frameworks, including:By specifying caching to obtain video data;Call Decoder plug-in unit is decoded to obtain decoding data to the video data, and the decoding data is stored to the decoder The output caching that plug-in unit is set;Player plug-in unit is obtained by the media decoder object of the specified caching push, and described in calling The display interface encapsulated in media decoder object carries out video playback, the media solution to the decoding data in the output caching Code object creates for structure video playback application program.
A kind of video play device based on GStreamer frameworks, including:Data acquisition module, for by specifying caching Obtain video data;Data decoder module, for calling decoder plug-in unit to be decoded to obtain solution yardage to the video data According to, and the decoding data is stored to the output set to the decoder plug-in unit and cached;Data playback module, for player Plug-in unit is obtained by the media decoder object of the specified caching push, and calls the display encapsulated in the media decoder object to connect Mouth carries out video playback to the decoding data in the output caching, and the media decoder object is to build video playback application Program and create.
A kind of electronic equipment, including:Processor and memory, computer-readable instruction are stored with the memory, institute Computer-readable instruction is stated by video playback side of the realization as described above based on GStreamer frameworks during the computing device Method.
Compared with prior art, the disclosure has the advantages that:
By being decoded to obtain decoding data to the video data got in specified caching, and decoding data is stored To the output caching set by decoder plug-in unit, and then the display interface encapsulated in media decoder object is called by player plug-in unit Decoding data in being cached to output carries out video playback.Wherein, media decoder object is to build video playback application program And create, and by specifying caching to push to player plug-in unit.
Thus, by specifying caching to carry out the push of media decoder object so that the structure of video playback application program Still the flow of GStreamer frameworks is followed, meanwhile, can be directly to defeated by the display interface encapsulated in media decoder object The decoding data gone out in caching carries out video playback, is avoided with this and refers to determine caching by output cached copies by decoding data, And then the efficiency of Video processing is improved, the fluency of video playback is ensure that, is advantageous to improve the performance of video playback, solves The problem of Video processing present in prior art is inefficient.
It should be appreciated that the general description and following detailed description of the above are only exemplary and explanatory, not The disclosure can be limited.
Brief description of the drawings
Accompanying drawing herein is merged in specification and forms the part of this specification, shows the implementation for meeting the disclosure Example, and be used in specification to explain the principle of the disclosure together.
Fig. 1 is a kind of flow chart of the video broadcasting method based on GStreamer frameworks in the prior art.
Fig. 2 is the hardware block diagram of a kind of electronic equipment according to an exemplary embodiment.
Fig. 3 is a kind of stream of video broadcasting method based on GStreamer frameworks according to an exemplary embodiment Cheng Tu.
Fig. 4 is another video broadcasting method based on GStreamer frameworks according to an exemplary embodiment Flow chart.
Fig. 5 is that Fig. 3 corresponds in embodiment step 250 in the flow chart of one embodiment.
Fig. 6 is that Fig. 3 corresponds in embodiment step 250 in the flow chart of another embodiment.
Fig. 7 is a kind of specific implementation schematic diagram of the video broadcasting method based on GStreamer frameworks in an application scenarios.
Fig. 8 is a kind of frame of video play device based on GStreamer frameworks according to an exemplary embodiment Figure.
Fig. 9 is another video play device based on GStreamer frameworks according to an exemplary embodiment Block diagram.
Figure 10 is that Fig. 8 corresponds in embodiment data playback module 750 in the block diagram of one embodiment.
Figure 11 is that Fig. 8 corresponds in embodiment data playback module 750 in the block diagram of another embodiment.
Pass through above-mentioned accompanying drawing, it has been shown that the clear and definite embodiment of the disclosure, will hereinafter be described in more detail, these accompanying drawings It is not intended to limit the scope of disclosure design by any mode with word description, but is by reference to specific embodiment Those skilled in the art illustrate the concept of the disclosure.
Embodiment
Here explanation will be performed to exemplary embodiment in detail, its example is illustrated in the accompanying drawings.Following description is related to During accompanying drawing, unless otherwise indicated, the same numbers in different accompanying drawings represent same or analogous key element.Following exemplary embodiment Described in embodiment do not represent all embodiments consistent with the disclosure.On the contrary, they be only with it is such as appended The example of the consistent apparatus and method of some aspects be described in detail in claims, the disclosure.
At present, in the structure of video playback application program, the amc plug-in units that are widely used that in GStreamer frameworks With gst-omx plug-in units.
Wherein, amc plug-in units are the GstVideoDecoder base class for inheriting GStreamer frameworks, and Android system is connected with this MediaCodec interfaces, and then realize the decoding and display of video data.
The advantages of amc plug-in units, can be achieved on the perfect adaptation of GStreamer frameworks and Android system, and shortcoming is to abide by The flow of GStreamer frameworks is followed, it is necessary to which the decoding data that decoding is obtained is copied to after video data decoding In the GstBuffer that GStreamer frameworks are specified, carried out so that decoding data is pushed into player plug-in unit by GstBuffer Video playback.
Because decoding data is yuv format, generally there is huger data volume, if each frame decoding data all need GstBuffer is returned by output cached copies, not only reduce the efficiency of Video processing, and also create the card of video playback , the performance of influence video playback seriously.
Similarly, gst-omx plug-in units also have the shortcomings that similar, in addition, the complexity of gst-omx plug-in units is higher, exploit person Member needs to spend longer time to go to grasp, and is also unfavorable for reducing R&D costs.
Therefore, current video broadcasting method goes to realize video playback application journey also by customized HAL layer interfaces Sequence structure, but this method is poor compared with the versatility of GStreamer frameworks, has had a strong impact on the expansible of video broadcasting method Property and professional platform independence.
Based on this, the video broadcasting method in the prior art based on GStreamer frameworks still suffer from Video processing efficiency compared with The defects of low, therefore, disclosure spy proposes a kind of video based on GStreamer frameworks that can improve Video processing efficiency Player method, video broadcasting method of this kind based on GStreamer frameworks are applied to electronic equipment.
Referring to Fig. 2, Fig. 2 is the hardware block diagram of a kind of electronic equipment according to an exemplary embodiment.Electricity Sub- equipment can be smart mobile phone, desktop computer, notebook computer, tablet personal computer or be available for video playback application program to run Other electronic equipments, be not defined herein.
It should be noted that the electronic equipment 100 is an example for adapting to the disclosure, it is impossible to thinks there is provided To any restrictions of the use range of the disclosure.The electronic equipment 100 can not be construed to need to rely on or must have One or more component in the exemplary electronic equipment 100 shown in Fig. 2.
(only show in figure as shown in Fig. 2 electronic equipment 100 includes memory 101, storage control 103, one or more Go out one) processor 105, Peripheral Interface 107, radio-frequency module 109, locating module 111, photographing module 113, audio-frequency module 115, Touch Screen 117 and key-press module 119.These components are mutually communicated by one or more communication bus/signal wire 121.
Wherein, memory 101 can be used for storage software program and module, as in disclosure exemplary embodiment based on Programmed instruction and module corresponding to the video broadcasting method and device of GStreamer frameworks, processor 105 are stored in by operation Programmed instruction in memory 101, so as to perform various functions and data processing, that is, realize and above-mentioned be based on GStreamer frames The video broadcasting method of frame.
The carrier that memory 101 stores as resource, can be random storage medium, such as high speed random access memory, non- Volatile memory, such as one or more magnetic storage devices, flash memory or other solid-state memories.Storage mode can be Of short duration storage permanently stores.
Peripheral Interface 107 can include an at least wired or wireless network interface, an at least connection in series-parallel translation interface, at least One input/output interface and at least USB interface etc., for outside various input/output devices to be coupled into memory 101 and processor 105, to realize the communication with outside various input/output devices.
Radio-frequency module 109 is used for transceiving electromagnetic ripple, the mutual conversion of electromagnetic wave and electric signal is realized, so as to pass through communication network Network is communicated with other equipment.Communication network includes cellular telephone networks, WLAN or Metropolitan Area Network (MAN), above-mentioned communication network Network can use various communication standards, agreement and technology.
Locating module 111 is used for the geographical position being currently located for obtaining electronic equipment 100.The example of locating module 111 Including but not limited to GPS (GPS), the location technology based on WLAN or mobile radio communication.
Photographing module 113 is under the jurisdiction of camera, for shooting picture or video.The picture or video of shooting can be deposited In storage to memory 101, it can also be sent by radio-frequency module 109 to host computer.
Audio-frequency module 115 provides a user COBBAIF, and it may include one or more microphone interfaces, one or more Speaker interface and one or more earphone interfaces.Interacting for voice data is carried out with miscellaneous equipment by COBBAIF.Sound Frequency can also be sent according to that can store to memory 101 by radio-frequency module 109.
Touch Screen 117 provides an I/O Interface between electronic equipment 100 and user.Specifically, Yong Huke Input operation, such as the gesture operation such as click, touch, slip are carried out by Touch Screen 117, so that electronic equipment 100 is to this Input operation is responded.Then by word, picture, either any one form of video or combination are formed electronic equipment 100 Content is exported by Touch Screen 117 to user's display output.
Key-press module 119 includes at least one button, to provide the interface that user is inputted to electronic equipment 100, User can make electronic equipment 100 perform different functions by pressing different buttons.For example, sound regulating key is available for using Realize the regulation of the wave volume played to electronic equipment 100 in family.
It is appreciated that structure shown in Fig. 2 is only to illustrate, electronic equipment 100 may also include than shown in Fig. 2 more or more Few component, or there is the component different from shown in Fig. 2.
In addition, also can equally realize the disclosure by hardware circuit or hardware circuit combination software instruction, therefore, realize The disclosure is not limited to any specific hardware circuit, software and both combinations.
Referring to Fig. 3, in one exemplary embodiment, a kind of video broadcasting method based on GStreamer frameworks is applicable In electronic equipment, the electronic equipment is applied to hardware configuration illustrated in fig. 2.
Video broadcasting method of this kind based on GStreamer frameworks can be performed by electronic equipment, can include following step Suddenly:
Step 210, by specifying caching to obtain video data.
Specified caching refers to the GstBuffer specified by GStreamer frameworks, and all types of plug-in units are buffered in by specifying Data transfer is carried out between (such as decoder plug-in unit, player plug-in unit), so as to ensure based on constructed by GStreamer frameworks Various multimedia applications (such as video playback application program) can follow the flow of GStreamer frameworks.
The video data stored in caching is specified to derive from the front end hardware equipment set by electronic equipment, for example, Front end hardware equipment is camera;Can also derive from electronic equipment set by local cache, for example, local cache include with Machine memory, read-only storage, hard disk, disk, flash memory etc., are not limited herein.
Specifically, the video data that receiving front-end hardware device collects, or, video counts are extracted by local cache According to, and video data is stored to specified caching.
Stored in video data to specified caching, just can be by specifying when needing to decode video data Video data to be decoded is obtained in caching.
Step 230, call decoder plug-in unit to be decoded to obtain decoding data to video data, and decoding data is stored The output caching set to decoder plug-in unit.
Specifically, for the video data by specifying caching to get, first, video data is copied to decoder plug-in unit The input-buffer of setting, then the video data in input-buffer is decoded to obtain decoding data, and then decoding data is deposited The output caching set to decoder plug-in unit is stored up, to wait the decoding data in subsequently being cached to output to carry out video playback.
It is noted that compared to prior art, different, decoding data is being stored to output caching Afterwards, it can't be copied and refer to determine caching.That is, transmitted by specifying to be buffered between decoder plug-in unit and player plug-in unit Data will no longer be decoding data.
Step 250, player plug-in unit is obtained by specifying the media decoder object of caching push, and calls media decoder object Decoding data during the display interface of middle encapsulation caches to output carries out video playback.
In order to avoid decoding data is copied back into specified caching, decoder plug-in unit is buffered in playing as it was previously stated, specifying The data transmitted between device plug-in unit will no longer be decoding data, that is to say, that be inserted by specifying caching to push to player Part is no longer decoding data.
Thus, in order to follow the flow of GStreamer frameworks, in the present embodiment, by specifying caching to push to player Plug-in unit is media decoder object.Wherein, media decoder object creates for structure video playback application program.
In the establishment of media decoder object, display interface will be packaged into media decoder object.The display interface by with In to decoding data progress video playback.For example, the display interface can be Android system standard application program interface (such as MediaCodec interfaces), or, the display interface is the application programming interfaces of the self-defined generation of linux system.
It should be noted that when the standard application program interface of Android system is packaged into media decoder object, it is GStreamer frameworks are combined with Android system, and then are advantageous to build video playback application program in Android system. Similarly, when the application programming interfaces of the self-defined generation of linux system are packaged into media decoder object, be by GStreamer frameworks combine with linux system, and then are advantageous to build video playback application program in linux system.
Based on process as described above, by specifying caching to carry out the push of media decoder object to substitute decoding data to push away Sending so that the structure of video playback application program still follows the flow of GStreamer frameworks, meanwhile, pass through media decoding pair Decoding data in directly being cached as the display interface of middle encapsulation to output carries out video playback, it is entirely avoided copy solution Code data and then improve the efficiency of Video processing, have fully ensured that the fluency of video playback to the possibility of specified caching, Be advantageous to improve the performance of video playback.
Referring to Fig. 4, in one exemplary embodiment, before step 250, method as described above can also include following Step:
Step 310, media decoder object is defined for structure video playback application program.
Step 330, a structure is constructed according to the pointer of the pointer of media decoder object and output caching, and by structure By specifying caching to push to player plug-in unit.
Illustrate first, the pointer of media decoder object is used to indicate media decoder object, i.e. is decoded by media The pointer of object is just able to access that media decoder object and its display interface.
Secondly, the pointer for exporting caching points to the decoding data being stored in output caching, i.e. by the finger for exporting caching Pin is just able to access that the decoding data in output caching.
Because decoding data can't be by specifying caching to be pushed to player plug-in unit so that player plug-in unit can not Video playback directly is carried out to decoding data, for this reason, it may be necessary to be changed to the processing mode of player plug-in unit, i.e., adjusted with interface Mode is gone to show and discharges the decoding data in output caching.
Based on this, before the decoding data in being shown and discharging output caching, player plug-in unit is firstly the need of obtaining Know how calling interface and how to access output caching in decoding data.
Specifically, a media decoder object is defined for structure video playback application program first, and then is decoded by media The pointer of object and the pointer of output caching carry out structure construction, then are inserted by specifying caching that structure is pushed into player Part, sealed in order to which follow-up play device plug-in unit can be realized in media decoder object by the pointer of media decoder object in structure The calling of the display interface of dress, and the decoding data exported in caching can be read by exporting the pointer of caching in structure.
It should be noted that because decoding data is not by output cached copies to specified caching, then decoding data can not Release, therefore, in the present embodiment, the decoding data finished by way of interface interchange to display discharges.
Referring to Fig. 5, in one exemplary embodiment, step 250 may comprise steps of:
Step 251, the pointer of media decoder object and the pointer of output caching are extracted by structure.
As it was previously stated, when creating media decoder object for structure video playback application program, structure is according to media solution The pointer of code object and the pointer construction of output caching, and by specifying caching to push to player plug-in unit.
Therefore, for player plug-in unit, after specified caching has carried out structure push, this can just be got Structure, and the pointer for extracting to obtain the pointer of media decoder object and output caches by the structure.
Step 253, the display interface encapsulated in media decoder object is called by the pointer of media decoder object, and passed through The pointer of output caching reads the decoding data in output caching.
After the pointer of media decoder object is obtained, just media can be accessed by the pointer of media decoder object and decoded Object and its display interface, i.e. call the display interface encapsulated in media decoder object.
Correspondingly, after the pointer of output caching is obtained, just output caching can be accessed by exporting the pointer of caching In decoding data, i.e. with output buffer pointers movement, one by one read output caching in decoding data.
Step 255, decoding data is carried out by display interface to show.
After display interface and decoding data is determined, the mode that player plug-in unit will pass through display interface calling is realized The display of decoding data, and data to be decoded show and finish release decoding data.
Based on above-mentioned process, player plug-in unit is not really to have handled decoding data, but calls display interface to go Show and discharge decoding data, with this avoid by decoding data by output cached copies refer to fixed caching and by specify cache into Row push, so as to improve the efficiency of Video processing, ensure that the fluency of video playback, be advantageous to improve the property of video playback Energy.
In one exemplary embodiment, before step 250, method as described above can also comprise the following steps:
The captions structure pointer of caption data is pointed in extension one in structure.
First, captions structure pointer points to caption data, i.e. is just able to access that captions number by captions structure pointer According to.
Secondly, structure extension refers to the pointer of the pointer that media decoder object is with the addition of in structure and output caching On the basis of, then add captions structure pointer.
Correspondingly, referring to Fig. 6, step 250 can also comprise the following steps:
Step 252, captions structure pointer is extracted by structure, and caption data is obtained by captions structure pointer.
As it was previously stated, when creating media decoder object for structure video playback application program, captions are extended in structure Structure pointer, and the structure is by specifying caching to push to player plug-in unit.
Therefore, for player plug-in unit, after specified caching has carried out structure push, this can just be got Structure, and extracted by the structure to obtain captions structure pointer.
Because letter configuration body pointer is directed to caption data, after captions structure pointer is obtained, just can lead to Cross captions structure pointer and access caption data, i.e. the movement of follow-up captions structure pointer, obtain caption data one by one.
Wherein, caption data can be stored in local cache, for example, local cache includes but is not limited to:Random storage Device, read-only storage, hard disk, disk, flash memory etc..
Step 254, when carrying out video playback to decoding data, enter according to the Subtitle Demonstration mode indicated in title plug-ins Row caption data is shown.
Title plug-ins, it is used to indicate whether to show captions, Subtitle Demonstration mode etc..
After caption data is obtained, player plug-in unit just can together show caption data with decoding data.
Specifically, judge whether to show captions by title plug-ins first, when it is determined that during without Subtitle Demonstration, then only Carry out the display of decoding data.Now, caption data is dropped.
Subtitle Demonstration mode is determined when it is determined that carrying out Subtitle Demonstration, then by title plug-ins, and according to Subtitle Demonstration side Formula carries out the display of decoding data and caption data, i.e. when carrying out video playback to decoding data, caption data is included In video playback interface.
Fig. 7 is a kind of specific implementation schematic diagram of the video broadcasting method based on GStreamer frameworks in an application scenarios.
In the application scenarios, by performing step 401, call decoder plug-in unit to decode video data and solved Code data, and decoding data is stored to the output set to decoder plug-in unit and cached.
By performing step 402, a structure is constructed according to the pointer of the pointer of media decoder object and output caching, and Structure is copied to specified caching, to be tied subsequently through specified be buffered between decoder plug-in unit and player plug-in unit The transmission of structure body.Wherein, media decoder object creates for structure video playback application program, can be used for wherein being packaged with The display interface of video playback is carried out to decoding data.
By performing step 403, specify the structure in caching to be pushed to player plug-in unit, decoding data is substituted with this By specifying caching to push, decoding data had both been avoided by output cached copies to specified caching, while also assures that GStreamer Framework flow is followed.
By performing step 404, player plug-in unit is therefrom extracted by specifying the push of caching to get structure To the pointer of media decoder object and the pointer of output caching.
By performing step 405, the display encapsulated in media decoder object is called to connect by the pointer of media decoder object Mouth goes the pointer decoding data that is accessed of the display by output caching, and the aobvious of image frame in video playback interface is realized with this Show.
Thus, avoid decoding data and to be referred to determine caching by output cached copies, and then improve the effect of Video processing Rate, the fluency of video playback is ensure that, be advantageous to improve the performance of video playback.
Following be embodiment of the present disclosure, can be used for performing involved by the disclosure based on GStreamer frameworks Video broadcasting method.For the details not disclosed in embodiment of the present disclosure, refer to involved by the disclosure based on The video broadcasting method embodiment of GStreamer frameworks.
Referring to Fig. 8, in one exemplary embodiment, a kind of video play device 700 based on GStreamer frameworks should For electronic equipment, include but is not limited to:Data acquisition module 710, data decoder module 730 and data playing module 750.
Wherein, data acquisition module 710 is used for by specifying caching to obtain video data.
Data decoder module 730 is used to call decoder plug-in unit to be decoded to obtain decoding data to video data, and will Decoding data stores the output caching set to decoder plug-in unit.
Data playback module 750 is used for player plug-in unit and obtained by specifying the media decoder object of caching push, and calls Decoding data during the display interface encapsulated in media decoder object caches to output carries out video playback, and media decoder object is Build video playback application program and create.
Referring to Fig. 9, in one exemplary embodiment, device 700 as described above also includes but is not limited to:Object definition Module 810 and structure constructing module 830.
Wherein, object definition module 810 is used to define media decoder object for structure video playback application program.
Structure constructing module 830 is used to construct a structure according to the pointer of media decoder object and the pointer of output caching Body, and by structure by specifying caching to push to player plug-in unit.
Referring to Fig. 10, in one exemplary embodiment, data playback module 750 includes but is not limited to:Pointer extracting list Member 751, pointer applying unit 753 and data display unit 755.
Wherein, pointer extracting unit 751 is in the pointer that media decoder object is extracted by structure and the pointer of output caching.
Pointer applying unit 753 is used to call the display encapsulated in media decoder object by the pointer of media decoder object Interface, and the pointer by exporting caching reads the decoding data exported in caching.
Data display unit 755 is used to be shown by display interface progress decoding data.
In one exemplary embodiment, device 700 as described above also includes but is not limited to:Structure expansion module.
Wherein, structure expansion module is used for the captions structure pointer that caption data is pointed in the extension one in structure.
Correspondingly, Figure 11 is referred to, data playback module 750 also includes but is not limited to:Captions acquiring unit 752 and captions Display unit 754.
Wherein, captions acquiring unit 752 is used to extract captions structure pointer by structure, and is referred to by captions structure Pin obtains caption data.
Subtitle Demonstration unit 754 is used for when carrying out video playback to decoding data, according to the word indicated in title plug-ins Curtain display mode carries out caption data and shown.
It should be noted that the video play device based on GStreamer frameworks that above-described embodiment is provided is being carried out When video playback based on GStreamer frameworks is handled, only carried out with the division of above-mentioned each functional module for example, actual should In, it can be completed as needed and by above-mentioned function distribution by different functional modules, i.e. regarding based on GStreamer frameworks The internal structure of frequency playing device will be divided into different functional modules, to complete all or part of function described above.
In addition, the video play device based on GStreamer frameworks that above-described embodiment is provided is with being based on GStreamer The embodiment of the video broadcasting method of framework belongs to same design, and wherein modules perform the concrete mode of operation in side It is described in detail in method embodiment, here is omitted.
In one exemplary embodiment, a kind of electronic equipment, including but not limited to processor and memory.
Wherein, computer-readable instruction is stored with memory, the computer-readable instruction is realized when being executed by processor As above the video broadcasting method based on GStreamer frameworks in each embodiment.
In one exemplary embodiment, a kind of computer-readable recording medium, is stored thereon with computer program, the calculating The video broadcasting method based on GStreamer frameworks in each embodiment as above is realized when machine program is executed by processor.
The preferable examples embodiment of the above, the only disclosure, the embodiment for being not intended to limit the disclosure, this Field those of ordinary skill can very easily carry out corresponding flexible or repair according to the central scope and spirit of the disclosure Change, therefore the protection domain of the disclosure should be defined by the protection domain required by claims.

Claims (10)

  1. A kind of 1. video broadcasting method based on GStreamer frameworks, it is characterised in that including:
    By specifying caching to obtain video data;
    Call decoder plug-in unit to be decoded to obtain decoding data to the video data, and the decoding data is stored to institute State the output caching of decoder plug-in unit setting;
    Player plug-in unit is obtained by the media decoder object of the specified caching push, and is called and sealed in the media decoder object The display interface of dress carries out video playback to the decoding data in the output caching, and the media decoder object is regarded for structure Frequency play-back application and create.
  2. 2. the method as described in claim 1, it is characterised in that the player plug-in unit is obtained by the specified caching push Media decoder object, and the display interface encapsulated in the media decoder object is called to the decoding data in the output caching Before carrying out video playback, methods described also includes:
    The media decoder object is defined for structure video playback application program;
    One structure is constructed according to the pointer of the pointer of the media decoder object and the output caching, and by the structure The player plug-in unit is pushed to by the specified caching.
  3. 3. method as claimed in claim 2, it is characterised in that the player plug-in unit is obtained by the specified caching push Media decoder object, and the display interface encapsulated in the media decoder object is called to the decoding data in the output caching Video playback is carried out, including:
    The pointer of the media decoder object and the pointer of the output caching are extracted by the structure;
    The display interface encapsulated in the media decoder object is called by the pointer of the media decoder object, and by described The pointer of output caching reads the decoding data in the output caching;
    Decoding data is carried out by the display interface to show.
  4. 4. method as claimed in claim 2, it is characterised in that the player plug-in unit is obtained by the specified caching push Media decoder object, and the display interface encapsulated in the media decoder object is called to the decoding data in the output caching Before carrying out video playback, methods described also includes:
    The captions structure pointer of caption data is pointed in extension one in the structure;
    It is described to call the display interface encapsulated in the media decoder object to regard the decoding data in the output caching Frequency plays, in addition to:
    The captions structure pointer is extracted by the structure, and the captions number is obtained by the captions structure pointer According to;
    When carrying out video playback to the decoding data, captions number is carried out according to the Subtitle Demonstration mode indicated in title plug-ins According to display.
  5. 5. the method as described in any one of Claims 1-4, it is characterised in that the display encapsulated in the media decoder object Interface is the standard application program interface of Android system.
  6. A kind of 6. video play device based on GStreamer frameworks, it is characterised in that including:
    Data acquisition module, for by specifying caching to obtain video data;
    Data decoder module, for calling decoder plug-in unit to be decoded to obtain decoding data to the video data, and by institute State decoding data and store the output caching set to the decoder plug-in unit;
    Data playback module, obtained for player plug-in unit by the media decoder object of the specified caching push, and call institute State the display interface encapsulated in media decoder object and video playback, the media are carried out to the decoding data in the output caching Decoder object creates for structure video playback application program.
  7. 7. device as claimed in claim 6, it is characterised in that described device also includes:
    Object definition module, for defining the media decoder object for structure video playback application program;
    Structure constructing module, the pointer for the pointer according to the media decoder object and the output caching construct a knot Structure body, and the structure is pushed into the player plug-in unit by the specified caching.
  8. 8. device as claimed in claim 7, it is characterised in that the data playback module includes:
    Pointer extracting unit, for extracting the pointer of the media decoder object and the finger of the output caching by the structure Pin;
    Pointer applying unit, for calling what is encapsulated in the media decoder object to show by the pointer of the media decoder object Show interface, and the decoding data exported in caching is read by the pointer of the output caching;
    Data display unit, shown for carrying out decoding data by the display interface.
  9. 9. device as claimed in claim 7, it is characterised in that described device also includes:
    Structure expansion module, the captions structure pointer for the sensing of extension one caption data in the structure;
    The data playback module also includes:
    Captions acquiring unit, for extracting the captions structure pointer by the structure, and pass through the captions structure Pointer obtains the caption data;
    Subtitle Demonstration unit, for the decoding data carry out video playback when, according to the captions indicated in title plug-ins Display mode carries out caption data and shown.
  10. 10. a kind of electronic equipment, it is characterised in that including:
    Processor;And
    Memory, computer-readable instruction is stored with the memory, the computer-readable instruction is held by the processor The video broadcasting method based on GStreamer frameworks as any one of claim 1 to 5 is realized during row.
CN201710934925.7A 2017-10-10 2017-10-10 Video playing method and device based on GStreamer frame and electronic equipment Active CN107613369B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201710934925.7A CN107613369B (en) 2017-10-10 2017-10-10 Video playing method and device based on GStreamer frame and electronic equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201710934925.7A CN107613369B (en) 2017-10-10 2017-10-10 Video playing method and device based on GStreamer frame and electronic equipment

Publications (2)

Publication Number Publication Date
CN107613369A true CN107613369A (en) 2018-01-19
CN107613369B CN107613369B (en) 2020-06-16

Family

ID=61067744

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201710934925.7A Active CN107613369B (en) 2017-10-10 2017-10-10 Video playing method and device based on GStreamer frame and electronic equipment

Country Status (1)

Country Link
CN (1) CN107613369B (en)

Cited By (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108989890A (en) * 2018-09-03 2018-12-11 四川长虹电器股份有限公司 Check method in audio-video mistake source based on GStreamer frame
CN109151571A (en) * 2018-10-10 2019-01-04 四川长虹电器股份有限公司 The method that DST PLAYER in DTV based on GStreamer frame promotes image quality
CN110062296A (en) * 2019-04-09 2019-07-26 南昌嘉研科技有限公司 A kind of real time flow medium player and its framework method
CN110493626A (en) * 2019-09-10 2019-11-22 海信集团有限公司 Video data handling procedure and device
CN115190262A (en) * 2021-04-02 2022-10-14 海信集团控股股份有限公司 Electronic device, video stream processing method, device and medium
CN115550708A (en) * 2022-01-07 2022-12-30 荣耀终端有限公司 Data processing method and electronic equipment

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104333808A (en) * 2014-11-14 2015-02-04 复旦大学 General player applied to Android and Linux smart televisiosn
CN104484181A (en) * 2014-12-23 2015-04-01 北京元心科技有限公司 Method, device and mobile device for controlling Android camera under glibc environment
CN104754349A (en) * 2013-12-25 2015-07-01 炫一下(北京)科技有限公司 Method and device for hardware decoding of audio/video
CN105898538A (en) * 2015-12-14 2016-08-24 乐视网信息技术(北京)股份有限公司 Play method and device and mobile terminal equipment based on Android platform

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104754349A (en) * 2013-12-25 2015-07-01 炫一下(北京)科技有限公司 Method and device for hardware decoding of audio/video
CN104333808A (en) * 2014-11-14 2015-02-04 复旦大学 General player applied to Android and Linux smart televisiosn
CN104484181A (en) * 2014-12-23 2015-04-01 北京元心科技有限公司 Method, device and mobile device for controlling Android camera under glibc environment
CN105898538A (en) * 2015-12-14 2016-08-24 乐视网信息技术(北京)股份有限公司 Play method and device and mobile terminal equipment based on Android platform

Cited By (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108989890A (en) * 2018-09-03 2018-12-11 四川长虹电器股份有限公司 Check method in audio-video mistake source based on GStreamer frame
CN109151571A (en) * 2018-10-10 2019-01-04 四川长虹电器股份有限公司 The method that DST PLAYER in DTV based on GStreamer frame promotes image quality
CN109151571B (en) * 2018-10-10 2021-03-02 四川长虹电器股份有限公司 Method for improving image quality of streaming media player based on GStreamer frame in digital television
CN110062296A (en) * 2019-04-09 2019-07-26 南昌嘉研科技有限公司 A kind of real time flow medium player and its framework method
CN110062296B (en) * 2019-04-09 2021-06-29 南昌嘉研科技有限公司 Real-time streaming media player and architecture method thereof
CN110493626A (en) * 2019-09-10 2019-11-22 海信集团有限公司 Video data handling procedure and device
CN115190262A (en) * 2021-04-02 2022-10-14 海信集团控股股份有限公司 Electronic device, video stream processing method, device and medium
CN115550708A (en) * 2022-01-07 2022-12-30 荣耀终端有限公司 Data processing method and electronic equipment
CN115550708B (en) * 2022-01-07 2023-12-19 荣耀终端有限公司 Data processing method and electronic equipment

Also Published As

Publication number Publication date
CN107613369B (en) 2020-06-16

Similar Documents

Publication Publication Date Title
CN107613369A (en) Video broadcasting method, device and electronic equipment based on GStreamer frameworks
WO2021093583A1 (en) Video stream processing method and apparatus, terminal device, and computer readable storage medium
KR102170781B1 (en) Electronic device and method for processing image
WO2021115194A1 (en) Application icon display method and electronic device
US20150061971A1 (en) Method and system for presenting content
CN104967801A (en) Video data processing method and apparatus
CN108702480A (en) Electronic equipment and method for driving its display
CN106658079A (en) Customized expression image generation method and device
KR20150027891A (en) Method and apparatus for presenting content using electronic devices
CN104980820A (en) Multimedia file playing method and multimedia file playing device
CN106101743A (en) Panoramic video recognition methods and device
KR20150027934A (en) Apparatas and method for generating a file of receiving a shoot image of multi angle in an electronic device
KR102187227B1 (en) Method for creating a content and an electronic device thereof
CN105653195B (en) Screenshotss method and mobile terminal
CN106101868A (en) Reduced graph generating method and generating means
CN110933289A (en) Continuous shooting method based on binocular camera, shooting device and terminal equipment
CN104966526B (en) A kind of shuffle method and device
KR102213429B1 (en) Apparatus And Method For Providing Sound
CN107431752B (en) Processing method and portable electronic equipment
CN108255445A (en) Vehicle device mirror image operation method, vehicle device, mobile terminal and vehicle
CN108345434B (en) Data writing method and device, computer equipment and readable storage medium
CN115665342A (en) Image processing method, image processing circuit, electronic device, and readable storage medium
CN105430260B (en) Obtain the method and device of video image
CN108601063A (en) Personal hot spot implementation method and Related product
CN108124098A (en) Electronic equipment and the method for focusing on automatically

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
CB02 Change of applicant information
CB02 Change of applicant information

Address after: 266000, No. 218, Bay Road, Qingdao economic and Technological Development Zone, Shandong

Applicant after: Hisense Video Technology Co., Ltd

Address before: 266555 Qingdao economic and Technological Development Zone, Shandong, Hong Kong Road, No. 218

Applicant before: HISENSE ELECTRIC Co.,Ltd.

GR01 Patent grant
GR01 Patent grant