CN103051946A - General real time streaming protocol (RTSP) stream player based on Android system - Google Patents
General real time streaming protocol (RTSP) stream player based on Android system Download PDFInfo
- Publication number
- CN103051946A CN103051946A CN2012105730105A CN201210573010A CN103051946A CN 103051946 A CN103051946 A CN 103051946A CN 2012105730105 A CN2012105730105 A CN 2012105730105A CN 201210573010 A CN201210573010 A CN 201210573010A CN 103051946 A CN103051946 A CN 103051946A
- Authority
- CN
- China
- Prior art keywords
- player
- module
- audio
- data
- storehouse
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Pending
Links
Images
Landscapes
- Two-Way Televisions, Distribution Of Moving Picture Or The Like (AREA)
Abstract
The invention discloses a general real time streaming protocol (RTSP) stream player based on an Android system. The player is characterized by comprising an audio and video decoding library, a dynamic library based on a C langue and a Java archive (JAR) library based on a Java language. The player has the beneficial effects that the player has a function of playing RTSP protocol audio and video streams; the player supports the operating systems of Android 2.0 version and updated versions; and the player supports ARMv6 (Advanced RISC Machines) architectures and updated ARM chip platforms.
Description
Technical field
The present invention relates to intelligent terminal player field, the particularly intelligent terminal of Andriod operating system.
Background technology
Present Android intelligent terminal on the market, great majority are not supported the connected mode playing audio-video stream by the RTSP agreement, even support, can not revise the interaction protocol of RTSP, can not spread to some special application scenarioss, such as the monitoring video flow of playing the RTSP agreement by intelligent terminal.For the problem of present existence, invented the general RTSP stream player based on the Andriod system.
Summary of the invention
The object of the invention is to: for the problem of present existence, provide a kind of Andriod operating system of compatible miscellaneous editions, support ARMv6 framework and above ARM chip platform, can play the player of RTSP audio/video flow.
The object of the invention technical scheme is: based on the general RTSP stream player of Android system, comprise the audio/video decoding storehouse, based on the dynamic base of C language with based on the JAR storehouse of Java language.
The audio/video decoding storehouse is used for data acquisition, data decode;
Be used for connecting the audio/video decoding storehouse and based on the JAR storehouse of Java language based on the dynamic base of C language, the data of audio/video decoding storehouse decoding are shown;
JAR storehouse based on Java language is used for funcall, parameter transmission and player control.
In the such scheme, described audio/video decoding storehouse comprises tool model, demultiplexing module, decoder module and picture Zoom module.
In the such scheme, tool model reaches reusing of source code for the modules in audio/video decoding storehouse provides general function interface; Demultiplexing module is unpacked to file or network data, therefrom extracts the Voice ﹠ Video data; Decoder module is exported the audio frequency and video initial data that the Android system supports to the Voice ﹠ Video decoding data.
In the such scheme, described dynamic base based on the C language is comprised of three parts: jni module, audio frequency output module and video output module.
In the such scheme, described JAR storehouse is comprised of two parts: java api module and jni api module.
In the such scheme, the described player method that flows player based on the general RTSP of Android system:
Step 1: each functional module of initialization;
Step 2: tool model obtains audio, video data;
Step 3: demultiplexing module is unpacked to the data of obtaining, and isolates the Voice ﹠ Video data;
Step 4: the decoding data of decoder module to separating, pass to dynamic base;
Step 5: dynamic base is play decoded audio, video data and is shown.
In the such scheme, the player method of player, at first call the java api module in the JAR storehouse when described each functional module of step 1 initialization, then described java api module is called the function in the jni api module, then by modules in the described dynamic base of jni method call.
In the such scheme, the player method of player, after described step 1 finished, the RTSP address passed to tool model in the audio/video decoding module by the jni method, after tool model obtains this address, carry out interactive authentication and data acquisition by socket and RTSP server.
In the such scheme, the player method of player, in described step 4, decoder module is to extract data format from the SDP domain information that streaming media server returns, and the parameter in described decoding storehouse is set.
In the such scheme, the player method of player, described audio/video decoding storehouse can be processed the floating-point in the ARM framework and multimedia instruction.
Compared with prior art, the beneficial effect of technique scheme: because the audio/video decoding storehouse and based on the dynamic base of C language at the C space motion, improved the decoding efficiency of audio frequency and video; Support the broadcast of the audio/video flow of RTSP agreement; Support the operating system of Android 2.0 and above version; Support ARMv6 framework and above ARM chip platform, therefore have versatility.
Description of drawings
Fig. 1 is framework schematic diagram of the present invention;
Fig. 2 is workflow diagram of the present invention.
Embodiment
As shown in Figure 1, based on the general RTSP stream player of Android system, comprise the audio/video decoding storehouse, based on the dynamic base of C language with based on the JAR storehouse of Java language.
The audio/video decoding storehouse is comprised of four parts: tool model, demultiplexing module, decoder module and picture Zoom module form.
Dynamic base based on the C language is comprised of three parts: jni module, audio frequency output module and video output module.
The JAR storehouse is comprised of two parts: java api module and jni api module.
The tool model in audio/video decoding storehouse reaches reusing of source code for the modules in audio/video decoding storehouse provides general function interface; Demultiplexing module is unpacked to file or network data, therefrom extracts the Voice ﹠ Video data; Decoder module is to the Voice ﹠ Video decoding data, thus the audio frequency and video initial data that output Android system supports.
, for providing the bridge of communication, JAR storehouse and audio/video decoding storehouse guarantee mutually to call between Java and the C language based on the jni module of the dynamic base of C language; The audio frequency output module is sent the voice data of exporting in the audio/video decoding storehouse into system bottom and is play; The video output module is sent the video data of exporting in the audio/video decoding storehouse into system bottom and is shown.
The java api module in JAR storehouse provides the api that can call function for the developer; Jni api module provides the JAR storehouse the inner api function that uses, and does not open to the outside world, can call power function in the dynamic base by jni api.
The workflow of the general RTSP stream player of the Android system that is based on that Fig. 2 shows, its workflow comprises initialization flow process and playing flow.
The initialization flow process:
Call the java api module in the JAR storehouse, then this module is called the function in the jni api module, then pass through the initial method of modules in the jni method call dynamic base, wherein when initialization jni module, can call the initial method of modules in the audio/video decoding storehouse, so far finish the initial work of all modules.
Playing flow:
At the java layer, the RTSP address passes to the audio/video decoding storehouse by the jni method, after tool model obtains this address, carries out interactive authentication and data acquisition by socket and RTSP server; Demultiplexing module is unpacked the data that tool model obtains, and isolates Voice ﹠ Video data wherein; Decoder module is respectively for the Voice ﹠ Video decoding data, then decoded data returned to audio frequency output module in the dynamic base and video output module and plays and show.
In order to allow player reach the effect of anticipation, technical scheme has overcome following difficulty:
1. in order to allow the correct compiling in audio/video decoding storehouse and true(-)running on Android system and ARM chip platform, made following modification:
A) the processor parameter in audio/video decoding storehouse is set, is appointed as the ARM framework;
B) the cross-platform compile option in audio/video decoding storehouse is set;
C) increase is to the support of the instructions such as floating-point, multimedia in the ARM framework.
2. in order to allow tool model correctly compile, made following modification:
Because the compilation tool of Android is not supported the restrict keyword, revise the config.h file under the source code of audio/video decoding storehouse, #define restrict restrict is revised as #define restrict; Revise the libavutil/libm.h file, static method is wherein all deleted;
3. in order to allow demultiplexing module correctly compile, and support file greater than 4GB, made following modification:
Revise the file_seek () function in the libavformat/file.c file, lseek () function is revised as lseek64 () function, make the demultiplexing module support greater than the file of 4GB;
4. for the data format of resolution flow media server, revise the libavformat/rtsp.c file.After the modification, send the SDP domain information that the rear streaming media server of Describe order returns with resolving, therefrom extract data format, thereby the parameter in decoding storehouse is set, make audio/video decoding have more autgmentability.
Claims (10)
1. based on the general RTSP stream player of Android system, comprise the audio/video decoding storehouse, based on the dynamic base of C language with based on the JAR storehouse of Java language;
Described audio/video decoding storehouse is used for that audio, video data obtains, data decode;
Described dynamic base based on the C language connects the audio/video decoding storehouse and based on the JAR storehouse of Java language, the data of audio/video decoding storehouse decoding are play and is shown;
Described JAR storehouse based on Java language is used for funcall, parameter transmission and player control.
2. player as claimed in claim 1 is characterized in that described audio/video decoding storehouse comprises tool model, demultiplexing module, decoder module and picture Zoom module.
3. player as claimed in claim 2, it is characterized in that: above-mentioned tool model reaches reusing of source code for the audio/video decoding storehouse provides general function interface; Demultiplexing module is unpacked to file or network data, therefrom extracts the Voice ﹠ Video data; Decoder module is exported the audio frequency and video initial data that the Android system supports to the Voice ﹠ Video decoding data.
4. player as claimed in claim 1 is characterized in that described dynamic base based on the C language is comprised of three parts: jni module, audio frequency output module and video output module.
5. player as claimed in claim 1 is characterized in that described JAR storehouse is comprised of two parts: java api module and jni api module.
6. the player method of the general RTSP stream player based on the Android system as claimed in claim 1: comprise the steps:
Step 1: each functional module of initialization;
Step 2: tool model obtains audio, video data;
Step 3: demultiplexing module is unpacked to the data of obtaining, and isolates the Voice ﹠ Video data;
Step 4: the decoding data of decoder module to separating, pass to dynamic base;
Step 5: dynamic base is play decoded data and is shown.
7. the player method of the general RTSP stream player based on the Android system as claimed in claim 6, further comprise: when each functional module of above-mentioned steps one initialization, at first call the java api module in the JAR storehouse, then described java api module is called the function in the jni api module, then by modules in the above-mentioned dynamic base of jni method call.
8. the player method of the general RTSP stream player based on the Android system as claimed in claim 7, further comprise: after above-mentioned steps one finishes, the RTSP address passes to tool model in the audio/video decoding module by the jni method, after tool model obtains this address, carry out interactive authentication and data acquisition by socket and RTSP server.
9. the player method of the general RTSP stream player based on the Android system as claimed in claim 8, further comprise: in above-mentioned steps four, decoder module is to extract data format from the SDP domain information that streaming media server returns, and the parameter in above-mentioned decoding storehouse is set.
10. such as the player method of the described general RTSP stream player based on the Android system of one of claim 6-9, further comprise: above-mentioned audio/video decoding storehouse can be processed the floating-point in the ARM framework and multimedia instruction.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN2012105730105A CN103051946A (en) | 2012-12-26 | 2012-12-26 | General real time streaming protocol (RTSP) stream player based on Android system |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN2012105730105A CN103051946A (en) | 2012-12-26 | 2012-12-26 | General real time streaming protocol (RTSP) stream player based on Android system |
Publications (1)
Publication Number | Publication Date |
---|---|
CN103051946A true CN103051946A (en) | 2013-04-17 |
Family
ID=48064427
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN2012105730105A Pending CN103051946A (en) | 2012-12-26 | 2012-12-26 | General real time streaming protocol (RTSP) stream player based on Android system |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN103051946A (en) |
Cited By (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
WO2016154855A1 (en) * | 2015-03-30 | 2016-10-06 | 联发科技(新加坡)私人有限公司 | Method of expanding function of android standard multimedia player and multimedia playing system |
CN106792124A (en) * | 2016-12-30 | 2017-05-31 | 合网络技术(北京)有限公司 | Multimedia resource decodes player method and device |
CN107666620A (en) * | 2017-09-26 | 2018-02-06 | 上海爱优威软件开发有限公司 | A kind of terminal system layer decoder method and system |
CN111651156A (en) * | 2020-06-04 | 2020-09-11 | 广州鲁邦通物联网科技有限公司 | Software development kit adaptive to multiple development languages and calling method |
Citations (2)
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 |
CN102789381A (en) * | 2011-12-31 | 2012-11-21 | 浙江创佳数字技术有限公司 | Method for achieving digital televisions in accordance to digital video broadcasting (DVB) standards in Andriod system |
-
2012
- 2012-12-26 CN CN2012105730105A patent/CN103051946A/en active Pending
Patent Citations (2)
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 |
CN102789381A (en) * | 2011-12-31 | 2012-11-21 | 浙江创佳数字技术有限公司 | Method for achieving digital televisions in accordance to digital video broadcasting (DVB) standards in Andriod system |
Cited By (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
WO2016154855A1 (en) * | 2015-03-30 | 2016-10-06 | 联发科技(新加坡)私人有限公司 | Method of expanding function of android standard multimedia player and multimedia playing system |
CN106792124A (en) * | 2016-12-30 | 2017-05-31 | 合网络技术(北京)有限公司 | Multimedia resource decodes player method and device |
CN107666620A (en) * | 2017-09-26 | 2018-02-06 | 上海爱优威软件开发有限公司 | A kind of terminal system layer decoder method and system |
CN111651156A (en) * | 2020-06-04 | 2020-09-11 | 广州鲁邦通物联网科技有限公司 | Software development kit adaptive to multiple development languages and calling method |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN104159150B (en) | Cloud terminal, Cloud Server, media data flow play system and method | |
CN104158836A (en) | Method for rendering mobile application interface through data | |
CN104780378A (en) | Method, device and player for decoding video | |
CN1529849A (en) | Method and apparatus for compitation of interpretative language for interactive television | |
CN102510543A (en) | Method and system for playing audio/video | |
CN112804592B (en) | RTSP live video forwarding method and terminal based on browser | |
CN103051946A (en) | General real time streaming protocol (RTSP) stream player based on Android system | |
CN103686210A (en) | Method and system for achieving audio and video transcoding in real time | |
CN103200448A (en) | Android system of set top box (STB) | |
CN105763898A (en) | Method and system for controlling IPTV set-top box by voice | |
CN106358047A (en) | Method and device for playing streaming media video | |
CN102186114B (en) | ETL (Extraction Transformation and Loading) based digital television interactive application middleware | |
CN102722377B (en) | Network video application processing system based on adaptive communication environment (ACE) framework | |
CN103269450B (en) | A kind of multimedia system towards Android intelligent television | |
CN101442627A (en) | Control method for peer-to-peer calculation set-top box player | |
CN101729827A (en) | Voice service method, system, digital television receiving terminal and front-end device | |
CN104023260A (en) | Hardware decoding implementation method and device, and player | |
CN102036121A (en) | Digital television browser based mosaic video navigation method | |
CN116841559A (en) | Transcoding method, device, apparatus, medium and program product | |
CN105744344B (en) | playing control method and system | |
CN105120323A (en) | Distributed player task scheduling method and system | |
CN102395051B (en) | Video player system, development method thereof and installation operation method thereof | |
CN109669691A (en) | Platform universal control method and system based on built-in Linux audio player | |
CN103702172A (en) | Method and system for carrying out dolby transcoding on AV (Audio/Video) | |
CN104269185B (en) | Method and system for realizing sound mixing play in Java virtual machine |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
C06 | Publication | ||
PB01 | Publication | ||
C10 | Entry into substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
C02 | Deemed withdrawal of patent application after publication (patent law 2001) | ||
WD01 | Invention patent application deemed withdrawn after publication |
Application publication date: 20130417 |