qt_demoe/docs/video_system/index.html

735 lines
475 KiB
HTML
Raw Normal View History

2022-06-02 06:36:30 +00:00
<!doctype html>
2021-07-10 09:47:51 +00:00
<html>
<head>
2022-06-02 06:36:30 +00:00
<meta charset='UTF-8'><meta name='viewport' content='width=device-width initial-scale=1'>
<link href='https://fonts.loli.net/css?family=Open+Sans:400italic,700italic,700,400&subset=latin,latin-ext' rel='stylesheet' type='text/css' /><style type='text/css'>html {overflow-x: initial !important;}:root { --bg-color:#ffffff; --text-color:#333333; --select-text-bg-color:#B5D6FC; --select-text-font-color:auto; --monospace:"Lucida Console",Consolas,"Courier",monospace; --title-bar-height:20px; }
.mac-os-11 { --title-bar-height:28px; }
html { font-size: 14px; background-color: var(--bg-color); color: var(--text-color); font-family: "Helvetica Neue", Helvetica, Arial, sans-serif; -webkit-font-smoothing: antialiased; }
body { margin: 0px; padding: 0px; height: auto; inset: 0px; font-size: 1rem; line-height: 1.42857; overflow-x: hidden; background: inherit; tab-size: 4; }
iframe { margin: auto; }
a.url { word-break: break-all; }
a:active, a:hover { outline: 0px; }
.in-text-selection, ::selection { text-shadow: none; background: var(--select-text-bg-color); color: var(--select-text-font-color); }
#write { margin: 0px auto; height: auto; width: inherit; word-break: normal; overflow-wrap: break-word; position: relative; white-space: normal; overflow-x: visible; padding-top: 36px; }
#write.first-line-indent p { text-indent: 2em; }
#write.first-line-indent li p, #write.first-line-indent p * { text-indent: 0px; }
#write.first-line-indent li { margin-left: 2em; }
.for-image #write { padding-left: 8px; padding-right: 8px; }
body.typora-export { padding-left: 30px; padding-right: 30px; }
.typora-export .footnote-line, .typora-export li, .typora-export p { white-space: pre-wrap; }
.typora-export .task-list-item input { pointer-events: none; }
@media screen and (max-width: 500px) {
body.typora-export { padding-left: 0px; padding-right: 0px; }
#write { padding-left: 20px; padding-right: 20px; }
}
#write li > figure:last-child { margin-bottom: 0.5rem; }
#write ol, #write ul { position: relative; }
img { max-width: 100%; vertical-align: middle; image-orientation: from-image; }
button, input, select, textarea { color: inherit; font: inherit; }
input[type="checkbox"], input[type="radio"] { line-height: normal; padding: 0px; }
*, ::after, ::before { box-sizing: border-box; }
#write h1, #write h2, #write h3, #write h4, #write h5, #write h6, #write p, #write pre { width: inherit; }
#write h1, #write h2, #write h3, #write h4, #write h5, #write h6, #write p { position: relative; }
p { line-height: inherit; }
h1, h2, h3, h4, h5, h6 { break-after: avoid-page; break-inside: avoid; orphans: 4; }
p { orphans: 4; }
h1 { font-size: 2rem; }
h2 { font-size: 1.8rem; }
h3 { font-size: 1.6rem; }
h4 { font-size: 1.4rem; }
h5 { font-size: 1.2rem; }
h6 { font-size: 1rem; }
.md-math-block, .md-rawblock, h1, h2, h3, h4, h5, h6, p { margin-top: 1rem; margin-bottom: 1rem; }
.hidden { display: none; }
.md-blockmeta { color: rgb(204, 204, 204); font-weight: 700; font-style: italic; }
a { cursor: pointer; }
sup.md-footnote { padding: 2px 4px; background-color: rgba(238, 238, 238, 0.7); color: rgb(85, 85, 85); border-radius: 4px; cursor: pointer; }
sup.md-footnote a, sup.md-footnote a:hover { color: inherit; text-transform: inherit; text-decoration: inherit; }
#write input[type="checkbox"] { cursor: pointer; width: inherit; height: inherit; }
figure { overflow-x: auto; margin: 1.2em 0px; max-width: calc(100% + 16px); padding: 0px; }
figure > table { margin: 0px; }
2022-07-02 04:18:12 +00:00
thead, tr { break-inside: avoid; break-after: auto; }
2022-06-02 06:36:30 +00:00
thead { display: table-header-group; }
table { border-collapse: collapse; border-spacing: 0px; width: 100%; overflow: auto; break-inside: auto; text-align: left; }
table.md-table td { min-width: 32px; }
.CodeMirror-gutters { border-right: 0px; background-color: inherit; }
.CodeMirror-linenumber { user-select: none; }
.CodeMirror { text-align: left; }
.CodeMirror-placeholder { opacity: 0.3; }
.CodeMirror pre { padding: 0px 4px; }
.CodeMirror-lines { padding: 0px; }
div.hr:focus { cursor: none; }
#write pre { white-space: pre-wrap; }
#write.fences-no-line-wrapping pre { white-space: pre; }
#write pre.ty-contain-cm { white-space: normal; }
.CodeMirror-gutters { margin-right: 4px; }
.md-fences { font-size: 0.9rem; display: block; break-inside: avoid; text-align: left; overflow: visible; white-space: pre; background: inherit; position: relative !important; }
.md-fences-adv-panel { width: 100%; margin-top: 10px; text-align: center; padding-top: 0px; padding-bottom: 8px; overflow-x: auto; }
#write .md-fences.mock-cm { white-space: pre-wrap; }
.md-fences.md-fences-with-lineno { padding-left: 0px; }
#write.fences-no-line-wrapping .md-fences.mock-cm { white-space: pre; overflow-x: auto; }
.md-fences.mock-cm.md-fences-with-lineno { padding-left: 8px; }
.CodeMirror-line, twitterwidget { break-inside: avoid; }
2022-07-02 04:18:12 +00:00
svg { break-inside: avoid; }
2022-06-02 06:36:30 +00:00
.footnotes { opacity: 0.8; font-size: 0.9rem; margin-top: 1em; margin-bottom: 1em; }
.footnotes + .footnotes { margin-top: 0px; }
.md-reset { margin: 0px; padding: 0px; border: 0px; outline: 0px; vertical-align: top; background: 0px 0px; text-decoration: none; text-shadow: none; float: none; position: static; width: auto; height: auto; white-space: nowrap; cursor: inherit; -webkit-tap-highlight-color: transparent; line-height: normal; font-weight: 400; text-align: left; box-sizing: content-box; direction: ltr; }
li div { padding-top: 0px; }
blockquote { margin: 1rem 0px; }
li .mathjax-block, li p { margin: 0.5rem 0px; }
li blockquote { margin: 1rem 0px; }
li { margin: 0px; position: relative; }
blockquote > :last-child { margin-bottom: 0px; }
blockquote > :first-child, li > :first-child { margin-top: 0px; }
.footnotes-area { color: rgb(136, 136, 136); margin-top: 0.714rem; padding-bottom: 0.143rem; white-space: normal; }
#write .footnote-line { white-space: pre-wrap; }
@media print {
body, html { border: 1px solid transparent; height: 99%; break-after: avoid; break-before: avoid; font-variant-ligatures: no-common-ligatures; }
2022-07-02 04:18:12 +00:00
#write { margin-top: 0px; padding-top: 0px; border-color: transparent !important; padding-bottom: 0px !important; }
2022-06-02 06:36:30 +00:00
.typora-export * { -webkit-print-color-adjust: exact; }
.typora-export #write { break-after: avoid; }
.typora-export #write::after { height: 0px; }
.is-mac table { break-inside: avoid; }
.typora-export-show-outline .typora-export-sidebar { display: none; }
}
.footnote-line { margin-top: 0.714em; font-size: 0.7em; }
a img, img a { cursor: pointer; }
pre.md-meta-block { font-size: 0.8rem; min-height: 0.8rem; white-space: pre-wrap; background: rgb(204, 204, 204); display: block; overflow-x: hidden; }
p > .md-image:only-child:not(.md-img-error) img, p > img:only-child { display: block; margin: auto; }
#write.first-line-indent p > .md-image:only-child:not(.md-img-error) img { left: -2em; position: relative; }
p > .md-image:only-child { display: inline-block; width: 100%; }
#write .MathJax_Display { margin: 0.8em 0px 0px; }
.md-math-block { width: 100%; }
.md-math-block:not(:empty)::after { display: none; }
.MathJax_ref { fill: currentcolor; }
[contenteditable="true"]:active, [contenteditable="true"]:focus, [contenteditable="false"]:active, [contenteditable="false"]:focus { outline: 0px; box-shadow: none; }
.md-task-list-item { position: relative; list-style-type: none; }
.task-list-item.md-task-list-item { padding-left: 0px; }
.md-task-list-item > input { position: absolute; top: 0px; left: 0px; margin-left: -1.2em; margin-top: calc(1em - 10px); border: none; }
.math { font-size: 1rem; }
.md-toc { min-height: 3.58rem; position: relative; font-size: 0.9rem; border-radius: 10px; }
.md-toc-content { position: relative; margin-left: 0px; }
.md-toc-content::after, .md-toc::after { display: none; }
.md-toc-item { display: block; color: rgb(65, 131, 196); }
.md-toc-item a { text-decoration: none; }
.md-toc-inner:hover { text-decoration: underline; }
.md-toc-inner { display: inline-block; cursor: pointer; }
.md-toc-h1 .md-toc-inner { margin-left: 0px; font-weight: 700; }
.md-toc-h2 .md-toc-inner { margin-left: 2em; }
.md-toc-h3 .md-toc-inner { margin-left: 4em; }
.md-toc-h4 .md-toc-inner { margin-left: 6em; }
.md-toc-h5 .md-toc-inner { margin-left: 8em; }
.md-toc-h6 .md-toc-inner { margin-left: 10em; }
@media screen and (max-width: 48em) {
.md-toc-h3 .md-toc-inner { margin-left: 3.5em; }
.md-toc-h4 .md-toc-inner { margin-left: 5em; }
.md-toc-h5 .md-toc-inner { margin-left: 6.5em; }
.md-toc-h6 .md-toc-inner { margin-left: 8em; }
}
a.md-toc-inner { font-size: inherit; font-style: inherit; font-weight: inherit; line-height: inherit; }
.footnote-line a:not(.reversefootnote) { color: inherit; }
2022-07-02 04:18:12 +00:00
.reversefootnote { font-family: ui-monospace, sans-serif; }
2022-06-02 06:36:30 +00:00
.md-attr { display: none; }
.md-fn-count::after { content: "."; }
code, pre, samp, tt { font-family: var(--monospace); }
kbd { margin: 0px 0.1em; padding: 0.1em 0.6em; font-size: 0.8em; color: rgb(36, 39, 41); background: rgb(255, 255, 255); border: 1px solid rgb(173, 179, 185); border-radius: 3px; box-shadow: rgba(12, 13, 14, 0.2) 0px 1px 0px, rgb(255, 255, 255) 0px 0px 0px 2px inset; white-space: nowrap; vertical-align: middle; }
.md-comment { color: rgb(162, 127, 3); opacity: 0.6; font-family: var(--monospace); }
code { text-align: left; vertical-align: initial; }
a.md-print-anchor { white-space: pre !important; border-width: initial !important; border-style: none !important; border-color: initial !important; display: inline-block !important; position: absolute !important; width: 1px !important; right: 0px !important; outline: 0px !important; background: 0px 0px !important; text-decoration: initial !important; text-shadow: initial !important; }
.os-windows.monocolor-emoji .md-emoji { font-family: "Segoe UI Symbol", sans-serif; }
.md-diagram-panel > svg { max-width: 100%; }
[lang="flow"] svg, [lang="mermaid"] svg { max-width: 100%; height: auto; }
[lang="mermaid"] .node text { font-size: 1rem; }
table tr th { border-bottom: 0px; }
video { max-width: 100%; display: block; margin: 0px auto; }
iframe { max-width: 100%; width: 100%; border: none; }
.highlight td, .highlight tr { border: 0px; }
mark { background: rgb(255, 255, 0); color: rgb(0, 0, 0); }
.md-html-inline .md-plain, .md-html-inline strong, mark .md-inline-math, mark strong { color: inherit; }
.md-expand mark .md-meta { opacity: 0.3 !important; }
mark .md-meta { color: rgb(0, 0, 0); }
@media print {
.typora-export h1, .typora-export h2, .typora-export h3, .typora-export h4, .typora-export h5, .typora-export h6 { break-inside: avoid; }
}
.md-diagram-panel .messageText { stroke: none !important; }
.md-diagram-panel .start-state { fill: var(--node-fill); }
.md-diagram-panel .edgeLabel rect { opacity: 1 !important; }
.md-fences.md-fences-math { font-size: 1em; }
.md-fences-advanced:not(.md-focus) { padding: 0px; white-space: nowrap; border: 0px; }
.md-fences-advanced:not(.md-focus) { background: inherit; }
.typora-export-show-outline .typora-export-content { max-width: 1440px; margin: auto; display: flex; flex-direction: row; }
.typora-export-sidebar { width: 300px; font-size: 0.8rem; margin-top: 80px; margin-right: 18px; }
.typora-export-show-outline #write { --webkit-flex:2; flex: 2 1 0%; }
.typora-export-sidebar .outline-content { position: fixed; top: 0px; max-height: 100%; overflow: hidden auto; padding-bottom: 30px; padding-top: 60px; width: 300px; }
@media screen and (max-width: 1024px) {
.typora-export-sidebar, .typora-export-sidebar .outline-content { width: 240px; }
}
@media screen and (max-width: 800px) {
.typora-export-sidebar { display: none; }
}
.outline-content li, .outline-content ul { margin-left: 0px; margin-right: 0px; padding-left: 0px; padding-right: 0px; list-style: none; }
.outline-content ul { margin-top: 0px; margin-bottom: 0px; }
.outline-content strong { font-weight: 400; }
.outline-expander { width: 1rem; height: 1.42857rem; position: relative; display: table-cell; vertical-align: middle; cursor: pointer; padding-left: 4px; }
.outline-expander::before { content: ""; position: relative; font-family: Ionicons; display: inline-block; font-size: 8px; vertical-align: middle; }
.outline-item { padding-top: 3px; padding-bottom: 3px; cursor: pointer; }
.outline-expander:hover::before { content: ""; }
.outline-h1 > .outline-item { padding-left: 0px; }
.outline-h2 > .outline-item { padding-left: 1em; }
.outline-h3 > .outline-item { padding-left: 2em; }
.outline-h4 > .outline-item { padding-left: 3em; }
.outline-h5 > .outline-item { padding-left: 4em; }
.outline-h6 > .outline-item { padding-left: 5em; }
.outline-label { cursor: pointer; display: table-cell; vertical-align: middle; text-decoration: none; color: inherit; }
.outline-label:hover { text-decoration: underline; }
.outline-item:hover { border-color: rgb(245, 245, 245); background-color: var(--item-hover-bg-color); }
.outline-item:hover { margin-left: -28px; margin-right: -28px; border-left: 28px solid transparent; border-right: 28px solid transparent; }
.outline-item-single .outline-expander::before, .outline-item-single .outline-expander:hover::before { display: none; }
.outline-item-open > .outline-item > .outline-expander::before { content: ""; }
.outline-children { display: none; }
.info-panel-tab-wrapper { display: none; }
.outline-item-open > .outline-children { display: block; }
.typora-export .outline-item { padding-top: 1px; padding-bottom: 1px; }
.typora-export .outline-item:hover { margin-right: -8px; border-right: 8px solid transparent; }
.typora-export .outline-expander::before { content: "+"; font-family: inherit; top: -1px; }
.typora-export .outline-expander:hover::before, .typora-export .outline-item-open > .outline-item > .outline-expander::before { content: ""; }
.typora-export-collapse-outline .outline-children { display: none; }
.typora-export-collapse-outline .outline-item-open > .outline-children, .typora-export-no-collapse-outline .outline-children { display: block; }
.typora-export-no-collapse-outline .outline-expander::before { content: "" !important; }
.typora-export-show-outline .outline-item-active > .outline-item .outline-label { font-weight: 700; }
.md-inline-math-container mjx-container { zoom: 0.95; }
2022-11-24 12:14:44 +00:00
mjx-container { break-inside: avoid; }
2022-06-02 06:36:30 +00:00
2022-07-04 06:50:37 +00:00
.CodeMirror { height: auto; }
.CodeMirror.cm-s-inner { background: inherit; }
.CodeMirror-scroll { overflow: auto hidden; z-index: 3; }
.CodeMirror-gutter-filler, .CodeMirror-scrollbar-filler { background-color: rgb(255, 255, 255); }
.CodeMirror-gutters { border-right: 1px solid rgb(221, 221, 221); background: inherit; white-space: nowrap; }
.CodeMirror-linenumber { padding: 0px 3px 0px 5px; text-align: right; color: rgb(153, 153, 153); }
.cm-s-inner .cm-keyword { color: rgb(119, 0, 136); }
.cm-s-inner .cm-atom, .cm-s-inner.cm-atom { color: rgb(34, 17, 153); }
.cm-s-inner .cm-number { color: rgb(17, 102, 68); }
.cm-s-inner .cm-def { color: rgb(0, 0, 255); }
.cm-s-inner .cm-variable { color: rgb(0, 0, 0); }
.cm-s-inner .cm-variable-2 { color: rgb(0, 85, 170); }
.cm-s-inner .cm-variable-3 { color: rgb(0, 136, 85); }
.cm-s-inner .cm-string { color: rgb(170, 17, 17); }
.cm-s-inner .cm-property { color: rgb(0, 0, 0); }
.cm-s-inner .cm-operator { color: rgb(152, 26, 26); }
.cm-s-inner .cm-comment, .cm-s-inner.cm-comment { color: rgb(170, 85, 0); }
.cm-s-inner .cm-string-2 { color: rgb(255, 85, 0); }
.cm-s-inner .cm-meta { color: rgb(85, 85, 85); }
.cm-s-inner .cm-qualifier { color: rgb(85, 85, 85); }
.cm-s-inner .cm-builtin { color: rgb(51, 0, 170); }
.cm-s-inner .cm-bracket { color: rgb(153, 153, 119); }
.cm-s-inner .cm-tag { color: rgb(17, 119, 0); }
.cm-s-inner .cm-attribute { color: rgb(0, 0, 204); }
.cm-s-inner .cm-header, .cm-s-inner.cm-header { color: rgb(0, 0, 255); }
.cm-s-inner .cm-quote, .cm-s-inner.cm-quote { color: rgb(0, 153, 0); }
.cm-s-inner .cm-hr, .cm-s-inner.cm-hr { color: rgb(153, 153, 153); }
.cm-s-inner .cm-link, .cm-s-inner.cm-link { color: rgb(0, 0, 204); }
.cm-negative { color: rgb(221, 68, 68); }
.cm-positive { color: rgb(34, 153, 34); }
.cm-header, .cm-strong { font-weight: 700; }
.cm-del { text-decoration: line-through; }
.cm-em { font-style: italic; }
.cm-link { text-decoration: underline; }
.cm-error { color: red; }
.cm-invalidchar { color: red; }
.cm-constant { color: rgb(38, 139, 210); }
.cm-defined { color: rgb(181, 137, 0); }
div.CodeMirror span.CodeMirror-matchingbracket { color: rgb(0, 255, 0); }
div.CodeMirror span.CodeMirror-nonmatchingbracket { color: rgb(255, 34, 34); }
.cm-s-inner .CodeMirror-activeline-background { background: inherit; }
.CodeMirror { position: relative; overflow: hidden; }
.CodeMirror-scroll { height: 100%; outline: 0px; position: relative; box-sizing: content-box; background: inherit; }
.CodeMirror-sizer { position: relative; }
.CodeMirror-gutter-filler, .CodeMirror-hscrollbar, .CodeMirror-scrollbar-filler, .CodeMirror-vscrollbar { position: absolute; z-index: 6; display: none; outline: 0px; }
.CodeMirror-vscrollbar { right: 0px; top: 0px; overflow: hidden; }
.CodeMirror-hscrollbar { bottom: 0px; left: 0px; overflow: auto hidden; }
.CodeMirror-scrollbar-filler { right: 0px; bottom: 0px; }
.CodeMirror-gutter-filler { left: 0px; bottom: 0px; }
.CodeMirror-gutters { position: absolute; left: 0px; top: 0px; padding-bottom: 10px; z-index: 3; overflow-y: hidden; }
.CodeMirror-gutter { white-space: normal; height: 100%; box-sizing: content-box; padding-bottom: 30px; margin-bottom: -32px; display: inline-block; }
.CodeMirror-gutter-wrapper { position: absolute; z-index: 4; background: 0px 0px !important; border: none !important; }
.CodeMirror-gutter-background { position: absolute; top: 0px; bottom: 0px; z-index: 4; }
.CodeMirror-gutter-elt { position: absolute; cursor: default; z-index: 4; }
.CodeMirror-lines { cursor: text; }
.CodeMirror pre { border-radius: 0px; border-width: 0px; background: 0px 0px; font-family: inherit; font-size: inherit; margin: 0px; white-space: pre; overflow-wrap: normal; color: inherit; z-index: 2; position: relative; overflow: visible; }
.CodeMirror-wrap pre { overflow-wrap: break-word; white-space: pre-wrap; word-break: normal; }
.CodeMirror-code pre { border-right: 30px solid transparent; width: fit-content; }
.CodeMirror-wrap .CodeMirror-code pre { border-right: none; width: auto; }
.CodeMirror-linebackground { position: absolute; inset: 0px; z-index: 0; }
.CodeMirror-linewidget { position: relative; z-index: 2; overflow: auto; }
.CodeMirror-wrap .CodeMirror-scroll { overflow-x: hidden; }
.CodeMirror-measure { position: absolute; width: 100%; height: 0px; overflow: hidden; visibility: hidden; }
.CodeMirror-measure pre { position: static; }
.CodeMirror div.CodeMirror-cursor { position: absolute; visibility: hidden; border-right: none; width: 0px; }
.CodeMirror div.CodeMirror-cursor { visibility: hidden; }
.CodeMirror-focused div.CodeMirror-cursor { visibility: inherit; }
.cm-searching { background: rgba(255, 255, 0, 0.4); }
span.cm-underlined { text-decoration: underline; }
span.cm-strikethrough { text-decoration: line-through; }
.cm-tw-syntaxerror { color: rgb(255, 255, 255); background-color: rgb(153, 0, 0); }
.cm-tw-deleted { text-decoration: line-through; }
.cm-tw-header5 { font-weight: 700; }
.cm-tw-listitem:first-child { padding-left: 10px; }
.cm-tw-box { border-style: solid; border-right-width: 1px; border-bottom-width: 1px; border-left-width: 1px; border-color: inherit; border-top-width: 0px !important; }
.cm-tw-underline { text-decoration: underline; }
@media print {
.CodeMirror div.CodeMirror-cursor { visibility: hidden; }
}
2022-06-02 06:36:30 +00:00
:root {
--side-bar-bg-color: #fafafa;
--control-text-color: #777;
}
@include-when-export url(https://fonts.loli.net/css?family=Open+Sans:400italic,700italic,700,400&subset=latin,latin-ext);
/* open-sans-regular - latin-ext_latin */
/* open-sans-italic - latin-ext_latin */
/* open-sans-700 - latin-ext_latin */
/* open-sans-700italic - latin-ext_latin */
html {
font-size: 16px;
-webkit-font-smoothing: antialiased;
}
body {
font-family: "Open Sans","Clear Sans", "Helvetica Neue", Helvetica, Arial, 'Segoe UI Emoji', sans-serif;
color: rgb(51, 51, 51);
line-height: 1.6;
}
#write {
max-width: 860px;
margin: 0 auto;
padding: 30px;
padding-bottom: 100px;
}
@media only screen and (min-width: 1400px) {
#write {
max-width: 1024px;
}
}
@media only screen and (min-width: 1800px) {
#write {
max-width: 1200px;
}
}
#write > ul:first-child,
#write > ol:first-child{
margin-top: 30px;
}
a {
color: #4183C4;
}
h1,
h2,
h3,
h4,
h5,
h6 {
position: relative;
margin-top: 1rem;
margin-bottom: 1rem;
font-weight: bold;
line-height: 1.4;
cursor: text;
}
h1:hover a.anchor,
h2:hover a.anchor,
h3:hover a.anchor,
h4:hover a.anchor,
h5:hover a.anchor,
h6:hover a.anchor {
text-decoration: none;
}
h1 tt,
h1 code {
font-size: inherit;
}
h2 tt,
h2 code {
font-size: inherit;
}
h3 tt,
h3 code {
font-size: inherit;
}
h4 tt,
h4 code {
font-size: inherit;
}
h5 tt,
h5 code {
font-size: inherit;
}
h6 tt,
h6 code {
font-size: inherit;
}
h1 {
font-size: 2.25em;
line-height: 1.2;
border-bottom: 1px solid #eee;
}
h2 {
font-size: 1.75em;
line-height: 1.225;
border-bottom: 1px solid #eee;
}
/*@media print {
.typora-export h1,
.typora-export h2 {
border-bottom: none;
padding-bottom: initial;
}
.typora-export h1::after,
.typora-export h2::after {
content: "";
display: block;
height: 100px;
margin-top: -96px;
border-top: 1px solid #eee;
}
}*/
h3 {
font-size: 1.5em;
line-height: 1.43;
}
h4 {
font-size: 1.25em;
}
h5 {
font-size: 1em;
}
h6 {
font-size: 1em;
color: #777;
}
p,
blockquote,
ul,
ol,
dl,
table{
margin: 0.8em 0;
}
li>ol,
li>ul {
margin: 0 0;
}
hr {
height: 2px;
padding: 0;
margin: 16px 0;
background-color: #e7e7e7;
border: 0 none;
overflow: hidden;
box-sizing: content-box;
}
li p.first {
display: inline-block;
}
ul,
ol {
padding-left: 30px;
}
ul:first-child,
ol:first-child {
margin-top: 0;
}
ul:last-child,
ol:last-child {
margin-bottom: 0;
}
blockquote {
border-left: 4px solid #dfe2e5;
padding: 0 15px;
color: #777777;
}
blockquote blockquote {
padding-right: 0;
}
table {
padding: 0;
word-break: initial;
}
table tr {
border: 1px solid #dfe2e5;
margin: 0;
padding: 0;
}
table tr:nth-child(2n),
thead {
background-color: #f8f8f8;
}
table th {
font-weight: bold;
border: 1px solid #dfe2e5;
border-bottom: 0;
margin: 0;
padding: 6px 13px;
}
table td {
border: 1px solid #dfe2e5;
margin: 0;
padding: 6px 13px;
}
table th:first-child,
table td:first-child {
margin-top: 0;
}
table th:last-child,
table td:last-child {
margin-bottom: 0;
}
.CodeMirror-lines {
padding-left: 4px;
}
.code-tooltip {
box-shadow: 0 1px 1px 0 rgba(0,28,36,.3);
border-top: 1px solid #eef2f2;
}
.md-fences,
code,
tt {
border: 1px solid #e7eaed;
background-color: #f8f8f8;
border-radius: 3px;
padding: 0;
padding: 2px 4px 0px 4px;
font-size: 0.9em;
}
code {
background-color: #f3f4f4;
padding: 0 2px 0 2px;
}
.md-fences {
margin-bottom: 15px;
margin-top: 15px;
padding-top: 8px;
padding-bottom: 6px;
}
.md-task-list-item > input {
margin-left: -1.3em;
}
@media print {
html {
font-size: 13px;
}
pre {
page-break-inside: avoid;
word-wrap: break-word;
}
}
.md-fences {
background-color: #f8f8f8;
}
#write pre.md-meta-block {
padding: 1rem;
font-size: 85%;
line-height: 1.45;
background-color: #f7f7f7;
border: 0;
border-radius: 3px;
color: #777777;
margin-top: 0 !important;
}
.mathjax-block>.code-tooltip {
bottom: .375rem;
}
.md-mathjax-midline {
background: #fafafa;
}
#write>h3.md-focus:before{
left: -1.5625rem;
top: .375rem;
}
#write>h4.md-focus:before{
left: -1.5625rem;
top: .285714286rem;
}
#write>h5.md-focus:before{
left: -1.5625rem;
top: .285714286rem;
}
#write>h6.md-focus:before{
left: -1.5625rem;
top: .285714286rem;
}
.md-image>.md-meta {
/*border: 1px solid #ddd;*/
border-radius: 3px;
padding: 2px 0px 0px 4px;
font-size: 0.9em;
color: inherit;
}
.md-tag {
color: #a7a7a7;
opacity: 1;
}
.md-toc {
margin-top:20px;
padding-bottom:20px;
}
.sidebar-tabs {
border-bottom: none;
}
#typora-quick-open {
border: 1px solid #ddd;
background-color: #f8f8f8;
}
#typora-quick-open-item {
background-color: #FAFAFA;
border-color: #FEFEFE #e5e5e5 #e5e5e5 #eee;
border-style: solid;
border-width: 1px;
}
/** focus mode */
.on-focus-mode blockquote {
border-left-color: rgba(85, 85, 85, 0.12);
}
header, .context-menu, .megamenu-content, footer{
font-family: "Segoe UI", "Arial", sans-serif;
}
.file-node-content:hover .file-node-icon,
.file-node-content:hover .file-node-open-state{
visibility: visible;
}
.mac-seamless-mode #typora-sidebar {
background-color: #fafafa;
background-color: var(--side-bar-bg-color);
}
.md-lang {
color: #b4654d;
}
/*.html-for-mac {
--item-hover-bg-color: #E6F0FE;
}*/
#md-notification .btn {
border: 0;
}
.dropdown-menu .divider {
border-color: #e5e5e5;
opacity: 0.4;
}
.ty-preferences .window-content {
background-color: #fafafa;
}
.ty-preferences .nav-group-item.active {
color: white;
background: #999;
}
.menu-item-container a.menu-style-btn {
background-color: #f5f8fa;
background-image: linear-gradient( 180deg , hsla(0, 0%, 100%, 0.8), hsla(0, 0%, 100%, 0));
}
2022-06-08 07:52:50 +00:00
</style><title>视频监控系统开发及使用手册</title>
2021-07-10 09:47:51 +00:00
</head>
2022-06-02 06:36:30 +00:00
<body class='typora-export os-windows typora-export-show-outline typora-export-collapse-outline'><div class='typora-export-content'>
2022-11-26 08:35:55 +00:00
<div class="typora-export-sidebar"><div class="outline-content"><li class="outline-item-wrapper outline-h2"><div class="outline-item"><span class="outline-expander"></span><a class="outline-label" href="#0-前言说明">0 前言说明</a></div><ul class="outline-children"><li class="outline-item-wrapper outline-h3 outline-item-single"><div class="outline-item"><span class="outline-expander"></span><a class="outline-label" href="#01-系统说明">0.1 系统说明</a></div><ul class="outline-children"></ul></li><li class="outline-item-wrapper outline-h3 outline-item-single"><div class="outline-item"><span class="outline-expander"></span><a class="outline-label" href="#02-特别说明">0.2 特别说明</a></div><ul class="outline-children"></ul></li><li class="outline-item-wrapper outline-h3 outline-item-single"><div class="outline-item"><span class="outline-expander"></span><a class="outline-label" href="#03-相关站点">0.3 相关站点</a></div><ul class="outline-children"></ul></li><li class="outline-item-wrapper outline-h3"><div class="outline-item"><span class="outline-expander"></span><a class="outline-label" href="#04-功能特点">0.4 功能特点</a></div><ul class="outline-children"><li class="outline-item-wrapper outline-h4 outline-item-single"><div class="outline-item"><span class="outline-expander"></span><a class="outline-label" href="#041-软件模块">0.4.1 软件模块</a></div><ul class="outline-children"></ul></li><li class="outline-item-wrapper outline-h4 outline-item-single"><div class="outline-item"><span class="outline-expander"></span><a class="outline-label" href="#042-基础功能">0.4.2 基础功能</a></div><ul class="outline-children"></ul></li><li class="outline-item-wrapper outline-h4 outline-item-single"><div class="outline-item"><span class="outline-expander"></span><a class="outline-label" href="#043-特色功能">0.4.3 特色功能</a></div><ul class="outline-children"></ul></li></ul></li><li class="outline-item-wrapper outline-h3 outline-item-single"><div class="outline-item"><span class="outline-expander"></span><a class="outline-label" href="#05-目录说明">0.5 目录说明</a></div><ul class="outline-children"></ul></li><li class="outline-item-wrapper outline-h3"><div class="outline-item"><span class="outline-expander"></span><a class="outline-label" href="#06-编译说明">0.6 编译说明</a></div><ul class="outline-children"><li class="outline-item-wrapper outline-h4 outline-item-single"><div class="outline-item"><span class="outline-expander"></span><a class="outline-label" href="#061-特别提示">0.6.1 特别提示</a></div><ul class="outline-children"></ul></li><li class="outline-item-wrapper outline-h4 outline-item-single"><div class="outline-item"><span class="outline-expander"></span><a class="outline-label" href="#062-注意事项">0.6.2 注意事项</a></div><ul class="outline-children"></ul></li><li class="outline-item-wrapper outline-h4 outline-item-single"><div class="outline-item"><span class="outline-expander"></span><a class="outline-label" href="#063-离线地图">0.6.3 离线地图</a></div><ul class="outline-children"></ul></li></ul></li><li class="outline-item-wrapper outline-h3"><div class="outline-item"><span class="outline-expander"></span><a class="outline-label" href="#07-视频格式">0.7 视频格式</a></div><ul class="outline-children"><li class="outline-item-wrapper outline-h4 outline-item-single"><div class="outline-item"><span class="outline-expander"></span><a class="outline-label" href="#071-usb摄像头">0.7.1 USB摄像头</a></div><ul class="outline-children"></ul></li><li class="outline-item-wrapper outline-h4 outline-item-single"><div class="outline-item"><span class="outline-expander"></span><a class="outline-label" href="#072-中央卫视">0.7.2 中央卫视</a></div><ul class="outline-children"></ul></li><li class="outline-item-wrapper outline-h4 outline-item-single"><div class="outline-item"><span class="outline-expander"></span><a class="outline-label" href="#073-视频文件">0.7.3 视频文件</a></div><ul class="outline-children"></u
<a href='https://pan.baidu.com/s/13LDRu6mXC6gaADtrGprNVA' target='_blank' class='url'>https://pan.baidu.com/s/13LDRu6mXC6gaADtrGprNVA</a><span>  提取码: ujm7。</span></li><li><span>如果是64位的qt则对应的dll时候拷贝dll_ffmpeg4_64目录下的。</span></li><li><span>如果使用的ffmpeg3则对应dll目录就是dll_ffmpeg3在core_videoffmpeg.pri文件中可以看到具体启用的是ffmpeg3支持XP还是ffmpeg4不支持XP默认是ffmpeg4。</span></li><li><span>如果编译运行提示miniblink文件不存在请先拷贝则说明你当前用的Qt版本没有浏览器模块要么没安装要么不支持你也不用担心啥此时自动切换用的miniblink浏览器内核你还需要将ffmpeg库下载的网盘的地方找到dll_miniblink.zip下载解压到可执行文件同一目录即可。</span></li><li><span>系统中所有的图标都采用的图形字体对照表在doc目录下的FontAwesome.png、FontAliBaBa.png对应图形字体类IconHelper中加载的图形字体后期如果还有增加的其他图形字体也是放在这里一个类支持多种图形字体通过不同的值范围自动设置。</span></li><li><span>如果发现地图打不开或者提示秘钥文件丢失请先确认file目录下的所有文件有没有拷贝过去。</span></li><li><span>如果是用vs+qt可能报错 error LNK2026解决办法详细见本文档中13其他说明/13.5环境使用qt+vs。</span></li><li><span>默认用户名admin 密码admin。</span></li><li><span>系统配置参数在加载的时候会对节点值进行过滤判断如果为空会自动用初始值生成新的配置文件如果不想要显示版权所有公司可以填xxx而不是删掉整个值。</span></li><li><span>如果是用vlc推流的rtsp地址比如 rtsp://:8554/aabb由于vlc推流默认写死的采用的udp协议所以监控系统也必须在系统设置中通信方式选择udp才行默认tcp</span></li></ol><h4 id='063-离线地图'><span>0.6.3 离线地图</span></h4><ol start='' ><li><span>离线地图可以用网上的瓦片地图下载器下载百度的离线地图放到对应目录即可。</span></li><li><span>也可以直接下载网盘中已经下载好的上海市的离线地图。</span></li><li><span>下载地址:</span><a href='https://pan.baidu.com/s/1ZxG-oyUKe286LPMPxOrO2A' target='_blank' class='url'>https://pan.baidu.com/s/1ZxG-oyUKe286LPMPxOrO2A</a><span> 提取码o05q 文件名称bin_map_tiles.tar.xz</span></li></ol><p><strong><span>使用说明</span></strong></p><ol start='' ><li><span>将压缩包下的两个文件夹复制到对应可执行文件下的config文件夹下和map.js文件同一级目录。</span></li><li><span>tiles文件夹是街道图tiles_hybrid文件夹是卫星图tiles_self是路网图路网图和卫星图合并就是混合图。</span></li><li><span>默认提供的是上海市徐汇区的瓦片地图,如果自己用万能地图下载器下载的百度地图的瓦片文件,也可以对应替换就行。</span></li><li><span>要注意的是格式默认是jpg如果下载的瓦片地图格式是png则需要打开config文件夹下的map_load.js文件将.jpg改成.png保存即可。</span></li></ol><h3 id='07-视频格式'><span>0.7 视频格式</span></h3><h4 id='071-usb摄像头'><span>0.7.1 USB摄像头</span></h4><ol start='' ><li><span>下面假定USB摄像头的设备名为 USB2.0 PC CAMERA。</span></li><li><span>win系统如何查看设备名见本文档中13其他说明/13.7打开USB摄像头。</span></li><li><span>linux系统查看设备名直接执行命令 ls /dev/video * 即可,一般对应的设备名是 /dev/video0。</span></li><li><span>写法1video=USB2.0 PC CAMERA这种写法默认按照640x480分辨率打开摄像头。</span></li><li><span>写法2video=USB2.0 PC CAMERA|1280x720|30这种写法按照指定的分辨率1280x720以及采集帧率30来打开摄像头。</span></li><li><span>写法3video=/dev/video0这种是对应linux系统<E7B3BB><E7BB9F>
2022-11-24 12:14:44 +00:00
</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">13</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-comment">//中文皮肤名称对应样式表文件</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">14</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable">QStringList</span> <span class="cm-variable">files</span>;</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">15</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">if</span> (<span class="cm-variable">files</span>.<span class="cm-variable">count</span>() <span class="cm-operator">==</span> <span class="cm-number">0</span>) {</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">16</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; &nbsp;<span class="cm-variable">files</span> <span class="cm-operator">&lt;&lt;</span> <span class="cm-string">":/qss/blackblue.css"</span> <span class="cm-operator">&lt;&lt;</span> <span class="cm-string">":/qss/blacksoft.css"</span> <span class="cm-operator">&lt;&lt;</span> <span class="cm-string">":/qss/blackvideo.css"</span>;</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">17</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; &nbsp;<span class="cm-variable">files</span> <span class="cm-operator">&lt;&lt;</span> <span class="cm-string">":/qss/darkblack.css"</span> <span class="cm-operator">&lt;&lt;</span> <span class="cm-string">":/qss/darkblue.css"</span> <span class="cm-operator">&lt;&lt;</span> <span class="cm-string">":/qss/darkgray.css"</span>;</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">18</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; &nbsp;<span class="cm-variable">files</span> <span class="cm-operator">&lt;&lt;</span> <span class="cm-string">":/qss/flatblack.css"</span> <span class="cm-operator">&lt;&lt;</span> <span class="cm-string">":/qss/flatblue.css"</span> <span class="cm-operator">&lt;&lt;</span> <span class="cm-string">":/qss/flatgray.css"</span>;</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">19</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; &nbsp;<span class="cm-variable">files</span> <span class="cm-operator">&lt;&lt;</span> <span class="cm-string">":/qss/lightblack.css"</span> <span class="cm-operator">&lt;&lt;</span> <span class="cm-string">":/qss/lightblue.css"</span> <span class="cm-operator">&lt;&lt;</span> <span class="cm-string">":/qss/lightgray.css"</span>;</s
</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">24</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-variable">styleNames</span> <span class="cm-operator">=</span> <span class="cm-variable">names</span>;</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">25</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-variable">styleFiles</span> <span class="cm-operator">=</span> <span class="cm-variable">files</span>;</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt CodeMirror-linenumber-show" style="left: 0px; width: 27px;">26</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">}</span></pre></div></div></div></div></div></div><div style="position: absolute; height: 0px; width: 1px; border-bottom: 0px solid transparent; top: 599px;"></div><div class="CodeMirror-gutters" style="height: 599px;"><div class="CodeMirror-gutter CodeMirror-linenumbers" style="width: 35px;"></div></div></div></div></pre><p><strong><span>V20211111</span></strong></p><ol start='' ><li><span>ONVIF组件增加图片参数范围获取之前默认0-255有些设备是0-100 0-128之类的获取后设置到滑动条范围。</span></li><li><span>ONVIF组件增加网络参数设置比如IP地址子网掩码、网关地址、DNS设置等。</span></li><li><span>ONVIF组件将结构体定义统一移到一个头文件onvifstruct.h方便后期拓展管理。</span></li><li><span>预置位模块,调用、添加(调用)、删除三种功能,改成了以三个按钮的形式加到每个预置位信息的后面直接单击使用。之前是先选中预置位所在行,然后单击下面的按钮。</span></li><li><span>通道轮询全部移动单独的悬停的模块。</span></li><li><span>视频面板窗体指针改成了全局变量,多处需要引用。</span></li><li><span>修复1通道轮询后再次启动程序无法正确加载通道面板布局的BUG。</span></li><li><span>修复底部通道切换部分样式效果悬停时候颜色不正确的BUG。改成了取报警图标颜色和已处理颜色。</span></li><li><span>路径规划模块增加模拟轨迹设备自动旋转角度移动。</span></li><li><span>路径规划模块模拟轨迹增加移动间隔下拉框选择。</span></li><li><span>修复Qt4对应webkit模块不支持返回数组的问题改成字符串拼接用 ; 符隔开。</span></li><li><span>修复Qt4对应webkit模块不支持路径规划的BUG因为开启了实时路况属性。</span></li><li><span>路径规划增加绘制实时轨迹线条,不同颜色显示。</span></li></ol><p><strong><span>V20211101</span></strong></p><ol start='' ><li><span>修正开启轮询后关闭所有视频通道不弹出提示信息。</span></li><li><span>所有信息框增加阴影边框区分突出显示,并跟随系统换肤自动更新边框阴影。</span></li><li><span>修正视频轮询分隔符,将|改成;因为如果是竖杠遇到带有参数的url则会出错。</span></li><li><span>将设备图片统一存放到config/device目录之前在config目录下随着越来越多非常凌乱。</span></li><li><span>修复之前通过信号执行通道切换对应文字显示反了的BUG通道1交换到通道2新的通道2应该显示之前通道1的文本</span></li><li><span>将鼠标按下两个通道交换的处理代码,复用信号槽切换通道的函数。</span></li><li><span>将视频监控布局切<EFBFBD>
2022-06-02 06:36:30 +00:00
<span> </span><img src="snap/1-1-2.jpg" referrerpolicy="no-referrer"></p><p><span>系统启动后首先会弹出用户登录界面从用户姓名的下拉框选择用户名然后输入密码默认用户名密码都是admin单击登录按钮密码正确则会进入到系统主界面错误会弹出提示错误超过三次自动关闭需要重新打开软件。</span></p><p><span>在登录界面可以勾选是否记住密码,是否自动登录,如果勾选了记住密码,则下次启用软件会自动填入最后用户的密码,勾选了自动登录(以最后的用户信息作为当前登录用户)则启动后直接进入主界面。如果开启了自动登录,不会弹出登录界面,可以在系统设置中关闭自动登录和记住密码。</span></p><h3 id='12-用户退出'><span>1.2 用户退出</span></h3><p><span> </span><img src="snap/1-2-1.jpg" referrerpolicy="no-referrer"></p><p><span>在主界面单击右上角的关闭按钮会弹出用户退出界面需要输入密码验证防止误关闭会自动填入登录的用户名密码输入正确才会退出软件。用户登录和退出都内置了超级密码a防止管理员忘记密码。</span></p><h2 id='2-主界面操作'><span>2 主界面操作</span></h2><p><span> </span><img src="snap/2-0-1.jpg" referrerpolicy="no-referrer">
2022-11-24 12:14:44 +00:00
<span> </span><img src="snap/2-0-2.jpg" referrerpolicy="no-referrer"></p><p><span>主界面由顶部主菜单导航、左侧右侧停靠窗体(设备列表、窗口信息、图文警情、悬浮地图、云台控制、设备控制、预置巡航、视频轮询等)、中间视频监控主画面组成,其中左右两侧的停靠窗体可以拉伸宽度,上下停靠窗体之间也可以拉伸高度,每个停靠窗体都可以关闭和悬浮。自动保存布局文件,下次启动自动应用。</span></p><p><strong><span>新增说明</span></strong></p><ul><li><span>2021-5-8主界面改成了停靠窗体模式。</span></li><li><span>拓展性更强,可以任意组合多种子模块。</span></li><li><span>模块可停靠悬浮。</span></li><li><span>在普通模式和全屏模式都有独立的布局文件。</span></li><li><span>不同的工作模式都可对应不同的布局文件。</span></li></ul><h3 id='21-模块显示'><span>2.1 模块显示</span></h3><p><span> </span><img src="snap/2-1-1.jpg" referrerpolicy="no-referrer">
<span> </span><img src="snap/2-1-2.jpg" referrerpolicy="no-referrer"></p><p><span>左侧和右侧的面板可以通过单击面板右上角的关闭按钮来隐藏当隐藏一个面板以后剩余的面板会自动填充布局如果需要重新显示面板则在标题栏鼠标右键就可以对小面板进行显示和隐藏右上角的时间和CPU显示面板可以在系统设置中控制显示隐藏。系统会自动记住最后的布局比如显示的面板和宽高占比下次启动后自动应用。</span></p><p><strong><span>特别说明</span></strong></p><ol start='' ><li><span>在停靠窗体的标题栏鼠标右键也会弹出子窗体的开启菜单,复选框勾选表示显示,悬浮的窗体没有这个特性,一定要是嵌入在主界面中的子窗体标题栏才有。</span></li><li><span>如果是全屏模式,由于没有了标题栏,想要关闭模块的话,需要将其拖动到边缘嵌入主窗体,然后在标题栏鼠标右键菜单中关闭即可。</span></li></ol><h3 id='22-模块拖动'><span>2.2 模块拖动</span></h3><p><span> </span><img src="snap/2-2-1.jpg" referrerpolicy="no-referrer"></p><p><span>面板和面板之间有个分隔条,鼠标移到对应分隔条的地方,会变成可拉动的鼠标指针,此时可以上下左右拉动调整宽高,调整好以后会自动保存宽高比例,下次启动后自动应用最后的配置来显示。</span></p><h3 id='23-视频播放'><span>2.3 视频播放</span></h3><p><span> </span><img src="snap/2-3-1.jpg" referrerpolicy="no-referrer"></p><p><span>视频播放支持多种方式:</span></p><ol start='' ><li><span>双击子节点播放单个摄像机,在当前选中通道处播放。</span></li><li><span>双击父节点播放整个录像机的摄像机,依次排列。</span></li><li><span>按住子节点拖曳到对应通道,播放摄像机。</span></li><li><span>本地文件直接拖曳到通道,自动播放本地文件。</span></li><li><span>启动后自动播放最后通道的视频信息。</span></li><li><span>代码接口提供指定通道播放url。</span></li><li><span>代码接口提供指定两个通道交换,比如报警的时候将某个通道移到最前面显示。</span></li></ol><h3 id='24-视频截图'><span>2.4 视频截图</span></h3><p><span> </span><img src="snap/2-4-1.jpg" referrerpolicy="no-referrer">
<span> </span><img src="snap/2-4-2.jpg" referrerpolicy="no-referrer"></p><p><span>视频截图支持多种方式:</span></p><ol start='' ><li><span>监控通道鼠标右键,弹出菜单选择截图当前视频/截图所有视频。</span></li><li><span>视频面板底部工具栏截图按钮。</span></li><li><span>每个通道悬浮工具条截图按钮。</span></li><li><span>截图默认保存在可执行文件所在目录下的image_normal目录文件名格式ch01_2022-11-24-13-41-24-000.jpg。</span></li><li><span>底部工具栏截图按钮触发截图后会弹出提示抓拍文件后的保存位置。</span></li></ol><h3 id='25-删除视频'><span>2.5 删除视频</span></h3><p><span> </span><img src="snap/2-5-1.jpg" referrerpolicy="no-referrer">
2022-06-02 06:36:30 +00:00
<span> </span><img src="snap/2-5-2.jpg" referrerpolicy="no-referrer"></p><p><span>有多种方法可以删除视频:</span></p><ol start='' ><li><span>鼠标右键删除当前视频。</span></li><li><span>鼠标右键删除所有视频。</span></li><li><span>按住通道画面移出视频监控画面。</span></li><li><span>悬浮条关闭按钮。</span></li></ol><h3 id='26-画面切换'><span>2.6 画面切换</span></h3><p><span> </span><img src="snap/2-6-1.jpg" referrerpolicy="no-referrer"></p><p><span>系统支持多画面切换全屏切换等包括1+4+6+8+9+13+16+25+36+64画面切换如果还需要增加更多的画面比如81+100等可以直接在源码中稍微修改即可。</span></p><ol start='' ><li><span>鼠标右键画面切换。</span></li><li><span>底部左侧画面切换缩略图。</span></li><li><span>快捷键alt+enter全屏。</span></li><li><span>快捷键esc退出全屏。</span></li></ol><p><span>64画面效果图</span>
2022-11-24 12:14:44 +00:00
<span> </span><img src="snap/2-6-2.jpg" referrerpolicy="no-referrer"></p><h3 id='27-声音调节'><span>2.7 声音调节</span></h3><p><span> </span><img src="snap/2-7-1.jpg" referrerpolicy="no-referrer">
<span> </span><img src="snap/2-7-2.jpg" referrerpolicy="no-referrer"></p><p><span>在主界面画面栏右下角,按下声音图标自动弹出声音调节面板,失去焦点自动隐藏,拉动声音滚动条来调节声音大小,还有静音切换。右下角的声音和静音切换是针对所有通道的,单个通道可以在每个通道的悬浮条工具栏中单击静音切换按钮。</span></p><h3 id='28-视频轮询'><span>2.8 视频轮询</span></h3><p><span> </span><img src="snap/2-8-1.jpg" referrerpolicy="no-referrer"></p><p><strong><span>功能说明</span></strong></p><ol start='' ><li><span>开启是否一运行自动轮询。</span></li><li><span>可设置轮询间隔比如5s、10s、30s、60s等。</span></li><li><span>可设置轮询画面类型比如1画面、4画面、9画面、16画面。</span></li><li><span>可选择切换不同的轮询方案。</span></li><li><span>开始轮询和停止轮询。</span></li><li><span>暂停轮询和继续轮询。</span></li></ol><h3 id='29-通道交换'><span>2.9 通道交换</span></h3><p><span> </span><img src="snap/2-9-1.jpg" referrerpolicy="no-referrer"></p><p><span>通道交换功能很常用一般用户喜欢调整自己想要的通道显示到前面或者占据画面的更大部分比如6画面8画面的时候左侧有一个画面占据很大的位置一般这个用来显示重要性最高的实时视频如果需要通道交换则按住通道拖动到另外一个通道上面松开鼠标即可会立即应用瞬间切换这里切记不要移出视频画面外移出去表示删除。</span></p><p><span>本系统也封装了代码中动态控制切换和动态交换具体代码在DeviceThreadUI类中具体全局函数在AppEvent类中。</span></p><pre class="md-fences md-end-block md-fences-with-lineno ty-contain-cm modeLoaded" spellcheck="false" lang="cpp"><div class="CodeMirror cm-s-inner cm-s-null-scroll CodeMirror-wrap" lang="cpp"><div style="overflow: hidden; position: relative; width: 3px; height: 0px; top: 9.51471px; left: 35.9874px;"><textarea autocorrect="off" autocapitalize="off" spellcheck="false" tabindex="0" style="position: absolute; bottom: -1em; padding: 0px; width: 1000px; height: 1em; outline: none;"></textarea></div><div class="CodeMirror-scrollbar-filler" cm-not-content="true"></div><div class="CodeMirror-gutter-filler" cm-not-content="true"></div><div class="CodeMirror-scroll" tabindex="-1"><div class="CodeMirror-sizer" style="margin-left: 28px; margin-bottom: 0px; border-right-width: 0px; padding-right: 0px; padding-bottom: 0px;"><div style="position: relative; top: 0px;"><div class="CodeMirror-lines" role="presentation"><div role="presentation" style="position: relative; outline: none;"><div class="CodeMirror-measure"><pre><span>xxxxxxxxxx</span></pre><div class="CodeMirror-linenumber CodeMirror-gutter-elt"><div>5</div></div></div><div class="CodeMirror-measure"></div><div style="position: relative; z-index: 1;"></div><div class="CodeMirror-code" role="presentation" style=""><div class="CodeMirror-activeline" style="position: relative;"><div class="CodeMirror-activeline-background CodeMirror-linebackground"></div><div class="CodeMirror-gutter-background CodeMirror-activeline-gutter" style="left: -27.9958px; width: 28px;"></div><div class="CodeMirror-gutter-wrapper CodeMirror-activeline-gutter" style="left: -27.9958px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt CodeMirror-linenumber-show" style="left: 0px; width: 19px;">1</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span class="cm-comment">//指定通道显示视频 id从0开始</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -27.9958px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 19px;">2</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span class="cm-variable-3">void</span> <span
</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">8</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-variable">QColor</span> <span class="cm-variable">color</span>; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span class="cm-comment">//文本颜色</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">9</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-variable">QImage</span> <span class="cm-variable">image</span>; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span class="cm-comment">//标签图片</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt CodeMirror-linenumber-show" style="left: 0px; width: 27px;">10</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-variable">QPoint</span> <span class="cm-variable">point</span>; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span class="cm-comment">//标签坐标(位置自定义时候使用)</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">11</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-variable">OsdFormat</span> <span class="cm-variable">format</span>; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span class="cm-comment">//标签格式</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">12</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-variable">OsdPosition</span> <span class="cm-variable">position</span>; &nbsp; &nbsp; &nbsp; <span class="cm-comment">//标签位置</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">13</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text="" cm-zwsp="">
</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">14</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-variable">OsdInfo</span>() {</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">15</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; &nbsp;<span class="cm-variable">name</span> <span class="cm-operator">=</span> <span class="cm-string">"osd"</span>;</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">16</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; &nbsp;<span class="cm-variable">visible</span> <span class="cm-operator">=</span> <span class="cm-atom">true</span>;</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">17</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; &nbsp;<span class="cm-variable">fontSize</span> <span class="cm-operator">=</span> <span class="cm-number">12</span>;</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">18</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; &nbsp;<span class="cm-variable">text</span> <span class="cm-operator">=</span> <span class="cm-string">"视频标签"</span>;</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">19</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text="" cm-zwsp="">
</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt CodeMirror-linenumber-show" style="left: 0px; width: 27px;">20</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; &nbsp;<span class="cm-variable">color</span> <span class="cm-operator">=</span> <span class="cm-string">"#FF0000"</span>;</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">21</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; &nbsp;<span class="cm-variable">image</span> <span class="cm-operator">=</span> <span class="cm-variable">QImage</span>();</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">22</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; &nbsp;<span class="cm-variable">point</span> <span class="cm-operator">=</span> <span class="cm-variable">QPoint</span>(<span class="cm-number">0</span>, <span class="cm-number">0</span>);</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">23</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; &nbsp;<span class="cm-variable">format</span> <span class="cm-operator">=</span> <span class="cm-variable">OsdFormat_Text</span>;</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">24</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; &nbsp;<span class="cm-variable">position</span> <span class="cm-operator">=</span> <span class="cm-variable">OsdPosition_LeftTop</span>;</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">25</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; }</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">26</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">};</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">27</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text="" cm-zwsp="">
</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">28</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span class="cm-keyword">public</span> <span class="cm-variable">slots</span>:</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">29</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-comment">//设置OSD标签</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt CodeMirror-linenumber-show" style="left: 0px; width: 27px;">30</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-variable-3">void</span> <span class="cm-def">setOsd</span>(<span class="cm-keyword">const</span> <span class="cm-variable">OsdInfo</span> <span class="cm-operator">&amp;</span><span class="cm-variable">osd</span>);</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">31</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-comment">//添加OSD标签</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">32</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-variable-3">void</span> <span class="cm-def">appendOsd</span>(<span class="cm-keyword">const</span> <span class="cm-variable">OsdInfo</span> <span class="cm-operator">&amp;</span><span class="cm-variable">osd</span>);</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">33</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-comment">//移除OSD标签</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">34</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-variable-3">void</span> <span class="cm-def">removeOsd</span>(<span class="cm-keyword">const</span> <span class="cm-variable">QString</span> <span class="cm-operator">&amp;</span><span class="cm-variable">name</span>);</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">35</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-comment">//清空OSD标签</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">36</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-variable-3">void</span> <span class="cm-def">clearOsd</span>();<
</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">38</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span class="cm-variable-3">void</span> <span class="cm-def">DeviceVideoSmart::receiveData</span>(<span class="cm-keyword">const</span> <span class="cm-variable">QString</span> <span class="cm-operator">&amp;</span><span class="cm-variable">type</span>, <span class="cm-keyword">const</span> <span class="cm-variable">QVariant</span> <span class="cm-operator">&amp;</span><span class="cm-variable">data</span>)</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">39</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">{</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt CodeMirror-linenumber-show" style="left: 0px; width: 27px;">40</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">if</span> (<span class="cm-operator">!</span><span class="cm-variable">widget</span> <span class="cm-operator">||</span> <span class="cm-operator">!</span><span class="cm-variable">widget</span><span class="cm-operator">-&gt;</span><span class="cm-variable">getIsRunning</span>()) {</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">41</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; &nbsp;<span class="cm-keyword">return</span>;</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">42</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; }</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">43</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text="" cm-zwsp="">
</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">44</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">if</span> (<span class="cm-variable">type</span> <span class="cm-operator">==</span> <span class="cm-string">"currentCount"</span>) {</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">45</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; &nbsp;<span class="cm-variable-3">int</span> <span class="cm-variable">currentCount</span> <span class="cm-operator">=</span> <span class="cm-variable">data</span>.<span class="cm-variable">toInt</span>();</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">46</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; &nbsp;<span class="cm-variable">OsdInfo</span> <span class="cm-variable">osd</span>;</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">47</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; &nbsp;<span class="cm-variable">osd</span>.<span class="cm-variable">name</span> <span class="cm-operator">=</span> <span class="cm-string">"currentCount"</span>;</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">48</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; &nbsp;<span class="cm-variable">osd</span>.<span class="cm-variable">fontSize</span> <span class="cm-operator">=</span> <span class="cm-number">20</span>;</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">49</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; &nbsp;<span class="cm-variable">osd</span>.<span class="cm-variable">text</span> <span class="cm-operator">=</span> <span class="cm-variable">QString</span>(<span class="cm-string">"当前人数: %1"</span>).<span class="cm-variable">arg</span>(<span class="cm-variable">currentCount</span>);</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt CodeMirror-linenumber-show" style="left: 0px; width: 27px;">50</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; &nbsp;<span class="cm-variable">osd</span>.<span class="cm-variable">color</span> <span class="cm-operator">=</span> <span class="cm-string">"#D64D54"</span>;</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">51</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; &nbsp;<span class="cm-variable">osd</span>.<span class="cm-variable">format</span> <span class="cm-opera
</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">8</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-variable">QRect</span> <span class="cm-variable">rect</span>; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span class="cm-comment">//矩形区域</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">9</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-variable">QPainterPath</span> <span class="cm-variable">path</span>; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span class="cm-comment">//路径集合</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt CodeMirror-linenumber-show" style="left: 0px; width: 27px;">10</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-variable">QList</span><span class="cm-operator">&lt;</span><span class="cm-variable">QPoint</span><span class="cm-operator">&gt;</span> <span class="cm-variable">points</span>; &nbsp; &nbsp; &nbsp; <span class="cm-comment">//点坐标集合</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">11</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text="" cm-zwsp="">
</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">12</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-variable">GraphInfo</span>() {</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">13</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; &nbsp;<span class="cm-variable">name</span> <span class="cm-operator">=</span> <span class="cm-string">"graph"</span>;</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">14</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; &nbsp;<span class="cm-variable">borderWidth</span> <span class="cm-operator">=</span> <span class="cm-number">2</span>;</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">15</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; &nbsp;<span class="cm-variable">borderColor</span> <span class="cm-operator">=</span> <span class="cm-string">"#FF0000"</span>;</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">16</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; &nbsp;<span class="cm-variable">bgColor</span> <span class="cm-operator">=</span> <span class="cm-variable">QColor</span>(<span class="cm-number">255</span>, <span class="cm-number">0</span>, <span class="cm-number">0</span>, <span class="cm-number">100</span>);</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">17</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; }</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">18</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">};</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">19</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text="" cm-zwsp="">
</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt CodeMirror-linenumber-show" style="left: 0px; width: 27px;">20</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span class="cm-keyword">public</span> <span class="cm-variable">slots</span>:</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">21</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-comment">//设置图形</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">22</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-variable-3">void</span> <span class="cm-def">setGraph</span>(<span class="cm-keyword">const</span> <span class="cm-variable">GraphInfo</span> <span class="cm-operator">&amp;</span><span class="cm-variable">graph</span>);</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">23</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-comment">//添加图形</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">24</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-variable-3">void</span> <span class="cm-def">appendGraph</span>(<span class="cm-keyword">const</span> <span class="cm-variable">GraphInfo</span> <span class="cm-operator">&amp;</span><span class="cm-variable">graph</span>);</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">25</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-comment">//删除图形</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">26</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-variable-3">void</span> <span class="cm-def">removeGraph</span>(<span class="cm-keyword">const</span> <span class="cm-variable">QString</span> <span class="cm-operator">&amp;</span><span class="cm-variable">name</span>);</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">27</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-comment">//清空图形</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">28</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-variable-3">void</span> <span class="cm-def">clearGraph</span>
</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt CodeMirror-linenumber-show" style="left: 0px; width: 27px;">30</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span class="cm-variable-3">void</span> <span class="cm-def">DeviceVideoSmart::receiveRects</span>(<span class="cm-keyword">const</span> <span class="cm-variable">QList</span><span class="cm-operator">&lt;</span><span class="cm-variable">QRect</span><span class="cm-operator">&gt;</span> <span class="cm-operator">&amp;</span><span class="cm-variable">rects</span>)</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">31</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">{</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">32</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">if</span> (<span class="cm-operator">!</span><span class="cm-variable">widget</span> <span class="cm-operator">||</span> <span class="cm-operator">!</span><span class="cm-variable">widget</span><span class="cm-operator">-&gt;</span><span class="cm-variable">getIsRunning</span>()) {</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">33</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; &nbsp;<span class="cm-keyword">return</span>;</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">34</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; }</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">35</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text="" cm-zwsp="">
</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">36</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-variable">widget</span><span class="cm-operator">-&gt;</span><span class="cm-variable">clearGraph</span>();</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">37</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-variable">foreach</span> (<span class="cm-variable">QRect</span> <span class="cm-variable">rect</span>, <span class="cm-variable">rects</span>) {</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">38</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; &nbsp;<span class="cm-variable">GraphInfo</span> <span class="cm-variable">graph</span>;</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">39</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; &nbsp;<span class="cm-variable">graph</span>.<span class="cm-variable">borderColor</span> <span class="cm-operator">=</span> <span class="cm-variable">QColor</span>(<span class="cm-number">255</span>, <span class="cm-number">0</span>, <span class="cm-number">0</span>);</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt CodeMirror-linenumber-show" style="left: 0px; width: 27px;">40</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; &nbsp;<span class="cm-variable">graph</span>.<span class="cm-variable">borderWidth</span> <span class="cm-operator">=</span> <span class="cm-number">3</span>;</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">41</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; &nbsp;<span class="cm-variable">graph</span>.<span class="cm-variable">rect</span> <span class="cm-operator">=</span> <span class="cm-variable">rect</span>;</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">42</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; &nbsp;<span class="cm-variable">widget</span><span class="cm-operator">-&gt;</span><span class="cm-variable">appendGraph</span>(<span class="cm-variable">graph</span>);</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">43</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; }</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt CodeMirror-linenumber-show" style="left: 0px;
<span> </span><img src="snap/3-5-2.jpg" referrerpolicy="no-referrer"></p><p><span>视频上传功能主要用来将本地存储的视频文件也可以是其他文件通过网络传输默认TCP上传到其他地方比如服务器服务器上要运行接收文件的程序这样就相当于远程备份视频文件的功能视频文件可以勾选需要上传哪一些。</span></p><h4 id='351-本地设置'><span>3.5.1 本地设置</span></h4><p><span>本地只需要在视频监控系统客户端上切换到视频上传页面然后选择要查询的日期范围单击查询会将视频文件查询出来显示在左边的表格中可以勾选要上传的视频文件右侧填写好服务器的IP和端口默认6000单击上传按钮会多线程的形式上传文件。</span></p><h4 id='352-远程设置'><span>3.5.2 远程设置</span></h4><p><span>远程需要放置文件传输工具,该工具完整源码如果购买了视频监控系统,可以赠送,该工具同时具备了发送端和接收端的功能,配套视频监控系统使用的是接收端,视频监控系统作为发送端,填好监听端口后,单击监听按钮,一旦有连接文件上传,会自动显示对应的接收进度,文件名称以上传的文件名为准。</span></p><h4 id='353-文件加密'><span>3.5.3 文件加密</span></h4><p><span>默认文件传输过程采用了加密机制,意味着传输的数据是加密后的数据,接收到以后根据设置的秘钥进行解密重新生成文件,防止文件传输过程中被拦截,可自定义加密规则。</span></p><h4 id='354-功能特点'><span>3.5.4 功能特点</span></h4><ol start='' ><li><span>多线程收发文件,支持加密传输。</span></li><li><span>接收端支持监听端口接收文件和主动连接服务器接收文件两种方式。</span></li><li><span>按照 文件开始符+文件大小+文件内容+文件结束符 逐个分包接收。</span></li><li><span>可对接收的加密过的文件包进行解密输出。</span></li><li><span>如果采用连接服务器方式接收文件可指定请求文件。</span></li><li><span>接收端请求文件的形式可以作为通用的程序升级方案。</span></li><li><span>进度条实时更新收发文件的进度。</span></li><li><span>发送端可设置每个包最很大小即切片分包数量。</span></li><li><span>发送端可对文件的每个包进行加密传输。</span></li><li><span>发送端支持对包进行合并发送。</span></li><li><span>可指定目录对客户端发来的请求文件进行搜索。</span></li><li><span>每个功能独立的一个类,接口清晰友好,使用方便。</span></li><li><span>支持任意Qt版本、任意系统、任意编译器。</span></li></ol><h2 id='4-电子地图'><span>4 电子地图</span></h2><p><span>电子地图有多个子模块,分别不同的功能,在每个模块上,双击对应的摄像机,都可以弹出实时视频预览画面,支持多个画面同时打开,每个摄像机都一个画面窗体。</span></p><ol start='' ><li><span>图片地图:摄像机分布在平面图上。</span></li><li><span>离线地图:默认采用百度离线瓦片地图,本地使用。</span></li><li><span>在线地图:默认采用百度地图,需要联网使用。</span></li><li><span>路径规划:指定起始点和终点经纬度坐标,查询最优路径并绘制路线,提取路线坐标集合,动态模拟轨迹,比如机器人和飞机轨迹。</span></li></ol><h3 id='41-双击预览'><span>4.1 双击预览</span></h3><p><span> </span><img src="snap/4-1-1.jpg" referrerpolicy="no-referrer"></p><h3 id='42-图片地图'><span>4.2 图片地图</span></h3><p><span> </span><img src="snap/4-2-1.jpg" referrerpolicy="no-referrer"></p><ol start='' ><li><span>图片地图的功能是为了方便直接提供图片文件然后摄像机点位可直接拖动更精确定位的场景图片可以提供鸟瞰图这种看起来更直观大气有3D的感觉。</span></li><li><span><EFBFBD>
2022-11-26 08:35:55 +00:00
<a href='https://blog.csdn.net/feiyangqingyun/article/details/104005917' target='_blank' class='url'>https://blog.csdn.net/feiyangqingyun/article/details/104005917</a></li><li><span>请下载同目录下的bin_map_tiles.zip压缩包解压到config目录下最后config文件夹下会多出来tiles tiles_hybrid两个文件夹。</span></li></ol><h3 id='44-在线地图'><span>4.4 在线地图</span></h3><p><span> </span><img src="snap/4-4-1.jpg" referrerpolicy="no-referrer"></p><p><span>在摄像机管理的界面,可以添加经纬度信息,这样就可以在地图上显示对应的摄像机点位信息,如果发现位置不对,可以在右侧先选择摄像机设备,然后鼠标单击新的位置,右侧目标经度、目标纬度信息会自动更新,然后再单击更新经纬度值则会更新当前下拉选择的设备的经纬度信息,也可以在摄像机管理界面手动填入进行修改。</span></p><p><span>在右侧还有模拟运动轨迹、开始显示轨迹两个按钮,有可能后期还会增加其他功能,是为了演示如何在地图上实现地图的相关功能,开始显示轨迹采用的定时器来生成轨迹点数据,动态模拟运动轨迹,可以单击显示设备位置按钮还原最初的设备点位图。</span></p><p><strong><span>功能特点</span></strong></p><ol start='' ><li><span>同时支持在线地图和离线地图两种模式。</span></li><li><span>同时支持webkit内核、webengine内核、IE内核。</span></li><li><span>支持设置多个标注点,信息包括名称、地址、经纬度。</span></li><li><span>可设置地图是否可单击、拖动、鼠标滚轮缩放。</span></li><li><span>可设置协议版本、秘钥、主题样式、中心坐标、中心城市、地理编码位置等。</span></li><li><span>可设置地图缩放比例和级别,缩略图、比例尺、路况信息等控件的可见。</span></li><li><span>支持地图交互,比如鼠标按下获取对应位置的经纬度。</span></li><li><span>支持查询路线,可设置起点位置、终点位置、路线模式、路线方式、路线方案(最少时间、最少换乘、最少步行、不乘地铁、最短距离、避开高速)。</span></li><li><span>可显示点线面工具,可直接在地图上划线、点、矩形、圆形等。</span></li><li><span>可设置行政区划指定某个城市区域绘制图层在线地图自动输出行政区划边界点集合到js文件给离线地图使用。</span></li><li><span>可静态或者动态添加多个覆盖物。支持点、折线、多边形、矩形、圆形、弧线、点聚合等。</span></li><li><span>函数接口友好和统一,使用简单方便,就一个类。</span></li><li><span>支持js动态交互添加点、删除点、清空点、重置点不需要刷新页面。</span></li><li><span>支持任意Qt版本、任意系统、任意编译器。</span></li></ol><h3 id='45-路径规划'><span>4.5 路径规划</span></h3><p><span> </span><img src="snap/4-5-1.jpg" referrerpolicy="no-referrer"></p><p><strong><span>基本步骤</span></strong></p><ol start='' ><li><span>输入起点坐标和终点坐标,也可以勾选地图选点,开启后直接在左侧的地图界面鼠标按下自动识别对应的经纬度坐标填入,单选框勾选的起点则填入起点坐标输入框中,勾选的终点就填入终点坐标输入框中。</span></li><li><span>选择路线方式,可选公交、驾车、步行、骑行等方式,默认选择步行。</span></li><li><span>选择路线方案,可选最少时间、最短距离、避开高速等。</span></li><li><span>输入关键点数一般查询返回的路径的经纬度坐标点数非常密集可能非常多我们需要根据输入的关键点数来过滤比如输入30表示从所有经纬度数据中平均提取出来30个数据就行。点数合计查询路线后自动返回所有经纬度坐标的数据个数。</span></li><li><span>单击查询路线,自动返回对应路径的所有经纬度坐标。</span><
</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">13</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span class="cm-comment">//自动切换默认数据库端口</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">14</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span class="cm-variable-3">void</span> <span class="cm-def">DbHelper::getDbDefaultInfo</span>(<span class="cm-keyword">const</span> <span class="cm-variable">QString</span> <span class="cm-operator">&amp;</span><span class="cm-variable">dbType</span>, <span class="cm-variable">QString</span> <span class="cm-operator">&amp;</span><span class="cm-variable">hostPort</span>,</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">15</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span class="cm-variable">QString</span> <span class="cm-operator">&amp;</span><span class="cm-variable">userName</span>, <span class="cm-variable">QString</span> <span class="cm-operator">&amp;</span><span class="cm-variable">userPwd</span>)</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">16</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">{</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">17</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">if</span> (<span class="cm-variable">dbType</span> <span class="cm-operator">==</span> <span class="cm-string">"MYSQL"</span>) {</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">18</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; &nbsp;<span class="cm-variable">hostPort</span> <span class="cm-operator">=</span> <span class="cm-string">"3306"</span>;</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">19</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; &nbsp;<span class="cm-variable">userName</span> <span class="cm-operator">=</span> <span class="cm-string">"root"</span>;</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt CodeMirror-linenumber-show" style="left: 0px; width: 27px;">20</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; &nbsp;<span class="cm-variable">userPwd</span> <span class="cm-operator">=</span> <span class="cm-string">"root"</span>;</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" sty
2022-06-02 06:36:30 +00:00
<span>单击打印按钮可以将表格中的内容打印出来,打印前会弹出打印预览界面,可以自行做边距的调整等,可以查看等待打印的内容,翻页切换。</span></p><h4 id='657-导出到excel'><span>6.5.7 导出到Excel</span></h4><p><span> </span><img src="snap/6-5-7.jpg" referrerpolicy="no-referrer">
<span>单击导出按钮可以将表格中的内容导出到excel表格独创的excel导出数据算法极速导出支持任意系统无依赖。</span></p><h4 id='658-权限验证'><span>6.5.8 权限验证</span></h4><p><span> </span><img src="snap/6-5-8-1.jpg" referrerpolicy="no-referrer">
2022-11-26 08:35:55 +00:00
<span> </span><img src="snap/6-5-8-2.jpg" referrerpolicy="no-referrer"></p><p><span>假设设置了用户没有退出系统和电子地图的权限,则关闭系统的时候会弹出错误信息提示当前用户没有权限。</span></p><h3 id='66-录像计划'><span>6.6 录像计划</span></h3><p><span> </span><img src="snap/6-6-1.jpg" referrerpolicy="no-referrer">
<span> </span><img src="snap/6-6-2.jpg" referrerpolicy="no-referrer">
<span> </span><img src="snap/6-6-3.jpg" referrerpolicy="no-referrer">
<span> </span><img src="snap/6-6-4.jpg" referrerpolicy="no-referrer"></p><p><span>录像文件严格按照30分钟一个文件除了首个文件和末尾文件不一定是30分钟的文件中间的肯定是完整的30分钟的文件时间从00:00到29:59或者30:00到59:59。由于文件打开和保存需要一点时间文件可能会有1s的偏差。</span></p><p><span>基本步骤:</span></p><ol start='' ><li><span>单击批量按钮可以批量添加1-64通道7 * 24小时录像计划到数据库中。</span></li><li><span>每个通道可以设置周一到周日7天的每个半小时时段是否录像。</span></li><li><span>上面表格中选中通道,下面录像计划控件选择对应的格子即可。</span></li><li><span>可以鼠标右键选择全选、反选、清空操作。</span></li><li><span>录像计划控件更改后会立即更新表格中对应通道的录像计划值1表示该时间段录像0表示不录像。</span></li><li><span>选中通道表格行,下面会自动显示对应的录像计划,一目了然。</span></li></ol><h3 id='67-其他设置'><span>6.7 其他设置</span></h3><p><span> </span><img src="snap/6-7-0.jpg" referrerpolicy="no-referrer"></p><p><span>其他设置里面的内容之前在基本设置中,现在重新开一个窗体,因为后面可能还有各种各样的设置,预留空间。</span></p><h4 id='661-串口配置'><span>6.6.1 串口配置</span></h4><p><span> </span><img src="snap/6-7-1.jpg" referrerpolicy="no-referrer"></p><p><span>系统中可能用到了多个串口通信,可以在这里选择对应的串口号和波特率。</span></p><h4 id='662-网络配置'><span>6.6.2 网络配置</span></h4><p><span> </span><img src="snap/6-7-2.jpg" referrerpolicy="no-referrer"></p><p><span>系统中可能用到多种网络通信比如软件主动连接服务器需要填写TCP地址和端口也可能软件作为服务端填写TCP或者UDP监听端口。</span></p><h2 id='7-简易使用步骤'><span>7 简易使用步骤</span></h2><h3 id='71-添加摄像机'><span>7.1 添加摄像机</span></h3><ol start='' ><li><span>切换到系统设置-》摄像机管理,单击添加,输入码流地址,单击保存。</span></li><li><span>在不知道主码流和子码流是啥的情况下,两个地方填一样的,其余默认即可。</span></li><li><span>本地文件格式g:/mp4/1.mp4</span></li><li><span>USB摄像机默认ffmpeg内核为 video=USB2.0 PC CAMERA</span></li><li><span>摄像机视频流直接填入rtsp、rtmp、http的视频流地址该地址可以先用vlc播放器或者potplay等播放器先试试是否能正常播放不能的话就别添加了添加了也没卵用别费力气了。</span></li></ol><h3 id='72-视频播放'><span>7.2 视频播放</span></h3><p><span>切换到视频监控主界面,左侧设备列表,双击摄像机,自动通道播放,双击录像机则整个录像机下面的摄像机全部加载。</span></p><h3 id='73-云台控制'><span>7.3 云台控制</span></h3><p><span>云台控制的前提是摄像机是通过onvif搜索的形式添加的不然没有云台地址没法进行云台控制当然也必须要求摄像机带云台不带云台的摄像机是不能进行云台控制的。</span>
2022-06-02 06:36:30 +00:00
<span>先选中要进行云台控制的摄像机通道,边缘高亮,然后再单击右侧的云台控件,可以上下左右等移动,变倍和光圈没有用。</span></p><h3 id='74-自动校时'><span>7.4 自动校时</span></h3><p><span>在系统设置中开启自动校时后,设备自动上线后会自动将本地时间同步到设备。</span></p><h3 id='75-事件订阅'><span>7.5 事件订阅</span></h3><p><span>在系统设置中开启事件订阅后,一旦接收到设备的报警信息会显示到主界面左下角的信息栏,右下角弹出对应的报警信息。</span>
2022-11-24 12:14:44 +00:00
<span>摄像机要响应事件订阅,具体详细设置说明参见说明书其他说明中的摄像机报警输入设置。</span></p><h3 id='76-图片参数'><span>7.6 图片参数</span></h3><p><span> </span><img src="snap/7-6-1.jpg" referrerpolicy="no-referrer"></p><p><strong><span>操作说明</span></strong></p><ul><li><span>用onvif也可以对摄像机的明亮度、对比度、饱和度进行设置。</span></li><li><span>先选中对应的通道,然后右下角这里找到设置的区域。</span></li><li><span>单击获取参数,会自动将对应摄像机的明亮度、对比度、饱和度值读回来,显示在对应文本框和滑块中。</span></li><li><span>如果需要设置图片参数,先移动滑块到需要的值,然后单击设置参数按钮即可。</span></li><li><span>设置完以后会立即应用,传过来的视频流就能看到效果。</span></li><li><span>下面还有两个按钮可以手动重启设备以及校时。后期可能还会增加一些按钮。</span></li></ul><h2 id='8-内核模块说明'><span>8 内核模块说明</span></h2><ol start='' ><li><span>本系统支持多种内核,方便不同的用户选择,适应不同的应用场景。</span></li><li><strong><span>本系统默认集成的是ffmpeg内核其他内核需要额外购买或者定制支持定制内核。</span></strong></li><li><span>每个内核实现的功能不一定完全一致,可仔细查看后面的每个内核的功能特点说明。</span></li></ol><h3 id='81-视频监控内核'><span>8.1 视频监控内核</span></h3><h4 id='811-效果图'><span>8.1.1 效果图</span></h4><p><span> </span><img src="snap/8-1-1.jpg" referrerpolicy="no-referrer">
<span> </span><img src="snap/8-1-2.jpg" referrerpolicy="no-referrer">
<span> </span><img src="snap/8-1-3.jpg" referrerpolicy="no-referrer">
<span> </span><img src="snap/8-1-4.jpg" referrerpolicy="no-referrer"></p><h4 id='812-基础功能'><span>8.1.2 基础功能</span></h4><ol start='' ><li><span>支持各种音频视频文件格式比如mp3、wav、mp4、asf、rm、rmvb、mkv等。</span></li><li><span>支持本地摄像头设备,可指定分辨率、帧率。</span></li><li><span>支持各种视频流格式比如rtp、rtsp、rtmp、http等。</span></li><li><span>本地音视频文件和网络音视频文件,自动识别文件长度、播放进度、音量大小、静音状态等。</span></li><li><span>文件可以指定播放位置、调节音量大小、设置静音状态等。</span></li><li><span>支持倍速播放文件可选0.5倍、1.0倍、2.5倍、5.0倍等速度,相当于慢放和快放。</span></li><li><span>支持开始播放、停止播放、暂停播放、继续播放。</span></li><li><span>支持抓拍截图,可指定文件路径,可选抓拍完成是否自动显示预览。</span></li><li><span>支持录像存储,手动开始录像、停止录像,部分内核支持暂停录像后继续录像,跳过不需要录像的部分。</span></li><li><span>支持无感知切换循环播放、自动重连等机制。</span></li><li><span>提供播放成功、播放完成、收到解码图片、收到抓拍图片、视频尺寸变化、录像状态变化等信号。</span></li><li><span>多线程处理,一个解码一个线程,不卡主界面。</span></li></ol><h4 id='813-特色功能'><span>8.1.3 特色功能</span></h4><ol start='' ><li><span>同时支持多种解码内核包括qmedia内核Qt4/Qt5/Qt6、ffmpeg内核ffmpeg2/ffmpeg3/ffmpeg4/ffmpeg5、vlc内核vlc2/vlc3、mpv内核mpv1/mp2、海康sdk、easyplayer内核等。</span></li><li><span>非常完善的多重基类设计,新增一种解码内核只需要实现极少的代码量,就可以应用整套机制。</span></li><li><span>同时支持多种画面显示策略,自动调整(原始分辨率小于显示控件尺寸则按照原始分辨率大小显示,否则等比缩放)、等比缩放(永远等比缩放)、拉伸填充(永远拉伸填充)。所有内核和所有视频显示模式下都支持三种画面显示策略。</span></li><li><span>同时支持多种视频显示模式句柄模式传入控件句柄交给对方绘制控制、绘制模式回调拿到数据后转成QImage用QPainter绘制、GPU模式回调拿到数据后转成yuv用QOpenglWidget绘制</span></li><li><span>支持多种硬件加速类型ffmpeg可选dxva2、d3d11va等mpv可选auto、dxva2、d3d11vavlc可选any、dxva2、d3d11va。不同的系统环境有不同的类型选择比如linux系统有vaapi、vdpaumacos系统有videotoolbox。</span></li><li><span>解码线程和显示窗体分离,可指定任意解码内核挂载到任意显示窗体,动态切换。</span></li><li><span>支持共享解码线程,默认开启并且自动处理,当识别到相同的视频地址,共享一个解码线程,在网络视频环境中可以大大节约网络流量以及对方设备的推流压力。国内顶尖视频厂商均采用此策略。这样只要拉一路视频流就可以共享到几十个几百个通道展示。</span></li><li><span>自动识别视频旋转角度并绘制比如手机上拍摄的视频一般是旋转了90度的播放的时候要自动旋转处理不然默认是倒着的。</span></li><li><span>自动识别视频流播放过程中分辨率的变化,在视频控件上自动调整尺寸。比如摄像机可以在使用过程中动态配置分辨率,当分辨率改动后对应视频控件也要做出同步反应。</span></li><li><span>音视频文件无感知自动切换循环播放,不会出现切换期间黑屏等肉眼可见的切换痕迹。</span></li><li><span>视频控件同时支持任意解码内核、任意画面显示策略、任意视频显示模式。</span></li><li><span>视频控件悬浮条同时支持句柄、绘制、GPU三种模式非绝对坐标移来<EFBFBD><EFBFBD>
<span> </span><img src="snap/8-2-2.jpg" referrerpolicy="no-referrer">
<span> </span><img src="snap/8-2-3.jpg" referrerpolicy="no-referrer">
<span> </span><img src="snap/8-2-4.jpg" referrerpolicy="no-referrer"></p><h4 id='822-功能介绍'><span>8.2.2 功能介绍</span></h4><ol start='' ><li><span>广播搜索设备支持IPC和NVR依次返回。</span></li><li><span>可选择不同的网卡IP进行对应网段设备的搜索。</span></li><li><span>依次获取Onvif地址、Media地址、Profile文件、Rtsp地址。</span></li><li><span>可对指定的Profile获取视频流Rtsp地址比如主码流地址、子码流地址。</span></li><li><span>可对每个设备设置Onvif用户信息用于认证获取详细信息。</span></li><li><span>可实时预览摄像机图像。</span></li><li><span>支持云台控制,可上下左右调节云台,支持绝对移动、相对移动、连续移动三种方式,可对图像拉近拉远。</span></li><li><span>支持获取预置位集合、调用预置位、添加预置位、删除预置位等。</span></li><li><span>支持图片参数设置,包括亮度、对比度、饱和度、锐度等。</span></li><li><span>支持Qt4和Qt6任意Qt版本以及后续Qt版本亲测Qt4.7.0到Qt6.2。</span></li><li><span>支持任意编译器亲测mingw、msvc、gcc、clang。</span></li><li><span>支持任意操作系统亲测xp、win7、win10、android、linux、嵌入式linux、树莓派全志H3等。</span></li><li><span>支持任意Onvif摄像机和NVR亲测海康、大华、宇视、天地伟业、华为、海思芯片内核等可定制开发。</span></li><li><span>支持对指定IP地址及onvif地址进行单播搜索比如跨网段情况下非常有用。</span></li><li><span>支持指定过滤条件过滤搜索设备。</span></li><li><span>支持搜索间隔和搜索策略设置,保证所有设备搜索回来,在大量设备现场很有用(亲测上千个摄像机现场,搜索回来的设备数量比摄像机厂家自带搜索工具还要准确)。</span></li><li><span>可对设备进行重启、网络参数获取等。</span></li><li><span>支持各种事件订阅、Onvif抓图等操作。</span></li><li><span>支持NTP校时和时间同步设置。</span></li><li><span>内置了线程实时执行Onvif指令队列排队最大速度的执行对应的指令执行结果信号发出。</span></li><li><span>采用的最底层的TCP+UDP通信机制原创最底层协议解析纯QtWidget编写。</span></li><li><span>超级小巧轻量总共约3000行代码不依赖任何第三方的库和组件跨平台。</span></li><li><span>封装好了通用的数据发送和接收解析的函数可以非常方便的自行拓展其他Onvif处理。</span></li><li><span>工具上提供了收发数据文本框,显示收发的数据,方便查看和分析。</span></li><li><span>支持所有Onvif设备代码工整接口友好直接引入pri即可使用。</span></li></ol><h4 id='823-云台说明'><span>8.2.3 云台说明</span></h4><ol start='' ><li><span>x、y、z 范围都在0-1之间。</span></li><li><span>x为负数表示左转x为正数表示右转。</span></li><li><span>y为负数表示下转y为正数表示上转。</span></li><li><span>z为正数表示拉近z为负数表示拉远。</span></li><li><span>通过x和y的组合来实现云台的控制。</span></li><li><span>通过z的组合来实现焦距控制。</span></li></ol><h4 id='824-主要功能'><span>8.2.4 主要功能</span></h4><ol start='' ><li><span>搜索设备,获取设备的信息比如厂家、型号等。</span></li><li><span>获取设备的多个配置文件信息profile。</span></li><li><span>获取对应配置文件的视频流地址rtsp以及分辨率等参数。</span></li><li><span>云台控制,上下左右移动,焦距放大缩小,相对和绝对移动。</span></li><li><span>获取预置位信息,触发预置位。</span></li><li><span>订阅事件接收设备的各种消息尤其是报警事件比如IO口的报警。</span></li><li><span>抓图,获取设备当前的图片。</span></li><li><span>获取、创建、删除用<EFBFBD><EFBFBD>
2022-06-02 06:36:30 +00:00
<span> </span><img src="snap/10-0-3.jpg" referrerpolicy="no-referrer">
<span> </span><img src="snap/10-0-5.jpg" referrerpolicy="no-referrer">
<span> </span><img src="snap/10-0-11.jpg" referrerpolicy="no-referrer">
<span> </span><img src="snap/10-0-15.jpg" referrerpolicy="no-referrer">
2022-11-24 12:14:44 +00:00
<span> </span><img src="snap/10-0-17.jpg" referrerpolicy="no-referrer"></p><p><span>本系统内置高达18套皮肤样式供用户选择可以在系统设置中随意切换立即应用。</span></p><pre class="md-fences md-end-block md-fences-with-lineno ty-contain-cm modeLoaded" spellcheck="false" lang="cpp" style="break-inside: unset;"><div class="CodeMirror cm-s-inner cm-s-null-scroll CodeMirror-wrap" lang="cpp"><div style="overflow: hidden; position: relative; width: 3px; height: 0px; top: 9.51471px; left: 43.9916px;"><textarea autocorrect="off" autocapitalize="off" spellcheck="false" tabindex="0" style="position: absolute; bottom: -1em; padding: 0px; width: 1000px; height: 1em; outline: none;"></textarea></div><div class="CodeMirror-scrollbar-filler" cm-not-content="true"></div><div class="CodeMirror-gutter-filler" cm-not-content="true"></div><div class="CodeMirror-scroll" tabindex="-1"><div class="CodeMirror-sizer" style="margin-left: 36px; margin-bottom: 0px; border-right-width: 0px; padding-right: 0px; padding-bottom: 0px;"><div style="position: relative; top: 0px;"><div class="CodeMirror-lines" role="presentation"><div role="presentation" style="position: relative; outline: none;"><div class="CodeMirror-measure"><pre><span>xxxxxxxxxx</span></pre><div class="CodeMirror-linenumber CodeMirror-gutter-elt"><div>26</div></div></div><div class="CodeMirror-measure"></div><div style="position: relative; z-index: 1;"></div><div class="CodeMirror-code" role="presentation" style=""><div class="CodeMirror-activeline" style="position: relative;"><div class="CodeMirror-activeline-background CodeMirror-linebackground"></div><div class="CodeMirror-gutter-background CodeMirror-activeline-gutter" style="left: -36px; width: 36px;"></div><div class="CodeMirror-gutter-wrapper CodeMirror-activeline-gutter" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt CodeMirror-linenumber-show" style="left: 0px; width: 27px;">1</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span class="cm-variable-3">void</span> <span class="cm-def">QUIStyle::getStyle</span>(<span class="cm-variable">QStringList</span> <span class="cm-operator">&amp;</span><span class="cm-variable">styleNames</span>, <span class="cm-variable">QStringList</span> <span class="cm-operator">&amp;</span><span class="cm-variable">styleFiles</span>)</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">2</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">{</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">3</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable">QStringList</span> <span class="cm-variable">names</span>;</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">4</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">if</span> (<span class="cm-variable">names</span>.<span class="cm-variable">count</span>() <span class="cm-operator">==</span> <span class="cm-number">0</span>) {</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">5</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; &nbsp;<span class="cm-v
</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">13</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-comment">//中文皮肤名称对应样式表文件</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">14</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">static</span> <span class="cm-variable">QStringList</span> <span class="cm-variable">files</span>;</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">15</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-keyword">if</span> (<span class="cm-variable">files</span>.<span class="cm-variable">count</span>() <span class="cm-operator">==</span> <span class="cm-number">0</span>) {</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">16</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; &nbsp;<span class="cm-variable">files</span> <span class="cm-operator">&lt;&lt;</span> <span class="cm-string">":/qss/blackblue.css"</span> <span class="cm-operator">&lt;&lt;</span> <span class="cm-string">":/qss/blacksoft.css"</span> <span class="cm-operator">&lt;&lt;</span> <span class="cm-string">":/qss/blackvideo.css"</span>;</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">17</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; &nbsp;<span class="cm-variable">files</span> <span class="cm-operator">&lt;&lt;</span> <span class="cm-string">":/qss/darkblack.css"</span> <span class="cm-operator">&lt;&lt;</span> <span class="cm-string">":/qss/darkblue.css"</span> <span class="cm-operator">&lt;&lt;</span> <span class="cm-string">":/qss/darkgray.css"</span>;</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">18</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; &nbsp;<span class="cm-variable">files</span> <span class="cm-operator">&lt;&lt;</span> <span class="cm-string">":/qss/flatblack.css"</span> <span class="cm-operator">&lt;&lt;</span> <span class="cm-string">":/qss/flatblue.css"</span> <span class="cm-operator">&lt;&lt;</span> <span class="cm-string">":/qss/flatgray.css"</span>;</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">19</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; &nbsp;<span class="cm-variable">files</span> <span class="cm-operator">&lt;&lt;</span> <span class="cm-string">":/qss/lightblack.css"</span> <span class="cm-operator">&lt;&lt;</span> <span class="cm-string">":/qss/lightblue.css"</span> <span class="cm-operator">&lt;&lt;</span> <span class="cm-string">":/qss/lightgray.css"</span>;</s
2022-11-26 08:35:55 +00:00
</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">24</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-variable">styleNames</span> <span class="cm-operator">=</span> <span class="cm-variable">names</span>;</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 27px;">25</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-variable">styleFiles</span> <span class="cm-operator">=</span> <span class="cm-variable">files</span>;</span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -36px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt CodeMirror-linenumber-show" style="left: 0px; width: 27px;">26</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">}</span></pre></div></div></div></div></div></div><div style="position: absolute; height: 0px; width: 1px; border-bottom: 0px solid transparent; top: 599px;"></div><div class="CodeMirror-gutters" style="height: 599px;"><div class="CodeMirror-gutter CodeMirror-linenumbers" style="width: 35px;"></div></div></div></div></pre><h3 id='101-windows-7'><span>10.1 windows-7</span></h3><p><span> </span><img src="snap/10-1-1.jpg" referrerpolicy="no-referrer"></p><h3 id='102-windows-11'><span>10.2 windows-11</span></h3><p><span> </span><img src="snap/10-2-1.jpg" referrerpolicy="no-referrer"></p><h3 id='103-linux-ubuntu'><span>10.3 linux-ubuntu</span></h3><p><span> </span><img src="snap/10-3-1.jpg" referrerpolicy="no-referrer"></p><h3 id='104-linux-fedora'><span>10.4 linux-fedora</span></h3><p><span> </span><img src="snap/10-4-1.jpg" referrerpolicy="no-referrer"></p><h3 id='105-linux-centos'><span>10.5 linux-centos</span></h3><p><span> </span><img src="snap/10-5-1.jpg" referrerpolicy="no-referrer"></p><h3 id='106-linux-uos'><span>10.6 linux-uos</span></h3><p><span> </span><img src="snap/10-6-1.jpg" referrerpolicy="no-referrer"></p><h3 id='107-linux-kylin'><span>10.7 linux-kylin</span></h3><p><span> </span><img src="snap/10-7-1.jpg" referrerpolicy="no-referrer"></p><h3 id='108-linux-neokylin'><span>10.8 linux-neokylin</span></h3><p><span> </span><img src="snap/10-8-1.jpg" referrerpolicy="no-referrer"></p><h3 id='109-linux-newstart'><span>10.9 linux-newstart</span></h3><p><span> </span><img src="snap/10-9-1.jpg" referrerpolicy="no-referrer"></p><h3 id='1010-linux-debian'><span>10.10 linux-debian</span></h3><p><span> </span><img src="snap/10-10-1.jpg" referrerpolicy="no-referrer"></p><h3 id='1011-unix-mac'><span>10.11 unix-mac</span></h3><p><span> </span><img src="snap/10-11-1.jpg" referrerpolicy="no-referrer"></p><h2 id='11-程序框架说明'><span>11 程序框架说明</span></h2><p><span>备注:下面的截图和说明未必是最新的,但是大部分是一致的,整体的框架不会改变,可能会有新增加子模块和代码,或者部分类文件有调整或者删除,具体以最新的代码为准。</span></p><h3 id='111-整体代码结构'><span>11.1 整体代码结构</span></h3><p><span> </span><img src="snap/11-1-1.jpg" referrerpolicy="no-referrer"></p><p><span>本系统采用模块化的设备有用到第三方开源类库比如串口通信qextserialport全部放在3rd下面有用到很多自己封装完善的通用类库比如ffmpeg视频监控全部放在core下面设备通信和辅助处理全部放在class下面所有界面全部放在ui下面相当于一个个小的组件合起来最终形成了整个监控系统的完整代码。</span></p><h3 id='112-主模块说明'><span>11.2 主模块说明</span></h3><figure><table><thead><tr><th styl
2022-06-02 06:36:30 +00:00
<span> </span><img src="snap/13-4-1.jpg" referrerpolicy="no-referrer">
2022-11-26 08:35:55 +00:00
<span> </span><img src="snap/13-4-1.jpg" referrerpolicy="no-referrer"></p><p><strong><span>操作说明</span></strong></p><ol start='' ><li><span>默认摄像机IO输入或者开关量输入是关闭的需要手动开启。</span></li><li><span>一般都是登录到摄像机的web页面找到开关量的地方可能描述不一样但是大致的意思差不多。</span></li><li><span>一般摄像机会有两组开关量输入,而且开关量报警有常开常闭两种,都需要自己手动选择。</span></li><li><span>如果是常开的话意味着闭合是属于报警,反之亦然。</span></li><li><span>找两个导线接在对应口子(详见摄像机厂家的说明书,摄像机背面板也会有对应字样标识一般叫 in</span></li><li><span>短接或者扒开都会有反应onvif工具都能接收到信息前提是单击过订阅事件按钮而且顺利返回了订阅地址才行</span></li><li><span>会收到LogicalState关键字的信息true或者1表示报警false或者0表示正常。</span></li><li><span>可能每个厂家会有所区别需要自己拿到数据后做特殊处理但是大部分厂家都是相似的实在不行无非搞个contains方法判断好了。</span></li></ol><h3 id='135-环境使用qtvs'><span>13.5 环境使用qt+vs</span></h3><p><span> </span><img src="snap/13-5-1.jpg" referrerpolicy="no-referrer">
2022-06-02 06:36:30 +00:00
<span> </span><img src="snap/13-5-2.jpg" referrerpolicy="no-referrer"></p><p><span>打开项目QT VS TOOLS Open Qt Project File 选择 video_system.pro,然后等待项目加载完毕。</span>
2022-07-02 04:18:12 +00:00
<span>由于项目中用到了ffmpeg和vlc引用了对应的lib库所以在用vs+qt的开发环境中很可能报错提示映像是不安全的错误导致编译通不过需要做个设置。</span></p><p><strong><span>解决方法</span></strong></p><ol start='' ><li><span>第一步:打开该项目的“属性页”对话框。</span></li><li><span>第二步:单击“链接器”文件夹。</span></li><li><span>第三步:单击“命令行”属性页。</span></li><li><span>第四步:将 /SAFESEH:NO 键入“附加选项”框中,然后点击应用。</span></li><li><span>如果设置完发现还是不行,那应该是没有一开始就设置这个步骤,你需要打开项目以后就设置好这个步骤,再去编译,建议重新解压项目来一遍。</span></li></ol><h3 id='136-数据库设置mysql'><span>13.6 数据库设置mysql</span></h3><p><span> </span><img src="snap/13-6-1.jpg" referrerpolicy="no-referrer"></p><p><span>如果在数据库设置中选择了mysql数据库需要对mysql数据库做个设置就是将编码设置成utf8已设置可以跳过不然很可能数据库无法正常使用。</span></p><p><span>32位的Qt程序带对应32位的libmysql动态库可以访问32/64位的mysql数据库64位的也是一样可以访问32/64位的mysql数据库只需要带上对应位数的动态库就行。查看mysql是32位还是64位命令 mysql.exe -V。</span>
<span> </span><img src="snap/13-6-2.jpg" referrerpolicy="no-referrer"></p><h3 id='137-打开usb摄像头'><span>13.7 打开USB摄像头</span></h3><p><span> </span><img src="snap/13-7-1.jpg" referrerpolicy="no-referrer"></p><p><span>在加载USB摄像机的时候需要填写对应USB设备的名称可以通过命令行和设备管理器查看对应的名称要英文的。</span></p><p><span>在需要加载多个USB摄像机的场景下有时候会遇到同名的USB名称设备此时需要打开注册表进行设备名称修改后按照新修改后的设备名称填入即可。</span></p><p><span> </span><img src="snap/13-7-2.jpg" referrerpolicy="no-referrer">
2022-06-02 06:36:30 +00:00
<span> </span><img src="snap/13-7-3.jpg" referrerpolicy="no-referrer">
2022-11-24 12:14:44 +00:00
<span> </span><img src="snap/13-7-4.jpg" referrerpolicy="no-referrer"></p><p><span>如果是在虚拟机中打开USB摄像头你需要对虚拟机做点设置默认USB2.0需要改成USB3.1。</span>
<span> </span><img src="snap/13-7-5.jpg" referrerpolicy="no-referrer"></p><h3 id='138-项目代码行数'><span>13.8 项目代码行数</span></h3><p><span> </span><img src="snap/13-8-1.jpg" referrerpolicy="no-referrer"></p><p><span>整个项目源代码行数大概30W行其中代码13.5W行占比45%注释12.7W行占比42%空行3.5W行。分层设计注释详细。</span></p><h3 id='139-编译ffmpeg'><span>13.9 编译ffmpeg</span></h3><p><span>下面是linux系统编译ffmpeg步骤</span></p><ol start='' ><li><span>第一步下载好ffmpeg这个可以去官网 </span><a href='http://ffmpeg.org/' target='_blank' class='url'>http://ffmpeg.org/</a><span> 或者第三方下载地址 </span><a href='https://www.videohelp.com/software/ffmpeg/old-versions' target='_blank' class='url'>https://www.videohelp.com/software/ffmpeg/old-versions</a><span> 推荐这个地址官网很多人找不到下载地址自行找到下载位置下载。要注意的是有些很老的嵌入式linux系统的编译器未必支持最新的ffmpeg4。下面用ffmpeg-3.4.5.tar.gz举例子。</span></li><li><span>第二步复制ffmpeg-3.4.5.tar.gz 到自定义文件夹下,我这里是/home/liu</span></li><li><span>第三步解压ffmpegtar zxvf ffmpeg-3.4.5.tar.gz C /home/liu</span></li><li><span>第四步安装编译ffmpeg依赖的包 apt-get install yasm</span></li><li><span>第五步编译ffmpeg cd /home/liu/ffmpeg-3.4.5</span></li></ol><ul><li><span>如果编译静态库执行以下命令</span></li><li><span>./configure --prefix=host --enable-static --disable-shared --disable-doc</span></li><li><span>如果编译动态库执行以下命令</span></li><li><span>./configure --prefix=host --enable-shared --disable-static --disable-doc</span></li><li><span>如果需要编译ffplay以便直接用其打开测试可以在参数后面加上--enable-ffplay</span></li><li><span>./configure --prefix=host --enable-shared --disable-static --disable-doc --enable-ffplay</span></li><li><span>嵌入式交叉编译需要指定编译器路径 --cross-prefix=/usr/local/arm-linux-gcc-4.9.2/gcc-linaro-arm-linux-gnueabihf-4.9-2014.08_linux/bin/arm-linux-gnueabihf- --arch=arm --target-os=linux</span></li><li><span>其他常用参数 --disable-zlib --disable-xlib --enable-x11grab --disable-libxcb </span></li><li><span>可以执行./configure help 来查看支持哪些参数,尤其是各种解码器的开关,具体可搜索。</span></li><li><span>其他参数可参见网页 </span><a href='https://blog.csdn.net/momo0853/article/details/78043903' target='_blank' class='url'>https://blog.csdn.net/momo0853/article/details/78043903</a></li><li><span>make (还可以开启多线程编译加快速度 make j4</span></li><li><span>make install</span></li></ul><ol start='6' ><li><span>第六步打开ffmpeg3.4.5/host目录生成的文件都在这里拿去用吧。</span></li></ol><p><span>编译ffmpeg支持x264/x265编码</span></p><ol start='' ><li><span>在linux上默认编译ffmpeg出来的库支持h264/h265的解码编码并不支持所以需要单独加上x264/x265的库再编译。</span></li><li><span>首先要下载好x264/x265的源码包解压到目录切换到管理员权限需要编译后拷贝库到/usr/lib</span></li><li><span>编译libx264以便支持h264编码。</span></li></ol><ul><li><span>./configure --disable-asm</span></li><li><span>make -j4</span></li><li><span>make install</span></li></ul><ol start='4' ><li><span>编译libx265以便支持h265(hevc)编码。</span></li></ol><ul><li><span>定位到x265的build/linux目录</span></li><li><span>./make-Makefiles.bash</span></li><li><span>make -j4</span></li><li><span>make install</span></li><li><span>如果提示cmake:command not found 需要安装 apt install cmake-curses-gui</span></li></ul><ol start='5' ><li><span>编译ffmpeg加入x264/x265支持。</span></li></ol><ul><li><span>指定位置链接libx264头文件和库写法</span></li><li><span>./configure --prefix=host --disable-static --enable-shared --
2022-06-08 07:52:50 +00:00
<span> </span><img src="snap/13-10-2.jpg" referrerpolicy="no-referrer">
2022-11-24 12:14:44 +00:00
<span> </span><img src="snap/13-10-3.jpg" referrerpolicy="no-referrer"></p><h3 id='1311-浏览器内核'><span>13.11 浏览器内核</span></h3><ul><li><span>本系统的电子地图模块支持三种浏览器内核webkit、webengine、miniblink编译的时候会自动识别。</span></li><li><span>其中Qt5.6以前用的是webkitQt5.6版本以后分两种情况一种是mingw编译器windows系统对应的Qt库不再提供浏览器模块所以本系统为了兼容各种编译器特意封装了miniblink浏览器内核弥补这个不足。</span></li><li><span>Qt5.6以后的版本在linux系统和mac等系统都不存在没有浏览器控件的情况都使用的webengine。</span></li><li><span>仅仅是windows上的mingw编译器的Qt版本没有其他系统其实都有的。很多人在这个地方都有疑问都以为只有msvc编译器有浏览器控件其实确切的说是在windows上msvc的Qt库带浏览器控件。</span></li><li><span>安装Qt的时候webengine模块默认不勾选需要主动勾选才会安装。</span></li><li><span>也不是所有的msvc的Qt版本都有webengine浏览器模块哪怕你勾选了也没用有些版本官方并没有编译需要自行编译。需要到对应的Qt安装目录查看是否有 Qt5WebEngine.dll 文件。</span></li></ul><p><span> </span><img src="snap/13-11-1.jpg" referrerpolicy="no-referrer"></p><h3 id='1312-odbc数据源'><span>13.12 ODBC数据源</span></h3><p><span>本系统除了支持直连各种数据库比如mysql、postgresql、sqlserver、oracle数据库也支持odbc数据源的形式连接以上各种数据库在配置数据源的时候记得区分32、64位对应数据源后面带有32/64一起字样的说明该数据源可以同时支持32位和64位的程序访问不带的要用对应位数的才能访问。数据库名称记得填写的是数据源对应的名称而不是数据源连接的数据库名称很多人会搞错。</span></p><p><span> </span><img src="snap/13-12-1.jpg" referrerpolicy="no-referrer"></p><h3 id='1313-摄像机音频设置'><span>13.13 摄像机音频设置</span></h3><p><span>摄像机音频编码可选多种格式建议选择用AAC格式。</span></p><p><span> </span><img src="snap/13-13-1.jpg" referrerpolicy="no-referrer">
<span> </span><img src="snap/13-13-2.jpg" referrerpolicy="no-referrer"></p><h3 id='1314-数据库插件'><span>13.14 数据库插件</span></h3><p><span>使用对应的数据库需要Qt中对应的数据库插件支持才行由于Qt版本众多数据库插件有增有减在打开数据库失败的时候如果提示数据库驱动未找到一定先要看下自己所用Qt套件版本有没有该数据库插件没有的话要自行编译或者更换其他版本试试。</span>
<span>大概从Qt5.12.5版本开始不自带mysql数据库插件一定要自己编译。编译的过程有一定难度建议耐心多试几次。</span></p><p><span> </span><img src="snap/13-14-1.jpg" referrerpolicy="no-referrer"></p><p><span>编译数据库插件通用步骤:</span></p><ol start='' ><li><span>安装对应的数据库安装后会有include头文件和lib链接库文件这是基本的前提编译数据库插件必须要有这两个东西。</span></li><li><span>准备好数据库插件源码比如qt-everywhere-src-5.14.2\qtbase\src\plugins\sqldrivers\mysql可以在安装Qt的时候勾选src或者后期直接官网重新下载源码解压出来。</span></li><li><span>打开你要编译的数据库插件源码比如mysql就打开mysql.prooracle就打开oci.pro。</span></li><li><span>在pro中注释掉一行 #QMAKE_USE += mysql如果是oci项目则是#QMAKE_USE += oci。</span></li><li><span>qsqldriverbase.pri文件中注释掉 #include($$shadowed($$PWD)/qtsqldrivers-config.pri)。</span></li><li><span>mysql.pro文件内容下面加上如下代码。</span></li></ol><pre class="md-fences md-end-block md-fences-with-lineno ty-contain-cm modeLoaded" spellcheck="false" lang="cpp"><div class="CodeMirror cm-s-inner cm-s-null-scroll CodeMirror-wrap" lang="cpp"><div style="overflow: hidden; position: relative; width: 3px; height: 0px; top: 9.51471px; left: 35.9874px;"><textarea autocorrect="off" autocapitalize="off" spellcheck="false" tabindex="0" style="position: absolute; bottom: -1em; padding: 0px; width: 1000px; height: 1em; outline: none;"></textarea></div><div class="CodeMirror-scrollbar-filler" cm-not-content="true"></div><div class="CodeMirror-gutter-filler" cm-not-content="true"></div><div class="CodeMirror-scroll" tabindex="-1"><div class="CodeMirror-sizer" style="margin-left: 28px; margin-bottom: 0px; border-right-width: 0px; padding-right: 0px; padding-bottom: 0px;"><div style="position: relative; top: 0px;"><div class="CodeMirror-lines" role="presentation"><div role="presentation" style="position: relative; outline: none;"><div class="CodeMirror-measure"><pre><span>xxxxxxxxxx</span></pre><div class="CodeMirror-linenumber CodeMirror-gutter-elt"><div>3</div></div></div><div class="CodeMirror-measure"></div><div style="position: relative; z-index: 1;"></div><div class="CodeMirror-code" role="presentation"><div class="CodeMirror-activeline" style="position: relative;"><div class="CodeMirror-activeline-background CodeMirror-linebackground"></div><div class="CodeMirror-gutter-background CodeMirror-activeline-gutter" style="left: -27.9958px; width: 28px;"></div><div class="CodeMirror-gutter-wrapper CodeMirror-activeline-gutter" style="left: -27.9958px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt CodeMirror-linenumber-show" style="left: 0px; width: 19px;">1</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span class="cm-variable">path</span> <span class="cm-operator">=</span> <span class="cm-variable">C</span>:<span class="cm-operator">/</span><span class="cm-variable">Qt</span><span class="cm-operator">/</span><span class="cm-variable">mysql</span><span class="cm-operator">-</span><span class="cm-number">5.7.30</span><span class="cm-operator">-</span><span class="cm-variable">winx64</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -27.9958px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt" style="left: 0px; width: 19px;">2</div></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span class="cm-variable">INCLUDEPATH</span> <span class="cm-operator">+=</span> <span class="cm-variable">$$path</span><span class="cm-operator">/</span><span class="cm-variable">include</span></span></pre></div><div style="position: relative;"><div class="CodeMirror-gutter-wrapper" style="left: -27.9958px;"><div class="CodeMirror-linenumber CodeMirror-gutter-elt CodeMirror-linenumber-
2022-06-02 06:36:30 +00:00
<script>(function(){var e=document.body.parentElement,t=[],n=null,i=document.body.classList.contains("typora-export-collapse-outline"),r=function(e,t,n){document.addEventListener(e,function(e){if(!e.defaultPrevented)for(var i=e.target;i&&i!=this;i=i.parentNode)if(i.matches(t)){!1===n.call(i,e)&&(e.preventDefault(),e.stopPropagation());break}},!1)};function o(){return e.scrollTop}r("click",".outline-expander",function(e){var t=this.closest(".outline-item-wrapper").classList;return t.contains("outline-item-open")?t.remove("outline-item-open"):t.add("outline-item-open"),d(),!1}),r("click",".outline-item",function(e){var t=this.querySelector(".outline-label");if(location.hash="#"+t.getAttribute("href"),i){var n=this.closest(".outline-item-wrapper").classList;n.contains("outline-item-open")||n.add("outline-item-open"),c(),n.add("outline-item-active")}});var a,s,l=function(){var e=o();n=null;for(var i=0;i<t.length&&t[i][1]-e<60;i++)n=t[i]},c=function(){document.querySelectorAll(".outline-item-active").forEach(e=>e.classList.remove("outline-item-active")),document.querySelectorAll(".outline-item-single.outline-item-open").forEach(e=>e.classList.remove("outline-item-open"))},d=function(){if(n){c();var e=document.querySelector('.outline-label[href="#'+(CSS.escape?CSS.escape(n[0]):n[0])+'"]');if(e)if(i){var t=e.closest(".outline-item-open>ul>.outline-item-wrapper");if(t)t.classList.add("outline-item-active");else{for(var r=(e=e.closest(".outline-item-wrapper")).parentElement.closest(".outline-item-wrapper");r;)r=(e=r).parentElement.closest(".outline-item-wrapper");e.classList.add("outline-item-active")}}else e.closest(".outline-item-wrapper").classList.add("outline-item-active")}};window.addEventListener("scroll",function(e){a&&clearTimeout(a),a=setTimeout(function(){l(),d()},300)});var u=function(){s=setTimeout(function(){!function(){t=[];var e=o();document.querySelector("#write").querySelectorAll("h1, h2, h3, h4, h5, h6").forEach(n=>{var i=n.getAttribute("id");t.push([i,e+n.getBoundingClientRect().y])})}(),l(),d()},300)};window.addEventListener("resize",function(e){s&&clearTimeout(s),u()}),u()})();</script></body>
2021-07-10 09:47:51 +00:00
</html>