【正文】
型產(chǎn)業(yè)”。我國資深嵌入式系統(tǒng)專家——沈緒榜院士曾預(yù)言:“未來十年將會產(chǎn)生針頭大小,具有超過一億次運(yùn)算能力的嵌入式智能芯片”。Linux系統(tǒng)下提供了非常豐富的開源軟件和視頻支持,支持各種硬件平臺,因此Linux平臺成為了視頻采集的最佳平臺。在流媒體技術(shù)的發(fā)展中,視頻技術(shù)的發(fā)展越來越迅速,大量應(yīng)用于安防與教育事業(yè),比如在遠(yuǎn)程視頻教育、在線遠(yuǎn)程視頻會議、醫(yī)療、各種場所的視頻監(jiān)控以及危險(xiǎn)區(qū)域的探測等方面?!娟P(guān)鍵詞】:Linux QT技術(shù) v4l2編程 協(xié)議Design and implementation of video monitoring system based on Linux and QTAbstractAlong with the social network technology unceasing renewal, puter multimedia application technology and network technology aspects of the rapid development of is be obvious to banks, shopping malls monitoring, urban traffic management, security and other aspects of the hotel. Market demand for video surveillance systemincreased significantly. Appeared on the market a variety of image acquisition and transmission products, the development trend of video surveillance system must be digital, network, and the use of embedded network camera. With the embedded monitoring equipment pact, stable performance, munication facilities and so on. At the present stage of our country, research and development of streaming media technology and the embedded network video monitoring technology is not mature enough, mostly in those big, video monitoring system and medium engineering development. But for a small place, the cost is too high, the video monitoring system with plex functions. Therefore, we according to the user group, can design a simple, low cost, video monitoring system model. This is a very meaningful project. This paper mainly introduces the system development process, the use of the design method of modularization analysis, the program flow chart of each module of the system design and implementation are described in detail, the full text is divided into introduction, the overall design of the system, each module of the specific function realization of video monitoring system, and the conclusion of this test the five part. Data collection by v4l2, TCP and multi thread programming for data processing based on QT technology to realize the client program. Sending video data is using HTTP protocol, the Linux system under the C programming language.【Key words】 Linux QT Technology v4l2 Programming Protocol28緒論Linux是一個基于Unix的操作系統(tǒng),它也是Unix家族的一元,與Unix不同的是,它可以運(yùn)行在不同的硬件平臺上,它于1991年誕生于芬蘭的一個大學(xué)生Linus Tor valds手中,不過當(dāng)時(shí)還只是一個雛形,為了不讓自己的這個羽翼未滿的操作系統(tǒng)夭折,Linus將自己的作品Linux通過Internet發(fā)布,從此大量的一批知名的、不知名的編程人員以及電腦黑客加入到Linux系統(tǒng)的開發(fā)過程中來,Linux就這樣的逐漸成長起來了[1]。利用v4l2進(jìn)行數(shù)據(jù)采集,基于TCP編程和多線程編程對數(shù)據(jù)進(jìn)行處理,QT技術(shù)來實(shí)現(xiàn)客戶端程序。這是一項(xiàng)非常有意義的工程。但是對于小型的場所來說,成本太高,視頻監(jiān)控系統(tǒng)的功能復(fù)雜?;贚inux、QT的視頻監(jiān)控系統(tǒng)的設(shè)計(jì)與實(shí)現(xiàn)畢業(yè)論文目 錄緒論 11 基于Linux、QT的視頻監(jiān)控系統(tǒng)概述 4 視頻監(jiān)控系統(tǒng)的組成 4 開發(fā)環(huán)境簡介 4 Linux環(huán)境簡介 4 QT技術(shù)簡介 4 V4L2編程技術(shù)簡介 52 系統(tǒng)總體設(shè)計(jì)概述 7 分析系統(tǒng)需求 7 系統(tǒng)的軟件結(jié)構(gòu)及整體框架 7 整體結(jié)構(gòu)框圖 7 模塊的功能分析 83 系統(tǒng)中各模塊功能的具體實(shí)現(xiàn) 9 服務(wù)器:數(shù)據(jù)采集部分 9 模塊功能描述 9 技術(shù)概要 9 邏輯概要及流程圖 10 服務(wù)器:數(shù)據(jù)處理 17 模塊功能描述 17 技術(shù)概要 17 邏輯概要及程序流程圖 17 客戶端:數(shù)據(jù)獲取 19 模塊功能描述 19 技術(shù)概要 19 邏輯概要及流程圖 19 客戶端:QT視頻渲染 21 模塊功能描述 21 技術(shù)概要 22 邏輯概要及流程圖 224 視頻監(jiān)控系統(tǒng)測試 23 系統(tǒng)測試目標(biāo) 23 系統(tǒng)測試過程 23 系統(tǒng)測試結(jié)果 25結(jié)論 26參考文獻(xiàn) 27致 謝 28插圖索引圖1 視頻監(jiān)控系統(tǒng)結(jié)構(gòu)圖 7圖2 服務(wù)器(server)端視頻數(shù)據(jù)采集流程 10圖3 打開USB攝像頭設(shè)備流程圖 11圖4 查詢視頻設(shè)備信息流程圖 12圖5 設(shè)置視頻采集方式流程圖 13圖6 申請緩沖區(qū)流程圖 14圖7 緩沖區(qū)設(shè)置流程圖 15圖8 視頻數(shù)據(jù)處理流程圖 16圖9 服務(wù)器端數(shù)據(jù)處理流程圖 18圖10 服務(wù)器端數(shù)據(jù)幀封裝結(jié)構(gòu)圖 19圖11 服務(wù)器與客戶端TCP網(wǎng)絡(luò)編程流程圖 20圖12 客戶端的數(shù)據(jù)分割流程圖 21圖13 客戶端視頻渲染模塊流程圖 22圖14 啟動系統(tǒng)效果圖(左:客戶端,右:服務(wù)端) 24圖15 客戶端準(zhǔn)備連接時(shí)效果圖(左:客戶端,右:服務(wù)端) 24圖16 系統(tǒng)網(wǎng)絡(luò)連接后效果圖(左:客戶端,右:服務(wù)端) 25基于Linux、QT的視頻監(jiān)控系統(tǒng)的設(shè)計(jì)與實(shí)現(xiàn)摘 要隨著社會的網(wǎng)絡(luò)技術(shù)的不斷更新,計(jì)算機(jī)多媒體應(yīng)用技術(shù)及網(wǎng)絡(luò)技術(shù)方面的發(fā)展之迅速是有目共睹的,在銀行,商場監(jiān)控,城市交通管理,酒店等安全保衛(wèi)方面,視頻監(jiān)控系統(tǒng)的市場需求量大幅度上升,市場上出現(xiàn)了多種圖像采集和傳輸?shù)漠a(chǎn)品,視頻監(jiān)控系統(tǒng)的發(fā)展趨勢必然是數(shù)字化,網(wǎng)絡(luò)化,即采用嵌入式網(wǎng)絡(luò)攝像機(jī),利用嵌入式監(jiān)控設(shè)備體積小巧,性能穩(wěn)定,通訊便利等特點(diǎn)。在我國現(xiàn)階段,流媒體技術(shù)以及嵌入式網(wǎng)絡(luò)視頻監(jiān)控技術(shù)的研發(fā)還不夠成熟,大多是針對那些大,中型工程所開發(fā)的視頻監(jiān)控系統(tǒng)。因此我們可以設(shè)計(jì)一種低成本的,簡便的,新型的視頻監(jiān)控系統(tǒng)針對上述用戶群。