├── .editorconfig ├── .gitignore ├── LICENSE ├── OnvifClient.nuspec ├── OnvifClient.sln ├── README.md ├── src ├── Common │ └── DataTypes.cs ├── Device │ ├── DataTypes.cs │ └── DeviceClient.cs ├── Imaging │ ├── DataTypes.cs │ └── ImagingClient.cs ├── Media │ ├── DataTypes.cs │ └── MediaClient.cs ├── OnvifClient.csproj ├── OnvifClientFactory.cs ├── Ptz │ ├── DataTypes.cs │ └── PTZClient.cs └── Security │ ├── SoapSecurityHeader.cs │ ├── SoapSecurityHeaderBehavior.cs │ └── SoapSecurityHeaderInspector.cs ├── test ├── OnvifTests.csproj └── Program.cs └── wsdl ├── common.xsd ├── devicemgmt.wsdl ├── imaging.wsdl ├── media.wsdl ├── onvif.xsd └── ptz.wsdl /.editorconfig: -------------------------------------------------------------------------------- 1 | # top-most EditorConfig file 2 | root = true 3 | 4 | # Baseline 5 | [*] 6 | charset = utf-8 7 | indent_style = tab 8 | trim_trailing_whitespace = true 9 | max_line_length = 180 10 | 11 | # JSON files 12 | [*.json] 13 | indent_style = space 14 | indent_size = 2 15 | 16 | # Dotnet code style settings: 17 | [*.{cs,vb}] 18 | indent_size = 8 19 | 20 | # Sort using and Import directives with System.* appearing first 21 | dotnet_sort_system_directives_first = true 22 | 23 | # Avoid "this." and "Me." if not necessary 24 | dotnet_style_qualification_for_field = false:suggestion 25 | dotnet_style_qualification_for_property = false:suggestion 26 | dotnet_style_qualification_for_method = false:suggestion 27 | dotnet_style_qualification_for_event = false:suggestion 28 | 29 | # Use language keywords instead of framework type names for type references 30 | dotnet_style_predefined_type_for_locals_parameters_members = true:suggestion 31 | dotnet_style_predefined_type_for_member_access = true:suggestion 32 | 33 | # Suggest more modern language features when available 34 | dotnet_style_object_initializer = true:suggestion 35 | dotnet_style_collection_initializer = true:suggestion 36 | dotnet_style_coalesce_expression = true:suggestion 37 | dotnet_style_null_propagation = true:suggestion 38 | dotnet_style_explicit_tuple_names = true:suggestion 39 | 40 | # CSharp code style settings: 41 | [*.cs] 42 | 43 | # spaces before parens 44 | csharp_space_between_method_declaration_name_and_open_parenthesis = true 45 | csharp_space_between_method_call_name_and_opening_parenthesis = true 46 | csharp_space_after_keywords_in_control_flow_statements = true 47 | 48 | # Newline settings 49 | csharp_new_line_before_open_brace = methods 50 | csharp_new_line_before_else = false 51 | csharp_new_line_before_catch = false 52 | csharp_new_line_before_finally = false 53 | csharp_new_line_before_members_in_object_initializers = false 54 | csharp_new_line_before_members_in_anonymous_types = false 55 | 56 | # Switch indentation 57 | csharp_indent_switch_labels = false 58 | 59 | # Prefer "var" everywhere it's apparent 60 | csharp_style_var_for_built_in_types = true:none 61 | csharp_style_var_when_type_is_apparent = true:suggestion 62 | csharp_style_var_elsewhere = true:none 63 | 64 | # Prefer method-like constructs to have a block body 65 | csharp_style_expression_bodied_methods = false:none 66 | csharp_style_expression_bodied_constructors = false:none 67 | csharp_style_expression_bodied_operators = false:none 68 | 69 | # Prefer property-like constructs to have an expression-body 70 | csharp_style_expression_bodied_properties = true:none 71 | csharp_style_expression_bodied_indexers = true:none 72 | csharp_style_expression_bodied_accessors = true:none 73 | 74 | # Suggest more modern language features when available 75 | csharp_style_pattern_matching_over_is_with_cast_check = true:suggestion 76 | csharp_style_pattern_matching_over_as_with_null_check = true:suggestion 77 | csharp_style_inlined_variable_declaration = true:suggestion 78 | csharp_style_throw_expression = true:suggestion 79 | csharp_style_conditional_delegate_call = true:suggestion -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | ## Ignore Visual Studio temporary files, build results, and 2 | ## files generated by popular Visual Studio add-ons. 3 | ## 4 | ## Get latest from https://github.com/github/gitignore/blob/master/VisualStudio.gitignore 5 | 6 | # User-specific files 7 | *.suo 8 | *.user 9 | *.userosscache 10 | *.sln.docstates 11 | 12 | # User-specific files (MonoDevelop/Xamarin Studio) 13 | *.userprefs 14 | 15 | # Build results 16 | [Dd]ebug/ 17 | [Dd]ebugPublic/ 18 | [Rr]elease/ 19 | [Rr]eleases/ 20 | x64/ 21 | x86/ 22 | bld/ 23 | [Bb]in/ 24 | [Oo]bj/ 25 | [Ll]og/ 26 | 27 | # Visual Studio 2015/2017 cache/options directory 28 | .vs/ 29 | # Uncomment if you have tasks that create the project's static files in wwwroot 30 | #wwwroot/ 31 | 32 | # Visual Studio 2017 auto generated files 33 | Generated\ Files/ 34 | 35 | # MSTest test Results 36 | [Tt]est[Rr]esult*/ 37 | [Bb]uild[Ll]og.* 38 | 39 | # NUNIT 40 | *.VisualState.xml 41 | TestResult.xml 42 | 43 | # Build Results of an ATL Project 44 | [Dd]ebugPS/ 45 | [Rr]eleasePS/ 46 | dlldata.c 47 | 48 | # Benchmark Results 49 | BenchmarkDotNet.Artifacts/ 50 | 51 | # .NET Core 52 | project.lock.json 53 | project.fragment.lock.json 54 | artifacts/ 55 | **/Properties/launchSettings.json 56 | 57 | # StyleCop 58 | StyleCopReport.xml 59 | 60 | # Files built by Visual Studio 61 | *_i.c 62 | *_p.c 63 | *_i.h 64 | *.ilk 65 | *.meta 66 | *.obj 67 | *.iobj 68 | *.pch 69 | *.pdb 70 | *.ipdb 71 | *.pgc 72 | *.pgd 73 | *.rsp 74 | *.sbr 75 | *.tlb 76 | *.tli 77 | *.tlh 78 | *.tmp 79 | *.tmp_proj 80 | *.log 81 | *.vspscc 82 | *.vssscc 83 | .builds 84 | *.pidb 85 | *.svclog 86 | *.scc 87 | 88 | # Chutzpah Test files 89 | _Chutzpah* 90 | 91 | # Visual C++ cache files 92 | ipch/ 93 | *.aps 94 | *.ncb 95 | *.opendb 96 | *.opensdf 97 | *.sdf 98 | *.cachefile 99 | *.VC.db 100 | *.VC.VC.opendb 101 | 102 | # Visual Studio profiler 103 | *.psess 104 | *.vsp 105 | *.vspx 106 | *.sap 107 | 108 | # Visual Studio Trace Files 109 | *.e2e 110 | 111 | # TFS 2012 Local Workspace 112 | $tf/ 113 | 114 | # Guidance Automation Toolkit 115 | *.gpState 116 | 117 | # ReSharper is a .NET coding add-in 118 | _ReSharper*/ 119 | *.[Rr]e[Ss]harper 120 | *.DotSettings.user 121 | 122 | # JustCode is a .NET coding add-in 123 | .JustCode 124 | 125 | # TeamCity is a build add-in 126 | _TeamCity* 127 | 128 | # DotCover is a Code Coverage Tool 129 | *.dotCover 130 | 131 | # AxoCover is a Code Coverage Tool 132 | .axoCover/* 133 | !.axoCover/settings.json 134 | 135 | # Visual Studio code coverage results 136 | *.coverage 137 | *.coveragexml 138 | 139 | # NCrunch 140 | _NCrunch_* 141 | .*crunch*.local.xml 142 | nCrunchTemp_* 143 | 144 | # MightyMoose 145 | *.mm.* 146 | AutoTest.Net/ 147 | 148 | # Web workbench (sass) 149 | .sass-cache/ 150 | 151 | # Installshield output folder 152 | [Ee]xpress/ 153 | 154 | # DocProject is a documentation generator add-in 155 | DocProject/buildhelp/ 156 | DocProject/Help/*.HxT 157 | DocProject/Help/*.HxC 158 | DocProject/Help/*.hhc 159 | DocProject/Help/*.hhk 160 | DocProject/Help/*.hhp 161 | DocProject/Help/Html2 162 | DocProject/Help/html 163 | 164 | # Click-Once directory 165 | publish/ 166 | 167 | # Publish Web Output 168 | *.[Pp]ublish.xml 169 | *.azurePubxml 170 | # Note: Comment the next line if you want to checkin your web deploy settings, 171 | # but database connection strings (with potential passwords) will be unencrypted 172 | *.pubxml 173 | *.publishproj 174 | 175 | # Microsoft Azure Web App publish settings. Comment the next line if you want to 176 | # checkin your Azure Web App publish settings, but sensitive information contained 177 | # in these scripts will be unencrypted 178 | PublishScripts/ 179 | 180 | # NuGet Packages 181 | *.nupkg 182 | # The packages folder can be ignored because of Package Restore 183 | **/[Pp]ackages/* 184 | # except build/, which is used as an MSBuild target. 185 | !**/[Pp]ackages/build/ 186 | # Uncomment if necessary however generally it will be regenerated when needed 187 | #!**/[Pp]ackages/repositories.config 188 | # NuGet v3's project.json files produces more ignorable files 189 | *.nuget.props 190 | *.nuget.targets 191 | 192 | # Microsoft Azure Build Output 193 | csx/ 194 | *.build.csdef 195 | 196 | # Microsoft Azure Emulator 197 | ecf/ 198 | rcf/ 199 | 200 | # Windows Store app package directories and files 201 | AppPackages/ 202 | BundleArtifacts/ 203 | Package.StoreAssociation.xml 204 | _pkginfo.txt 205 | *.appx 206 | 207 | # Visual Studio cache files 208 | # files ending in .cache can be ignored 209 | *.[Cc]ache 210 | # but keep track of directories ending in .cache 211 | !*.[Cc]ache/ 212 | 213 | # Others 214 | ClientBin/ 215 | ~$* 216 | *~ 217 | *.dbmdl 218 | *.dbproj.schemaview 219 | *.jfm 220 | *.pfx 221 | *.publishsettings 222 | orleans.codegen.cs 223 | 224 | # Including strong name files can present a security risk 225 | # (https://github.com/github/gitignore/pull/2483#issue-259490424) 226 | #*.snk 227 | 228 | # Since there are multiple workflows, uncomment next line to ignore bower_components 229 | # (https://github.com/github/gitignore/pull/1529#issuecomment-104372622) 230 | #bower_components/ 231 | 232 | # RIA/Silverlight projects 233 | Generated_Code/ 234 | 235 | # Backup & report files from converting an old project file 236 | # to a newer Visual Studio version. Backup files are not needed, 237 | # because we have git ;-) 238 | _UpgradeReport_Files/ 239 | Backup*/ 240 | UpgradeLog*.XML 241 | UpgradeLog*.htm 242 | ServiceFabricBackup/ 243 | *.rptproj.bak 244 | 245 | # SQL Server files 246 | *.mdf 247 | *.ldf 248 | *.ndf 249 | 250 | # Business Intelligence projects 251 | *.rdl.data 252 | *.bim.layout 253 | *.bim_*.settings 254 | *.rptproj.rsuser 255 | 256 | # Microsoft Fakes 257 | FakesAssemblies/ 258 | 259 | # GhostDoc plugin setting file 260 | *.GhostDoc.xml 261 | 262 | # Node.js Tools for Visual Studio 263 | .ntvs_analysis.dat 264 | node_modules/ 265 | 266 | # Visual Studio 6 build log 267 | *.plg 268 | 269 | # Visual Studio 6 workspace options file 270 | *.opt 271 | 272 | # Visual Studio 6 auto-generated workspace file (contains which files were open etc.) 273 | *.vbw 274 | 275 | # Visual Studio LightSwitch build output 276 | **/*.HTMLClient/GeneratedArtifacts 277 | **/*.DesktopClient/GeneratedArtifacts 278 | **/*.DesktopClient/ModelManifest.xml 279 | **/*.Server/GeneratedArtifacts 280 | **/*.Server/ModelManifest.xml 281 | _Pvt_Extensions 282 | 283 | # Paket dependency manager 284 | .paket/paket.exe 285 | paket-files/ 286 | 287 | # FAKE - F# Make 288 | .fake/ 289 | 290 | # JetBrains Rider 291 | .idea/ 292 | *.sln.iml 293 | 294 | # CodeRush 295 | .cr/ 296 | 297 | # Python Tools for Visual Studio (PTVS) 298 | __pycache__/ 299 | *.pyc 300 | 301 | # Cake - Uncomment if you are using it 302 | # tools/** 303 | # !tools/packages.config 304 | 305 | # Tabs Studio 306 | *.tss 307 | 308 | # Telerik's JustMock configuration file 309 | *.jmconfig 310 | 311 | # BizTalk build output 312 | *.btp.cs 313 | *.btm.cs 314 | *.odx.cs 315 | *.xsd.cs 316 | 317 | # OpenCover UI analysis results 318 | OpenCover/ 319 | 320 | # Azure Stream Analytics local run output 321 | ASALocalRun/ 322 | 323 | # MSBuild Binary and Structured Log 324 | *.binlog 325 | 326 | # NVidia Nsight GPU debugger configuration file 327 | *.nvuser 328 | 329 | # MFractors (Xamarin productivity tool) working folder 330 | .mfractor/ 331 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | MIT License 2 | 3 | Copyright (c) 2018 Mictlanix 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. 22 | -------------------------------------------------------------------------------- /OnvifClient.nuspec: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | Mictlanix.DotNet.OnvifClient 5 | 0.0.3 6 | Mictlanix ONVIF Client 7 | Eddy Zavaleta 8 | 9 | https://github.com/mictlanix/onvif/blob/master/LICENSE 10 | https://github.com/mictlanix/onvif 11 | false 12 | A lightweight ONVIF Client library. 13 | PasswordDigest security added. 14 | Copyright © 2018 Mictlanix SAS de CV 15 | ipcam onvif ptz 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | -------------------------------------------------------------------------------- /OnvifClient.sln: -------------------------------------------------------------------------------- 1 | 2 | Microsoft Visual Studio Solution File, Format Version 12.00 3 | # Visual Studio 15 4 | Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "OnvifClient", "src\OnvifClient.csproj", "{F0E0E735-2C6B-47EA-9F5C-DCA3142DE301}" 5 | EndProject 6 | Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "OnvifTests", "test\OnvifTests.csproj", "{B04385D2-44DF-4C6F-B66A-E2633EE0FE55}" 7 | EndProject 8 | Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Solution Items", "Solution Items", "{453F122D-22B3-4873-BF49-F2ABF8348440}" 9 | ProjectSection(SolutionItems) = preProject 10 | .editorconfig = .editorconfig 11 | EndProjectSection 12 | EndProject 13 | Global 14 | GlobalSection(SolutionConfigurationPlatforms) = preSolution 15 | Debug|Any CPU = Debug|Any CPU 16 | Release|Any CPU = Release|Any CPU 17 | EndGlobalSection 18 | GlobalSection(ProjectConfigurationPlatforms) = postSolution 19 | {F0E0E735-2C6B-47EA-9F5C-DCA3142DE301}.Debug|Any CPU.ActiveCfg = Debug|Any CPU 20 | {F0E0E735-2C6B-47EA-9F5C-DCA3142DE301}.Debug|Any CPU.Build.0 = Debug|Any CPU 21 | {F0E0E735-2C6B-47EA-9F5C-DCA3142DE301}.Release|Any CPU.ActiveCfg = Release|Any CPU 22 | {F0E0E735-2C6B-47EA-9F5C-DCA3142DE301}.Release|Any CPU.Build.0 = Release|Any CPU 23 | {B04385D2-44DF-4C6F-B66A-E2633EE0FE55}.Debug|Any CPU.ActiveCfg = Debug|Any CPU 24 | {B04385D2-44DF-4C6F-B66A-E2633EE0FE55}.Debug|Any CPU.Build.0 = Debug|Any CPU 25 | {B04385D2-44DF-4C6F-B66A-E2633EE0FE55}.Release|Any CPU.ActiveCfg = Release|Any CPU 26 | {B04385D2-44DF-4C6F-B66A-E2633EE0FE55}.Release|Any CPU.Build.0 = Release|Any CPU 27 | EndGlobalSection 28 | GlobalSection(MonoDevelopProperties) = preSolution 29 | version = 0.0.3 30 | description = A lightweight ONVIF Client library. 31 | EndGlobalSection 32 | EndGlobal 33 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # onvif 2 | A lightweight ONVIF Client library. 3 | -------------------------------------------------------------------------------- /src/Device/DataTypes.cs: -------------------------------------------------------------------------------- 1 | using Mictlanix.DotNet.Onvif.Common; 2 | 3 | namespace Mictlanix.DotNet.Onvif.Device { 4 | /// 5 | [System.CodeDom.Compiler.GeneratedCodeAttribute ("dotnet-svcutil", "1.0.3")] 6 | [System.Diagnostics.DebuggerStepThroughAttribute ()] 7 | [System.Xml.Serialization.XmlTypeAttribute (Namespace = "http://www.onvif.org/ver10/device/wsdl")] 8 | public partial class Service { 9 | 10 | private string namespaceField; 11 | 12 | private string xAddrField; 13 | 14 | private System.Xml.Linq.XElement capabilitiesField; 15 | 16 | private OnvifVersion versionField; 17 | 18 | private System.Xml.Linq.XElement [] anyField; 19 | 20 | /// 21 | [System.Xml.Serialization.XmlElementAttribute (DataType = "anyURI", Order = 0)] 22 | public string Namespace { 23 | get { 24 | return this.namespaceField; 25 | } 26 | set { 27 | this.namespaceField = value; 28 | } 29 | } 30 | 31 | /// 32 | [System.Xml.Serialization.XmlElementAttribute (DataType = "anyURI", Order = 1)] 33 | public string XAddr { 34 | get { 35 | return this.xAddrField; 36 | } 37 | set { 38 | this.xAddrField = value; 39 | } 40 | } 41 | 42 | /// 43 | [System.Xml.Serialization.XmlElementAttribute (Order = 2)] 44 | public System.Xml.Linq.XElement Capabilities { 45 | get { 46 | return this.capabilitiesField; 47 | } 48 | set { 49 | this.capabilitiesField = value; 50 | } 51 | } 52 | 53 | /// 54 | [System.Xml.Serialization.XmlElementAttribute (Order = 3)] 55 | public OnvifVersion Version { 56 | get { 57 | return this.versionField; 58 | } 59 | set { 60 | this.versionField = value; 61 | } 62 | } 63 | 64 | /// 65 | [System.Xml.Serialization.XmlAnyElementAttribute (Order = 4)] 66 | public System.Xml.Linq.XElement [] Any { 67 | get { 68 | return this.anyField; 69 | } 70 | set { 71 | this.anyField = value; 72 | } 73 | } 74 | } 75 | 76 | /// 77 | [System.CodeDom.Compiler.GeneratedCodeAttribute ("dotnet-svcutil", "1.0.3")] 78 | [System.Diagnostics.DebuggerStepThroughAttribute ()] 79 | [System.Xml.Serialization.XmlTypeAttribute (Namespace = "http://www.onvif.org/ver10/device/wsdl")] 80 | public partial class UserCredential { 81 | 82 | private string userNameField; 83 | 84 | private string passwordField; 85 | 86 | private UserCredentialExtension extensionField; 87 | 88 | /// 89 | [System.Xml.Serialization.XmlElementAttribute (Order = 0)] 90 | public string UserName { 91 | get { 92 | return this.userNameField; 93 | } 94 | set { 95 | this.userNameField = value; 96 | } 97 | } 98 | 99 | /// 100 | [System.Xml.Serialization.XmlElementAttribute (Order = 1)] 101 | public string Password { 102 | get { 103 | return this.passwordField; 104 | } 105 | set { 106 | this.passwordField = value; 107 | } 108 | } 109 | 110 | /// 111 | [System.Xml.Serialization.XmlElementAttribute (Order = 2)] 112 | public UserCredentialExtension Extension { 113 | get { 114 | return this.extensionField; 115 | } 116 | set { 117 | this.extensionField = value; 118 | } 119 | } 120 | } 121 | 122 | /// 123 | [System.CodeDom.Compiler.GeneratedCodeAttribute ("dotnet-svcutil", "1.0.3")] 124 | [System.Diagnostics.DebuggerStepThroughAttribute ()] 125 | [System.Xml.Serialization.XmlTypeAttribute (AnonymousType = true, Namespace = "http://www.onvif.org/ver10/device/wsdl")] 126 | public partial class UserCredentialExtension { 127 | 128 | private System.Xml.Linq.XElement [] anyField; 129 | 130 | /// 131 | [System.Xml.Serialization.XmlAnyElementAttribute (Order = 0)] 132 | public System.Xml.Linq.XElement [] Any { 133 | get { 134 | return this.anyField; 135 | } 136 | set { 137 | this.anyField = value; 138 | } 139 | } 140 | } 141 | 142 | /// 143 | [System.CodeDom.Compiler.GeneratedCodeAttribute ("dotnet-svcutil", "1.0.3")] 144 | [System.Diagnostics.DebuggerStepThroughAttribute ()] 145 | [System.Xml.Serialization.XmlTypeAttribute (Namespace = "http://www.onvif.org/ver10/device/wsdl")] 146 | public partial class StorageConfigurationData { 147 | 148 | private string localPathField; 149 | 150 | private string storageUriField; 151 | 152 | private UserCredential userField; 153 | 154 | private StorageConfigurationDataExtension extensionField; 155 | 156 | private string typeField; 157 | 158 | /// 159 | [System.Xml.Serialization.XmlElementAttribute (DataType = "anyURI", Order = 0)] 160 | public string LocalPath { 161 | get { 162 | return this.localPathField; 163 | } 164 | set { 165 | this.localPathField = value; 166 | } 167 | } 168 | 169 | /// 170 | [System.Xml.Serialization.XmlElementAttribute (DataType = "anyURI", Order = 1)] 171 | public string StorageUri { 172 | get { 173 | return this.storageUriField; 174 | } 175 | set { 176 | this.storageUriField = value; 177 | } 178 | } 179 | 180 | /// 181 | [System.Xml.Serialization.XmlElementAttribute (Order = 2)] 182 | public UserCredential User { 183 | get { 184 | return this.userField; 185 | } 186 | set { 187 | this.userField = value; 188 | } 189 | } 190 | 191 | /// 192 | [System.Xml.Serialization.XmlElementAttribute (Order = 3)] 193 | public StorageConfigurationDataExtension Extension { 194 | get { 195 | return this.extensionField; 196 | } 197 | set { 198 | this.extensionField = value; 199 | } 200 | } 201 | 202 | /// 203 | [System.Xml.Serialization.XmlAttributeAttribute ()] 204 | public string type { 205 | get { 206 | return this.typeField; 207 | } 208 | set { 209 | this.typeField = value; 210 | } 211 | } 212 | } 213 | 214 | /// 215 | [System.CodeDom.Compiler.GeneratedCodeAttribute ("dotnet-svcutil", "1.0.3")] 216 | [System.Diagnostics.DebuggerStepThroughAttribute ()] 217 | [System.Xml.Serialization.XmlTypeAttribute (AnonymousType = true, Namespace = "http://www.onvif.org/ver10/device/wsdl")] 218 | public partial class StorageConfigurationDataExtension { 219 | 220 | private System.Xml.Linq.XElement [] anyField; 221 | 222 | /// 223 | [System.Xml.Serialization.XmlAnyElementAttribute (Order = 0)] 224 | public System.Xml.Linq.XElement [] Any { 225 | get { 226 | return this.anyField; 227 | } 228 | set { 229 | this.anyField = value; 230 | } 231 | } 232 | } 233 | 234 | /// 235 | [System.CodeDom.Compiler.GeneratedCodeAttribute ("dotnet-svcutil", "1.0.3")] 236 | [System.Diagnostics.DebuggerStepThroughAttribute ()] 237 | [System.Xml.Serialization.XmlTypeAttribute (Namespace = "http://www.onvif.org/ver10/device/wsdl")] 238 | public partial class StorageConfiguration : DeviceEntity { 239 | 240 | private StorageConfigurationData dataField; 241 | 242 | /// 243 | [System.Xml.Serialization.XmlElementAttribute (Order = 0)] 244 | public StorageConfigurationData Data { 245 | get { 246 | return this.dataField; 247 | } 248 | set { 249 | this.dataField = value; 250 | } 251 | } 252 | } 253 | 254 | /// 255 | [System.CodeDom.Compiler.GeneratedCodeAttribute ("dotnet-svcutil", "1.0.3")] 256 | [System.Diagnostics.DebuggerStepThroughAttribute ()] 257 | [System.Xml.Serialization.XmlTypeAttribute (Namespace = "http://www.onvif.org/ver10/device/wsdl")] 258 | public partial class MiscCapabilities { 259 | 260 | private string [] auxiliaryCommandsField; 261 | 262 | /// 263 | [System.Xml.Serialization.XmlAttributeAttribute ()] 264 | public string [] AuxiliaryCommands { 265 | get { 266 | return this.auxiliaryCommandsField; 267 | } 268 | set { 269 | this.auxiliaryCommandsField = value; 270 | } 271 | } 272 | } 273 | 274 | /// 275 | [System.CodeDom.Compiler.GeneratedCodeAttribute ("dotnet-svcutil", "1.0.3")] 276 | [System.Diagnostics.DebuggerStepThroughAttribute ()] 277 | [System.Xml.Serialization.XmlTypeAttribute (Namespace = "http://www.onvif.org/ver10/device/wsdl")] 278 | public partial class SystemCapabilities { 279 | 280 | private bool discoveryResolveField; 281 | 282 | private bool discoveryResolveFieldSpecified; 283 | 284 | private bool discoveryByeField; 285 | 286 | private bool discoveryByeFieldSpecified; 287 | 288 | private bool remoteDiscoveryField; 289 | 290 | private bool remoteDiscoveryFieldSpecified; 291 | 292 | private bool systemBackupField; 293 | 294 | private bool systemBackupFieldSpecified; 295 | 296 | private bool systemLoggingField; 297 | 298 | private bool systemLoggingFieldSpecified; 299 | 300 | private bool firmwareUpgradeField; 301 | 302 | private bool firmwareUpgradeFieldSpecified; 303 | 304 | private bool httpFirmwareUpgradeField; 305 | 306 | private bool httpFirmwareUpgradeFieldSpecified; 307 | 308 | private bool httpSystemBackupField; 309 | 310 | private bool httpSystemBackupFieldSpecified; 311 | 312 | private bool httpSystemLoggingField; 313 | 314 | private bool httpSystemLoggingFieldSpecified; 315 | 316 | private bool httpSupportInformationField; 317 | 318 | private bool httpSupportInformationFieldSpecified; 319 | 320 | private bool storageConfigurationField; 321 | 322 | private bool storageConfigurationFieldSpecified; 323 | 324 | private int maxStorageConfigurationsField; 325 | 326 | private bool maxStorageConfigurationsFieldSpecified; 327 | 328 | private int geoLocationEntriesField; 329 | 330 | private bool geoLocationEntriesFieldSpecified; 331 | 332 | private string [] autoGeoField; 333 | 334 | private string [] storageTypesSupportedField; 335 | 336 | /// 337 | [System.Xml.Serialization.XmlAttributeAttribute ()] 338 | public bool DiscoveryResolve { 339 | get { 340 | return this.discoveryResolveField; 341 | } 342 | set { 343 | this.discoveryResolveField = value; 344 | } 345 | } 346 | 347 | /// 348 | [System.Xml.Serialization.XmlIgnoreAttribute ()] 349 | public bool DiscoveryResolveSpecified { 350 | get { 351 | return this.discoveryResolveFieldSpecified; 352 | } 353 | set { 354 | this.discoveryResolveFieldSpecified = value; 355 | } 356 | } 357 | 358 | /// 359 | [System.Xml.Serialization.XmlAttributeAttribute ()] 360 | public bool DiscoveryBye { 361 | get { 362 | return this.discoveryByeField; 363 | } 364 | set { 365 | this.discoveryByeField = value; 366 | } 367 | } 368 | 369 | /// 370 | [System.Xml.Serialization.XmlIgnoreAttribute ()] 371 | public bool DiscoveryByeSpecified { 372 | get { 373 | return this.discoveryByeFieldSpecified; 374 | } 375 | set { 376 | this.discoveryByeFieldSpecified = value; 377 | } 378 | } 379 | 380 | /// 381 | [System.Xml.Serialization.XmlAttributeAttribute ()] 382 | public bool RemoteDiscovery { 383 | get { 384 | return this.remoteDiscoveryField; 385 | } 386 | set { 387 | this.remoteDiscoveryField = value; 388 | } 389 | } 390 | 391 | /// 392 | [System.Xml.Serialization.XmlIgnoreAttribute ()] 393 | public bool RemoteDiscoverySpecified { 394 | get { 395 | return this.remoteDiscoveryFieldSpecified; 396 | } 397 | set { 398 | this.remoteDiscoveryFieldSpecified = value; 399 | } 400 | } 401 | 402 | /// 403 | [System.Xml.Serialization.XmlAttributeAttribute ()] 404 | public bool SystemBackup { 405 | get { 406 | return this.systemBackupField; 407 | } 408 | set { 409 | this.systemBackupField = value; 410 | } 411 | } 412 | 413 | /// 414 | [System.Xml.Serialization.XmlIgnoreAttribute ()] 415 | public bool SystemBackupSpecified { 416 | get { 417 | return this.systemBackupFieldSpecified; 418 | } 419 | set { 420 | this.systemBackupFieldSpecified = value; 421 | } 422 | } 423 | 424 | /// 425 | [System.Xml.Serialization.XmlAttributeAttribute ()] 426 | public bool SystemLogging { 427 | get { 428 | return this.systemLoggingField; 429 | } 430 | set { 431 | this.systemLoggingField = value; 432 | } 433 | } 434 | 435 | /// 436 | [System.Xml.Serialization.XmlIgnoreAttribute ()] 437 | public bool SystemLoggingSpecified { 438 | get { 439 | return this.systemLoggingFieldSpecified; 440 | } 441 | set { 442 | this.systemLoggingFieldSpecified = value; 443 | } 444 | } 445 | 446 | /// 447 | [System.Xml.Serialization.XmlAttributeAttribute ()] 448 | public bool FirmwareUpgrade { 449 | get { 450 | return this.firmwareUpgradeField; 451 | } 452 | set { 453 | this.firmwareUpgradeField = value; 454 | } 455 | } 456 | 457 | /// 458 | [System.Xml.Serialization.XmlIgnoreAttribute ()] 459 | public bool FirmwareUpgradeSpecified { 460 | get { 461 | return this.firmwareUpgradeFieldSpecified; 462 | } 463 | set { 464 | this.firmwareUpgradeFieldSpecified = value; 465 | } 466 | } 467 | 468 | /// 469 | [System.Xml.Serialization.XmlAttributeAttribute ()] 470 | public bool HttpFirmwareUpgrade { 471 | get { 472 | return this.httpFirmwareUpgradeField; 473 | } 474 | set { 475 | this.httpFirmwareUpgradeField = value; 476 | } 477 | } 478 | 479 | /// 480 | [System.Xml.Serialization.XmlIgnoreAttribute ()] 481 | public bool HttpFirmwareUpgradeSpecified { 482 | get { 483 | return this.httpFirmwareUpgradeFieldSpecified; 484 | } 485 | set { 486 | this.httpFirmwareUpgradeFieldSpecified = value; 487 | } 488 | } 489 | 490 | /// 491 | [System.Xml.Serialization.XmlAttributeAttribute ()] 492 | public bool HttpSystemBackup { 493 | get { 494 | return this.httpSystemBackupField; 495 | } 496 | set { 497 | this.httpSystemBackupField = value; 498 | } 499 | } 500 | 501 | /// 502 | [System.Xml.Serialization.XmlIgnoreAttribute ()] 503 | public bool HttpSystemBackupSpecified { 504 | get { 505 | return this.httpSystemBackupFieldSpecified; 506 | } 507 | set { 508 | this.httpSystemBackupFieldSpecified = value; 509 | } 510 | } 511 | 512 | /// 513 | [System.Xml.Serialization.XmlAttributeAttribute ()] 514 | public bool HttpSystemLogging { 515 | get { 516 | return this.httpSystemLoggingField; 517 | } 518 | set { 519 | this.httpSystemLoggingField = value; 520 | } 521 | } 522 | 523 | /// 524 | [System.Xml.Serialization.XmlIgnoreAttribute ()] 525 | public bool HttpSystemLoggingSpecified { 526 | get { 527 | return this.httpSystemLoggingFieldSpecified; 528 | } 529 | set { 530 | this.httpSystemLoggingFieldSpecified = value; 531 | } 532 | } 533 | 534 | /// 535 | [System.Xml.Serialization.XmlAttributeAttribute ()] 536 | public bool HttpSupportInformation { 537 | get { 538 | return this.httpSupportInformationField; 539 | } 540 | set { 541 | this.httpSupportInformationField = value; 542 | } 543 | } 544 | 545 | /// 546 | [System.Xml.Serialization.XmlIgnoreAttribute ()] 547 | public bool HttpSupportInformationSpecified { 548 | get { 549 | return this.httpSupportInformationFieldSpecified; 550 | } 551 | set { 552 | this.httpSupportInformationFieldSpecified = value; 553 | } 554 | } 555 | 556 | /// 557 | [System.Xml.Serialization.XmlAttributeAttribute ()] 558 | public bool StorageConfiguration { 559 | get { 560 | return this.storageConfigurationField; 561 | } 562 | set { 563 | this.storageConfigurationField = value; 564 | } 565 | } 566 | 567 | /// 568 | [System.Xml.Serialization.XmlIgnoreAttribute ()] 569 | public bool StorageConfigurationSpecified { 570 | get { 571 | return this.storageConfigurationFieldSpecified; 572 | } 573 | set { 574 | this.storageConfigurationFieldSpecified = value; 575 | } 576 | } 577 | 578 | /// 579 | [System.Xml.Serialization.XmlAttributeAttribute ()] 580 | public int MaxStorageConfigurations { 581 | get { 582 | return this.maxStorageConfigurationsField; 583 | } 584 | set { 585 | this.maxStorageConfigurationsField = value; 586 | } 587 | } 588 | 589 | /// 590 | [System.Xml.Serialization.XmlIgnoreAttribute ()] 591 | public bool MaxStorageConfigurationsSpecified { 592 | get { 593 | return this.maxStorageConfigurationsFieldSpecified; 594 | } 595 | set { 596 | this.maxStorageConfigurationsFieldSpecified = value; 597 | } 598 | } 599 | 600 | /// 601 | [System.Xml.Serialization.XmlAttributeAttribute ()] 602 | public int GeoLocationEntries { 603 | get { 604 | return this.geoLocationEntriesField; 605 | } 606 | set { 607 | this.geoLocationEntriesField = value; 608 | } 609 | } 610 | 611 | /// 612 | [System.Xml.Serialization.XmlIgnoreAttribute ()] 613 | public bool GeoLocationEntriesSpecified { 614 | get { 615 | return this.geoLocationEntriesFieldSpecified; 616 | } 617 | set { 618 | this.geoLocationEntriesFieldSpecified = value; 619 | } 620 | } 621 | 622 | /// 623 | [System.Xml.Serialization.XmlAttributeAttribute ()] 624 | public string [] AutoGeo { 625 | get { 626 | return this.autoGeoField; 627 | } 628 | set { 629 | this.autoGeoField = value; 630 | } 631 | } 632 | 633 | /// 634 | [System.Xml.Serialization.XmlAttributeAttribute ()] 635 | public string [] StorageTypesSupported { 636 | get { 637 | return this.storageTypesSupportedField; 638 | } 639 | set { 640 | this.storageTypesSupportedField = value; 641 | } 642 | } 643 | } 644 | 645 | /// 646 | [System.CodeDom.Compiler.GeneratedCodeAttribute ("dotnet-svcutil", "1.0.3")] 647 | [System.Diagnostics.DebuggerStepThroughAttribute ()] 648 | [System.Xml.Serialization.XmlTypeAttribute (Namespace = "http://www.onvif.org/ver10/device/wsdl")] 649 | public partial class SecurityCapabilities { 650 | 651 | private bool tLS10Field; 652 | 653 | private bool tLS10FieldSpecified; 654 | 655 | private bool tLS11Field; 656 | 657 | private bool tLS11FieldSpecified; 658 | 659 | private bool tLS12Field; 660 | 661 | private bool tLS12FieldSpecified; 662 | 663 | private bool onboardKeyGenerationField; 664 | 665 | private bool onboardKeyGenerationFieldSpecified; 666 | 667 | private bool accessPolicyConfigField; 668 | 669 | private bool accessPolicyConfigFieldSpecified; 670 | 671 | private bool defaultAccessPolicyField; 672 | 673 | private bool defaultAccessPolicyFieldSpecified; 674 | 675 | private bool dot1XField; 676 | 677 | private bool dot1XFieldSpecified; 678 | 679 | private bool remoteUserHandlingField; 680 | 681 | private bool remoteUserHandlingFieldSpecified; 682 | 683 | private bool x509TokenField; 684 | 685 | private bool x509TokenFieldSpecified; 686 | 687 | private bool sAMLTokenField; 688 | 689 | private bool sAMLTokenFieldSpecified; 690 | 691 | private bool kerberosTokenField; 692 | 693 | private bool kerberosTokenFieldSpecified; 694 | 695 | private bool usernameTokenField; 696 | 697 | private bool usernameTokenFieldSpecified; 698 | 699 | private bool httpDigestField; 700 | 701 | private bool httpDigestFieldSpecified; 702 | 703 | private bool rELTokenField; 704 | 705 | private bool rELTokenFieldSpecified; 706 | 707 | private int [] supportedEAPMethodsField; 708 | 709 | private int maxUsersField; 710 | 711 | private bool maxUsersFieldSpecified; 712 | 713 | private int maxUserNameLengthField; 714 | 715 | private bool maxUserNameLengthFieldSpecified; 716 | 717 | private int maxPasswordLengthField; 718 | 719 | private bool maxPasswordLengthFieldSpecified; 720 | 721 | /// 722 | [System.Xml.Serialization.XmlAttributeAttribute ("TLS1.0")] 723 | public bool TLS10 { 724 | get { 725 | return this.tLS10Field; 726 | } 727 | set { 728 | this.tLS10Field = value; 729 | } 730 | } 731 | 732 | /// 733 | [System.Xml.Serialization.XmlIgnoreAttribute ()] 734 | public bool TLS10Specified { 735 | get { 736 | return this.tLS10FieldSpecified; 737 | } 738 | set { 739 | this.tLS10FieldSpecified = value; 740 | } 741 | } 742 | 743 | /// 744 | [System.Xml.Serialization.XmlAttributeAttribute ("TLS1.1")] 745 | public bool TLS11 { 746 | get { 747 | return this.tLS11Field; 748 | } 749 | set { 750 | this.tLS11Field = value; 751 | } 752 | } 753 | 754 | /// 755 | [System.Xml.Serialization.XmlIgnoreAttribute ()] 756 | public bool TLS11Specified { 757 | get { 758 | return this.tLS11FieldSpecified; 759 | } 760 | set { 761 | this.tLS11FieldSpecified = value; 762 | } 763 | } 764 | 765 | /// 766 | [System.Xml.Serialization.XmlAttributeAttribute ("TLS1.2")] 767 | public bool TLS12 { 768 | get { 769 | return this.tLS12Field; 770 | } 771 | set { 772 | this.tLS12Field = value; 773 | } 774 | } 775 | 776 | /// 777 | [System.Xml.Serialization.XmlIgnoreAttribute ()] 778 | public bool TLS12Specified { 779 | get { 780 | return this.tLS12FieldSpecified; 781 | } 782 | set { 783 | this.tLS12FieldSpecified = value; 784 | } 785 | } 786 | 787 | /// 788 | [System.Xml.Serialization.XmlAttributeAttribute ()] 789 | public bool OnboardKeyGeneration { 790 | get { 791 | return this.onboardKeyGenerationField; 792 | } 793 | set { 794 | this.onboardKeyGenerationField = value; 795 | } 796 | } 797 | 798 | /// 799 | [System.Xml.Serialization.XmlIgnoreAttribute ()] 800 | public bool OnboardKeyGenerationSpecified { 801 | get { 802 | return this.onboardKeyGenerationFieldSpecified; 803 | } 804 | set { 805 | this.onboardKeyGenerationFieldSpecified = value; 806 | } 807 | } 808 | 809 | /// 810 | [System.Xml.Serialization.XmlAttributeAttribute ()] 811 | public bool AccessPolicyConfig { 812 | get { 813 | return this.accessPolicyConfigField; 814 | } 815 | set { 816 | this.accessPolicyConfigField = value; 817 | } 818 | } 819 | 820 | /// 821 | [System.Xml.Serialization.XmlIgnoreAttribute ()] 822 | public bool AccessPolicyConfigSpecified { 823 | get { 824 | return this.accessPolicyConfigFieldSpecified; 825 | } 826 | set { 827 | this.accessPolicyConfigFieldSpecified = value; 828 | } 829 | } 830 | 831 | /// 832 | [System.Xml.Serialization.XmlAttributeAttribute ()] 833 | public bool DefaultAccessPolicy { 834 | get { 835 | return this.defaultAccessPolicyField; 836 | } 837 | set { 838 | this.defaultAccessPolicyField = value; 839 | } 840 | } 841 | 842 | /// 843 | [System.Xml.Serialization.XmlIgnoreAttribute ()] 844 | public bool DefaultAccessPolicySpecified { 845 | get { 846 | return this.defaultAccessPolicyFieldSpecified; 847 | } 848 | set { 849 | this.defaultAccessPolicyFieldSpecified = value; 850 | } 851 | } 852 | 853 | /// 854 | [System.Xml.Serialization.XmlAttributeAttribute ()] 855 | public bool Dot1X { 856 | get { 857 | return this.dot1XField; 858 | } 859 | set { 860 | this.dot1XField = value; 861 | } 862 | } 863 | 864 | /// 865 | [System.Xml.Serialization.XmlIgnoreAttribute ()] 866 | public bool Dot1XSpecified { 867 | get { 868 | return this.dot1XFieldSpecified; 869 | } 870 | set { 871 | this.dot1XFieldSpecified = value; 872 | } 873 | } 874 | 875 | /// 876 | [System.Xml.Serialization.XmlAttributeAttribute ()] 877 | public bool RemoteUserHandling { 878 | get { 879 | return this.remoteUserHandlingField; 880 | } 881 | set { 882 | this.remoteUserHandlingField = value; 883 | } 884 | } 885 | 886 | /// 887 | [System.Xml.Serialization.XmlIgnoreAttribute ()] 888 | public bool RemoteUserHandlingSpecified { 889 | get { 890 | return this.remoteUserHandlingFieldSpecified; 891 | } 892 | set { 893 | this.remoteUserHandlingFieldSpecified = value; 894 | } 895 | } 896 | 897 | /// 898 | [System.Xml.Serialization.XmlAttributeAttribute ("X.509Token")] 899 | public bool X509Token { 900 | get { 901 | return this.x509TokenField; 902 | } 903 | set { 904 | this.x509TokenField = value; 905 | } 906 | } 907 | 908 | /// 909 | [System.Xml.Serialization.XmlIgnoreAttribute ()] 910 | public bool X509TokenSpecified { 911 | get { 912 | return this.x509TokenFieldSpecified; 913 | } 914 | set { 915 | this.x509TokenFieldSpecified = value; 916 | } 917 | } 918 | 919 | /// 920 | [System.Xml.Serialization.XmlAttributeAttribute ()] 921 | public bool SAMLToken { 922 | get { 923 | return this.sAMLTokenField; 924 | } 925 | set { 926 | this.sAMLTokenField = value; 927 | } 928 | } 929 | 930 | /// 931 | [System.Xml.Serialization.XmlIgnoreAttribute ()] 932 | public bool SAMLTokenSpecified { 933 | get { 934 | return this.sAMLTokenFieldSpecified; 935 | } 936 | set { 937 | this.sAMLTokenFieldSpecified = value; 938 | } 939 | } 940 | 941 | /// 942 | [System.Xml.Serialization.XmlAttributeAttribute ()] 943 | public bool KerberosToken { 944 | get { 945 | return this.kerberosTokenField; 946 | } 947 | set { 948 | this.kerberosTokenField = value; 949 | } 950 | } 951 | 952 | /// 953 | [System.Xml.Serialization.XmlIgnoreAttribute ()] 954 | public bool KerberosTokenSpecified { 955 | get { 956 | return this.kerberosTokenFieldSpecified; 957 | } 958 | set { 959 | this.kerberosTokenFieldSpecified = value; 960 | } 961 | } 962 | 963 | /// 964 | [System.Xml.Serialization.XmlAttributeAttribute ()] 965 | public bool UsernameToken { 966 | get { 967 | return this.usernameTokenField; 968 | } 969 | set { 970 | this.usernameTokenField = value; 971 | } 972 | } 973 | 974 | /// 975 | [System.Xml.Serialization.XmlIgnoreAttribute ()] 976 | public bool UsernameTokenSpecified { 977 | get { 978 | return this.usernameTokenFieldSpecified; 979 | } 980 | set { 981 | this.usernameTokenFieldSpecified = value; 982 | } 983 | } 984 | 985 | /// 986 | [System.Xml.Serialization.XmlAttributeAttribute ()] 987 | public bool HttpDigest { 988 | get { 989 | return this.httpDigestField; 990 | } 991 | set { 992 | this.httpDigestField = value; 993 | } 994 | } 995 | 996 | /// 997 | [System.Xml.Serialization.XmlIgnoreAttribute ()] 998 | public bool HttpDigestSpecified { 999 | get { 1000 | return this.httpDigestFieldSpecified; 1001 | } 1002 | set { 1003 | this.httpDigestFieldSpecified = value; 1004 | } 1005 | } 1006 | 1007 | /// 1008 | [System.Xml.Serialization.XmlAttributeAttribute ()] 1009 | public bool RELToken { 1010 | get { 1011 | return this.rELTokenField; 1012 | } 1013 | set { 1014 | this.rELTokenField = value; 1015 | } 1016 | } 1017 | 1018 | /// 1019 | [System.Xml.Serialization.XmlIgnoreAttribute ()] 1020 | public bool RELTokenSpecified { 1021 | get { 1022 | return this.rELTokenFieldSpecified; 1023 | } 1024 | set { 1025 | this.rELTokenFieldSpecified = value; 1026 | } 1027 | } 1028 | 1029 | /// 1030 | [System.Xml.Serialization.XmlAttributeAttribute ()] 1031 | public int [] SupportedEAPMethods { 1032 | get { 1033 | return this.supportedEAPMethodsField; 1034 | } 1035 | set { 1036 | this.supportedEAPMethodsField = value; 1037 | } 1038 | } 1039 | 1040 | /// 1041 | [System.Xml.Serialization.XmlAttributeAttribute ()] 1042 | public int MaxUsers { 1043 | get { 1044 | return this.maxUsersField; 1045 | } 1046 | set { 1047 | this.maxUsersField = value; 1048 | } 1049 | } 1050 | 1051 | /// 1052 | [System.Xml.Serialization.XmlIgnoreAttribute ()] 1053 | public bool MaxUsersSpecified { 1054 | get { 1055 | return this.maxUsersFieldSpecified; 1056 | } 1057 | set { 1058 | this.maxUsersFieldSpecified = value; 1059 | } 1060 | } 1061 | 1062 | /// 1063 | [System.Xml.Serialization.XmlAttributeAttribute ()] 1064 | public int MaxUserNameLength { 1065 | get { 1066 | return this.maxUserNameLengthField; 1067 | } 1068 | set { 1069 | this.maxUserNameLengthField = value; 1070 | } 1071 | } 1072 | 1073 | /// 1074 | [System.Xml.Serialization.XmlIgnoreAttribute ()] 1075 | public bool MaxUserNameLengthSpecified { 1076 | get { 1077 | return this.maxUserNameLengthFieldSpecified; 1078 | } 1079 | set { 1080 | this.maxUserNameLengthFieldSpecified = value; 1081 | } 1082 | } 1083 | 1084 | /// 1085 | [System.Xml.Serialization.XmlAttributeAttribute ()] 1086 | public int MaxPasswordLength { 1087 | get { 1088 | return this.maxPasswordLengthField; 1089 | } 1090 | set { 1091 | this.maxPasswordLengthField = value; 1092 | } 1093 | } 1094 | 1095 | /// 1096 | [System.Xml.Serialization.XmlIgnoreAttribute ()] 1097 | public bool MaxPasswordLengthSpecified { 1098 | get { 1099 | return this.maxPasswordLengthFieldSpecified; 1100 | } 1101 | set { 1102 | this.maxPasswordLengthFieldSpecified = value; 1103 | } 1104 | } 1105 | } 1106 | 1107 | /// 1108 | [System.CodeDom.Compiler.GeneratedCodeAttribute ("dotnet-svcutil", "1.0.3")] 1109 | [System.Diagnostics.DebuggerStepThroughAttribute ()] 1110 | [System.Xml.Serialization.XmlTypeAttribute (Namespace = "http://www.onvif.org/ver10/device/wsdl")] 1111 | public partial class NetworkCapabilities { 1112 | 1113 | private bool iPFilterField; 1114 | 1115 | private bool iPFilterFieldSpecified; 1116 | 1117 | private bool zeroConfigurationField; 1118 | 1119 | private bool zeroConfigurationFieldSpecified; 1120 | 1121 | private bool iPVersion6Field; 1122 | 1123 | private bool iPVersion6FieldSpecified; 1124 | 1125 | private bool dynDNSField; 1126 | 1127 | private bool dynDNSFieldSpecified; 1128 | 1129 | private bool dot11ConfigurationField; 1130 | 1131 | private bool dot11ConfigurationFieldSpecified; 1132 | 1133 | private int dot1XConfigurationsField; 1134 | 1135 | private bool dot1XConfigurationsFieldSpecified; 1136 | 1137 | private bool hostnameFromDHCPField; 1138 | 1139 | private bool hostnameFromDHCPFieldSpecified; 1140 | 1141 | private int nTPField; 1142 | 1143 | private bool nTPFieldSpecified; 1144 | 1145 | private bool dHCPv6Field; 1146 | 1147 | private bool dHCPv6FieldSpecified; 1148 | 1149 | /// 1150 | [System.Xml.Serialization.XmlAttributeAttribute ()] 1151 | public bool IPFilter { 1152 | get { 1153 | return this.iPFilterField; 1154 | } 1155 | set { 1156 | this.iPFilterField = value; 1157 | } 1158 | } 1159 | 1160 | /// 1161 | [System.Xml.Serialization.XmlIgnoreAttribute ()] 1162 | public bool IPFilterSpecified { 1163 | get { 1164 | return this.iPFilterFieldSpecified; 1165 | } 1166 | set { 1167 | this.iPFilterFieldSpecified = value; 1168 | } 1169 | } 1170 | 1171 | /// 1172 | [System.Xml.Serialization.XmlAttributeAttribute ()] 1173 | public bool ZeroConfiguration { 1174 | get { 1175 | return this.zeroConfigurationField; 1176 | } 1177 | set { 1178 | this.zeroConfigurationField = value; 1179 | } 1180 | } 1181 | 1182 | /// 1183 | [System.Xml.Serialization.XmlIgnoreAttribute ()] 1184 | public bool ZeroConfigurationSpecified { 1185 | get { 1186 | return this.zeroConfigurationFieldSpecified; 1187 | } 1188 | set { 1189 | this.zeroConfigurationFieldSpecified = value; 1190 | } 1191 | } 1192 | 1193 | /// 1194 | [System.Xml.Serialization.XmlAttributeAttribute ()] 1195 | public bool IPVersion6 { 1196 | get { 1197 | return this.iPVersion6Field; 1198 | } 1199 | set { 1200 | this.iPVersion6Field = value; 1201 | } 1202 | } 1203 | 1204 | /// 1205 | [System.Xml.Serialization.XmlIgnoreAttribute ()] 1206 | public bool IPVersion6Specified { 1207 | get { 1208 | return this.iPVersion6FieldSpecified; 1209 | } 1210 | set { 1211 | this.iPVersion6FieldSpecified = value; 1212 | } 1213 | } 1214 | 1215 | /// 1216 | [System.Xml.Serialization.XmlAttributeAttribute ()] 1217 | public bool DynDNS { 1218 | get { 1219 | return this.dynDNSField; 1220 | } 1221 | set { 1222 | this.dynDNSField = value; 1223 | } 1224 | } 1225 | 1226 | /// 1227 | [System.Xml.Serialization.XmlIgnoreAttribute ()] 1228 | public bool DynDNSSpecified { 1229 | get { 1230 | return this.dynDNSFieldSpecified; 1231 | } 1232 | set { 1233 | this.dynDNSFieldSpecified = value; 1234 | } 1235 | } 1236 | 1237 | /// 1238 | [System.Xml.Serialization.XmlAttributeAttribute ()] 1239 | public bool Dot11Configuration { 1240 | get { 1241 | return this.dot11ConfigurationField; 1242 | } 1243 | set { 1244 | this.dot11ConfigurationField = value; 1245 | } 1246 | } 1247 | 1248 | /// 1249 | [System.Xml.Serialization.XmlIgnoreAttribute ()] 1250 | public bool Dot11ConfigurationSpecified { 1251 | get { 1252 | return this.dot11ConfigurationFieldSpecified; 1253 | } 1254 | set { 1255 | this.dot11ConfigurationFieldSpecified = value; 1256 | } 1257 | } 1258 | 1259 | /// 1260 | [System.Xml.Serialization.XmlAttributeAttribute ()] 1261 | public int Dot1XConfigurations { 1262 | get { 1263 | return this.dot1XConfigurationsField; 1264 | } 1265 | set { 1266 | this.dot1XConfigurationsField = value; 1267 | } 1268 | } 1269 | 1270 | /// 1271 | [System.Xml.Serialization.XmlIgnoreAttribute ()] 1272 | public bool Dot1XConfigurationsSpecified { 1273 | get { 1274 | return this.dot1XConfigurationsFieldSpecified; 1275 | } 1276 | set { 1277 | this.dot1XConfigurationsFieldSpecified = value; 1278 | } 1279 | } 1280 | 1281 | /// 1282 | [System.Xml.Serialization.XmlAttributeAttribute ()] 1283 | public bool HostnameFromDHCP { 1284 | get { 1285 | return this.hostnameFromDHCPField; 1286 | } 1287 | set { 1288 | this.hostnameFromDHCPField = value; 1289 | } 1290 | } 1291 | 1292 | /// 1293 | [System.Xml.Serialization.XmlIgnoreAttribute ()] 1294 | public bool HostnameFromDHCPSpecified { 1295 | get { 1296 | return this.hostnameFromDHCPFieldSpecified; 1297 | } 1298 | set { 1299 | this.hostnameFromDHCPFieldSpecified = value; 1300 | } 1301 | } 1302 | 1303 | /// 1304 | [System.Xml.Serialization.XmlAttributeAttribute ()] 1305 | public int NTP { 1306 | get { 1307 | return this.nTPField; 1308 | } 1309 | set { 1310 | this.nTPField = value; 1311 | } 1312 | } 1313 | 1314 | /// 1315 | [System.Xml.Serialization.XmlIgnoreAttribute ()] 1316 | public bool NTPSpecified { 1317 | get { 1318 | return this.nTPFieldSpecified; 1319 | } 1320 | set { 1321 | this.nTPFieldSpecified = value; 1322 | } 1323 | } 1324 | 1325 | /// 1326 | [System.Xml.Serialization.XmlAttributeAttribute ()] 1327 | public bool DHCPv6 { 1328 | get { 1329 | return this.dHCPv6Field; 1330 | } 1331 | set { 1332 | this.dHCPv6Field = value; 1333 | } 1334 | } 1335 | 1336 | /// 1337 | [System.Xml.Serialization.XmlIgnoreAttribute ()] 1338 | public bool DHCPv6Specified { 1339 | get { 1340 | return this.dHCPv6FieldSpecified; 1341 | } 1342 | set { 1343 | this.dHCPv6FieldSpecified = value; 1344 | } 1345 | } 1346 | } 1347 | 1348 | /// 1349 | [System.CodeDom.Compiler.GeneratedCodeAttribute ("dotnet-svcutil", "1.0.3")] 1350 | [System.Diagnostics.DebuggerStepThroughAttribute ()] 1351 | [System.Xml.Serialization.XmlTypeAttribute (Namespace = "http://www.onvif.org/ver10/device/wsdl")] 1352 | public partial class DeviceServiceCapabilities { 1353 | 1354 | private NetworkCapabilities networkField; 1355 | 1356 | private SecurityCapabilities securityField; 1357 | 1358 | private SystemCapabilities systemField; 1359 | 1360 | private MiscCapabilities miscField; 1361 | 1362 | /// 1363 | [System.Xml.Serialization.XmlElementAttribute (Order = 0)] 1364 | public NetworkCapabilities Network { 1365 | get { 1366 | return this.networkField; 1367 | } 1368 | set { 1369 | this.networkField = value; 1370 | } 1371 | } 1372 | 1373 | /// 1374 | [System.Xml.Serialization.XmlElementAttribute (Order = 1)] 1375 | public SecurityCapabilities Security { 1376 | get { 1377 | return this.securityField; 1378 | } 1379 | set { 1380 | this.securityField = value; 1381 | } 1382 | } 1383 | 1384 | /// 1385 | [System.Xml.Serialization.XmlElementAttribute (Order = 2)] 1386 | public SystemCapabilities System { 1387 | get { 1388 | return this.systemField; 1389 | } 1390 | set { 1391 | this.systemField = value; 1392 | } 1393 | } 1394 | 1395 | /// 1396 | [System.Xml.Serialization.XmlElementAttribute (Order = 3)] 1397 | public MiscCapabilities Misc { 1398 | get { 1399 | return this.miscField; 1400 | } 1401 | set { 1402 | this.miscField = value; 1403 | } 1404 | } 1405 | } 1406 | 1407 | /// 1408 | [System.CodeDom.Compiler.GeneratedCodeAttribute ("dotnet-svcutil", "1.0.3")] 1409 | [System.Diagnostics.DebuggerStepThroughAttribute ()] 1410 | [System.Xml.Serialization.XmlTypeAttribute (AnonymousType = true, Namespace = "http://www.onvif.org/ver10/device/wsdl")] 1411 | public partial class GetSystemUrisResponseExtension { 1412 | 1413 | private System.Xml.Linq.XElement [] anyField; 1414 | 1415 | /// 1416 | [System.Xml.Serialization.XmlAnyElementAttribute (Order = 0)] 1417 | public System.Xml.Linq.XElement [] Any { 1418 | get { 1419 | return this.anyField; 1420 | } 1421 | set { 1422 | this.anyField = value; 1423 | } 1424 | } 1425 | } 1426 | } -------------------------------------------------------------------------------- /src/Imaging/DataTypes.cs: -------------------------------------------------------------------------------- 1 | namespace Mictlanix.DotNet.Onvif.Imaging { 2 | /// 3 | [System.CodeDom.Compiler.GeneratedCodeAttribute ("dotnet-svcutil", "1.0.3")] 4 | [System.Diagnostics.DebuggerStepThroughAttribute ()] 5 | [System.Xml.Serialization.XmlTypeAttribute (Namespace = "http://www.onvif.org/ver20/imaging/wsdl")] 6 | public partial class Capabilities { 7 | 8 | private System.Xml.Linq.XElement [] anyField; 9 | 10 | private bool imageStabilizationField; 11 | 12 | private bool imageStabilizationFieldSpecified; 13 | 14 | private bool presetsField; 15 | 16 | private bool presetsFieldSpecified; 17 | 18 | /// 19 | [System.Xml.Serialization.XmlAnyElementAttribute (Order = 0)] 20 | public System.Xml.Linq.XElement [] Any { 21 | get { 22 | return this.anyField; 23 | } 24 | set { 25 | this.anyField = value; 26 | } 27 | } 28 | 29 | /// 30 | [System.Xml.Serialization.XmlAttributeAttribute ()] 31 | public bool ImageStabilization { 32 | get { 33 | return this.imageStabilizationField; 34 | } 35 | set { 36 | this.imageStabilizationField = value; 37 | } 38 | } 39 | 40 | /// 41 | [System.Xml.Serialization.XmlIgnoreAttribute ()] 42 | public bool ImageStabilizationSpecified { 43 | get { 44 | return this.imageStabilizationFieldSpecified; 45 | } 46 | set { 47 | this.imageStabilizationFieldSpecified = value; 48 | } 49 | } 50 | 51 | /// 52 | [System.Xml.Serialization.XmlAttributeAttribute ()] 53 | public bool Presets { 54 | get { 55 | return this.presetsField; 56 | } 57 | set { 58 | this.presetsField = value; 59 | } 60 | } 61 | 62 | /// 63 | [System.Xml.Serialization.XmlIgnoreAttribute ()] 64 | public bool PresetsSpecified { 65 | get { 66 | return this.presetsFieldSpecified; 67 | } 68 | set { 69 | this.presetsFieldSpecified = value; 70 | } 71 | } 72 | } 73 | 74 | /// 75 | [System.CodeDom.Compiler.GeneratedCodeAttribute ("dotnet-svcutil", "1.0.3")] 76 | [System.Diagnostics.DebuggerStepThroughAttribute ()] 77 | [System.Xml.Serialization.XmlTypeAttribute (Namespace = "http://www.onvif.org/ver20/imaging/wsdl")] 78 | public partial class ImagingPreset { 79 | 80 | private string nameField; 81 | 82 | private string tokenField; 83 | 84 | private string typeField; 85 | 86 | /// 87 | [System.Xml.Serialization.XmlElementAttribute (Order = 0)] 88 | public string Name { 89 | get { 90 | return this.nameField; 91 | } 92 | set { 93 | this.nameField = value; 94 | } 95 | } 96 | 97 | /// 98 | [System.Xml.Serialization.XmlAttributeAttribute ()] 99 | public string token { 100 | get { 101 | return this.tokenField; 102 | } 103 | set { 104 | this.tokenField = value; 105 | } 106 | } 107 | 108 | /// 109 | [System.Xml.Serialization.XmlAttributeAttribute ()] 110 | public string type { 111 | get { 112 | return this.typeField; 113 | } 114 | set { 115 | this.typeField = value; 116 | } 117 | } 118 | } 119 | } -------------------------------------------------------------------------------- /src/Imaging/ImagingClient.cs: -------------------------------------------------------------------------------- 1 | using Mictlanix.DotNet.Onvif.Common; 2 | 3 | namespace Mictlanix.DotNet.Onvif.Imaging 4 | { 5 | [System.CodeDom.Compiler.GeneratedCodeAttribute("dotnet-svcutil", "1.0.3")] 6 | [System.ServiceModel.ServiceContractAttribute(Namespace="http://www.onvif.org/ver20/imaging/wsdl", ConfigurationName="Mictlanix.DotNet.Onvif.Imaging.Imaging")] 7 | public interface Imaging 8 | { 9 | 10 | [System.ServiceModel.OperationContractAttribute(Action="http://www.onvif.org/ver20/imaging/wsdl/GetServiceCapabilities", ReplyAction="*")] 11 | [System.ServiceModel.XmlSerializerFormatAttribute(SupportFaults=true)] 12 | [return: System.ServiceModel.MessageParameterAttribute(Name="Capabilities")] 13 | System.Threading.Tasks.Task GetServiceCapabilitiesAsync(); 14 | 15 | [System.ServiceModel.OperationContractAttribute(Action="http://www.onvif.org/ver20/imaging/wsdl/GetImagingSettings", ReplyAction="*")] 16 | [System.ServiceModel.XmlSerializerFormatAttribute(SupportFaults=true)] 17 | [return: System.ServiceModel.MessageParameterAttribute(Name="ImagingSettings")] 18 | System.Threading.Tasks.Task GetImagingSettingsAsync(string VideoSourceToken); 19 | 20 | [System.ServiceModel.OperationContractAttribute(Action="http://www.onvif.org/ver20/imaging/wsdl/SetImagingSettings", ReplyAction="*")] 21 | [System.ServiceModel.XmlSerializerFormatAttribute(SupportFaults=true)] 22 | System.Threading.Tasks.Task SetImagingSettingsAsync(string VideoSourceToken, ImagingSettings20 ImagingSettings, bool ForcePersistence); 23 | 24 | [System.ServiceModel.OperationContractAttribute(Action="http://www.onvif.org/ver20/imaging/wsdl/GetOptions", ReplyAction="*")] 25 | [System.ServiceModel.XmlSerializerFormatAttribute(SupportFaults=true)] 26 | [return: System.ServiceModel.MessageParameterAttribute(Name="ImagingOptions")] 27 | System.Threading.Tasks.Task GetOptionsAsync(string VideoSourceToken); 28 | 29 | [System.ServiceModel.OperationContractAttribute(Action="http://www.onvif.org/ver20/imaging/wsdl/Move", ReplyAction="*")] 30 | [System.ServiceModel.XmlSerializerFormatAttribute(SupportFaults=true)] 31 | System.Threading.Tasks.Task MoveAsync(string VideoSourceToken, FocusMove Focus); 32 | 33 | [System.ServiceModel.OperationContractAttribute(Action="http://www.onvif.org/ver20/imaging/wsdl/GetMoveOptions", ReplyAction="*")] 34 | [System.ServiceModel.XmlSerializerFormatAttribute(SupportFaults=true)] 35 | [return: System.ServiceModel.MessageParameterAttribute(Name="MoveOptions")] 36 | System.Threading.Tasks.Task GetMoveOptionsAsync(string VideoSourceToken); 37 | 38 | [System.ServiceModel.OperationContractAttribute(Action="http://www.onvif.org/ver20/imaging/wsdl/FocusStop", ReplyAction="*")] 39 | [System.ServiceModel.XmlSerializerFormatAttribute(SupportFaults=true)] 40 | System.Threading.Tasks.Task StopAsync(string VideoSourceToken); 41 | 42 | [System.ServiceModel.OperationContractAttribute(Action="http://www.onvif.org/ver20/imaging/wsdl/GetStatus", ReplyAction="*")] 43 | [System.ServiceModel.XmlSerializerFormatAttribute(SupportFaults=true)] 44 | [return: System.ServiceModel.MessageParameterAttribute(Name="Status")] 45 | System.Threading.Tasks.Task GetStatusAsync(string VideoSourceToken); 46 | 47 | [System.ServiceModel.OperationContractAttribute(Action="http://www.onvif.org/ver20/imaging/wsdl/GetPresets", ReplyAction="*")] 48 | [System.ServiceModel.XmlSerializerFormatAttribute(SupportFaults=true)] 49 | System.Threading.Tasks.Task GetPresetsAsync(Mictlanix.DotNet.Onvif.Imaging.GetPresetsRequest request); 50 | 51 | [System.ServiceModel.OperationContractAttribute(Action="http://www.onvif.org/ver20/imaging/wsdl/GetCurrentPreset", ReplyAction="*")] 52 | [System.ServiceModel.XmlSerializerFormatAttribute(SupportFaults=true)] 53 | [return: System.ServiceModel.MessageParameterAttribute(Name="Preset")] 54 | System.Threading.Tasks.Task GetCurrentPresetAsync(string VideoSourceToken); 55 | 56 | [System.ServiceModel.OperationContractAttribute(Action="http://www.onvif.org/ver20/imaging/wsdl/SetCurrentPreset", ReplyAction="*")] 57 | [System.ServiceModel.XmlSerializerFormatAttribute(SupportFaults=true)] 58 | System.Threading.Tasks.Task SetCurrentPresetAsync(string VideoSourceToken, string PresetToken); 59 | } 60 | 61 | [System.Diagnostics.DebuggerStepThroughAttribute()] 62 | [System.CodeDom.Compiler.GeneratedCodeAttribute("dotnet-svcutil", "1.0.3")] 63 | [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Advanced)] 64 | [System.ServiceModel.MessageContractAttribute(WrapperName="GetPresets", WrapperNamespace="http://www.onvif.org/ver20/imaging/wsdl", IsWrapped=true)] 65 | public partial class GetPresetsRequest 66 | { 67 | 68 | [System.ServiceModel.MessageBodyMemberAttribute(Namespace="http://www.onvif.org/ver20/imaging/wsdl", Order=0)] 69 | public string VideoSourceToken; 70 | 71 | public GetPresetsRequest() 72 | { 73 | } 74 | 75 | public GetPresetsRequest(string VideoSourceToken) 76 | { 77 | this.VideoSourceToken = VideoSourceToken; 78 | } 79 | } 80 | 81 | [System.Diagnostics.DebuggerStepThroughAttribute()] 82 | [System.CodeDom.Compiler.GeneratedCodeAttribute("dotnet-svcutil", "1.0.3")] 83 | [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Advanced)] 84 | [System.ServiceModel.MessageContractAttribute(WrapperName="GetPresetsResponse", WrapperNamespace="http://www.onvif.org/ver20/imaging/wsdl", IsWrapped=true)] 85 | public partial class GetPresetsResponse 86 | { 87 | 88 | [System.ServiceModel.MessageBodyMemberAttribute(Namespace="http://www.onvif.org/ver20/imaging/wsdl", Order=0)] 89 | [System.Xml.Serialization.XmlElementAttribute("Preset")] 90 | public ImagingPreset[] Preset; 91 | 92 | public GetPresetsResponse() 93 | { 94 | } 95 | 96 | public GetPresetsResponse(ImagingPreset[] Preset) 97 | { 98 | this.Preset = Preset; 99 | } 100 | } 101 | 102 | [System.CodeDom.Compiler.GeneratedCodeAttribute("dotnet-svcutil", "1.0.3")] 103 | public interface ImagingChannel : Mictlanix.DotNet.Onvif.Imaging.Imaging, System.ServiceModel.IClientChannel 104 | { 105 | } 106 | 107 | [System.Diagnostics.DebuggerStepThroughAttribute()] 108 | [System.CodeDom.Compiler.GeneratedCodeAttribute("dotnet-svcutil", "1.0.3")] 109 | public partial class ImagingClient : System.ServiceModel.ClientBase, Mictlanix.DotNet.Onvif.Imaging.Imaging 110 | { 111 | 112 | internal ImagingClient(System.ServiceModel.Channels.Binding binding, System.ServiceModel.EndpointAddress remoteAddress) : 113 | base(binding, remoteAddress) 114 | { 115 | } 116 | 117 | public System.Threading.Tasks.Task GetServiceCapabilitiesAsync() 118 | { 119 | return base.Channel.GetServiceCapabilitiesAsync(); 120 | } 121 | 122 | public System.Threading.Tasks.Task GetImagingSettingsAsync(string VideoSourceToken) 123 | { 124 | return base.Channel.GetImagingSettingsAsync(VideoSourceToken); 125 | } 126 | 127 | public System.Threading.Tasks.Task SetImagingSettingsAsync(string VideoSourceToken, ImagingSettings20 ImagingSettings, bool ForcePersistence) 128 | { 129 | return base.Channel.SetImagingSettingsAsync(VideoSourceToken, ImagingSettings, ForcePersistence); 130 | } 131 | 132 | public System.Threading.Tasks.Task GetOptionsAsync(string VideoSourceToken) 133 | { 134 | return base.Channel.GetOptionsAsync(VideoSourceToken); 135 | } 136 | 137 | public System.Threading.Tasks.Task MoveAsync(string VideoSourceToken, FocusMove Focus) 138 | { 139 | return base.Channel.MoveAsync(VideoSourceToken, Focus); 140 | } 141 | 142 | public System.Threading.Tasks.Task GetMoveOptionsAsync(string VideoSourceToken) 143 | { 144 | return base.Channel.GetMoveOptionsAsync(VideoSourceToken); 145 | } 146 | 147 | public System.Threading.Tasks.Task StopAsync(string VideoSourceToken) 148 | { 149 | return base.Channel.StopAsync(VideoSourceToken); 150 | } 151 | 152 | public System.Threading.Tasks.Task GetStatusAsync(string VideoSourceToken) 153 | { 154 | return base.Channel.GetStatusAsync(VideoSourceToken); 155 | } 156 | 157 | [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Advanced)] 158 | System.Threading.Tasks.Task Mictlanix.DotNet.Onvif.Imaging.Imaging.GetPresetsAsync(Mictlanix.DotNet.Onvif.Imaging.GetPresetsRequest request) 159 | { 160 | return base.Channel.GetPresetsAsync(request); 161 | } 162 | 163 | public System.Threading.Tasks.Task GetPresetsAsync(string VideoSourceToken) 164 | { 165 | Mictlanix.DotNet.Onvif.Imaging.GetPresetsRequest inValue = new Mictlanix.DotNet.Onvif.Imaging.GetPresetsRequest(); 166 | inValue.VideoSourceToken = VideoSourceToken; 167 | return ((Mictlanix.DotNet.Onvif.Imaging.Imaging)(this)).GetPresetsAsync(inValue); 168 | } 169 | 170 | public System.Threading.Tasks.Task GetCurrentPresetAsync(string VideoSourceToken) 171 | { 172 | return base.Channel.GetCurrentPresetAsync(VideoSourceToken); 173 | } 174 | 175 | public System.Threading.Tasks.Task SetCurrentPresetAsync(string VideoSourceToken, string PresetToken) 176 | { 177 | return base.Channel.SetCurrentPresetAsync(VideoSourceToken, PresetToken); 178 | } 179 | 180 | public virtual System.Threading.Tasks.Task OpenAsync() 181 | { 182 | return System.Threading.Tasks.Task.Factory.FromAsync(((System.ServiceModel.ICommunicationObject)(this)).BeginOpen(null, null), new System.Action(((System.ServiceModel.ICommunicationObject)(this)).EndOpen)); 183 | } 184 | 185 | public virtual System.Threading.Tasks.Task CloseAsync() 186 | { 187 | return System.Threading.Tasks.Task.Factory.FromAsync(((System.ServiceModel.ICommunicationObject)(this)).BeginClose(null, null), new System.Action(((System.ServiceModel.ICommunicationObject)(this)).EndClose)); 188 | } 189 | } 190 | } 191 | -------------------------------------------------------------------------------- /src/Media/DataTypes.cs: -------------------------------------------------------------------------------- 1 | using Mictlanix.DotNet.Onvif.Common; 2 | 3 | namespace Mictlanix.DotNet.Onvif.Media { 4 | /// 5 | [System.CodeDom.Compiler.GeneratedCodeAttribute ("dotnet-svcutil", "1.0.3")] 6 | [System.Diagnostics.DebuggerStepThroughAttribute ()] 7 | [System.Xml.Serialization.XmlTypeAttribute (Namespace = "http://www.onvif.org/ver10/media/wsdl")] 8 | public partial class Capabilities { 9 | 10 | private ProfileCapabilities profileCapabilitiesField; 11 | 12 | private StreamingCapabilities streamingCapabilitiesField; 13 | 14 | private System.Xml.Linq.XElement [] anyField; 15 | 16 | private bool snapshotUriField; 17 | 18 | private bool snapshotUriFieldSpecified; 19 | 20 | private bool rotationField; 21 | 22 | private bool rotationFieldSpecified; 23 | 24 | private bool videoSourceModeField; 25 | 26 | private bool videoSourceModeFieldSpecified; 27 | 28 | private bool oSDField; 29 | 30 | private bool oSDFieldSpecified; 31 | 32 | private bool temporaryOSDTextField; 33 | 34 | private bool temporaryOSDTextFieldSpecified; 35 | 36 | private bool eXICompressionField; 37 | 38 | private bool eXICompressionFieldSpecified; 39 | 40 | /// 41 | [System.Xml.Serialization.XmlElementAttribute (Order = 0)] 42 | public ProfileCapabilities ProfileCapabilities { 43 | get { 44 | return this.profileCapabilitiesField; 45 | } 46 | set { 47 | this.profileCapabilitiesField = value; 48 | } 49 | } 50 | 51 | /// 52 | [System.Xml.Serialization.XmlElementAttribute (Order = 1)] 53 | public StreamingCapabilities StreamingCapabilities { 54 | get { 55 | return this.streamingCapabilitiesField; 56 | } 57 | set { 58 | this.streamingCapabilitiesField = value; 59 | } 60 | } 61 | 62 | /// 63 | [System.Xml.Serialization.XmlAnyElementAttribute (Order = 2)] 64 | public System.Xml.Linq.XElement [] Any { 65 | get { 66 | return this.anyField; 67 | } 68 | set { 69 | this.anyField = value; 70 | } 71 | } 72 | 73 | /// 74 | [System.Xml.Serialization.XmlAttributeAttribute ()] 75 | public bool SnapshotUri { 76 | get { 77 | return this.snapshotUriField; 78 | } 79 | set { 80 | this.snapshotUriField = value; 81 | } 82 | } 83 | 84 | /// 85 | [System.Xml.Serialization.XmlIgnoreAttribute ()] 86 | public bool SnapshotUriSpecified { 87 | get { 88 | return this.snapshotUriFieldSpecified; 89 | } 90 | set { 91 | this.snapshotUriFieldSpecified = value; 92 | } 93 | } 94 | 95 | /// 96 | [System.Xml.Serialization.XmlAttributeAttribute ()] 97 | public bool Rotation { 98 | get { 99 | return this.rotationField; 100 | } 101 | set { 102 | this.rotationField = value; 103 | } 104 | } 105 | 106 | /// 107 | [System.Xml.Serialization.XmlIgnoreAttribute ()] 108 | public bool RotationSpecified { 109 | get { 110 | return this.rotationFieldSpecified; 111 | } 112 | set { 113 | this.rotationFieldSpecified = value; 114 | } 115 | } 116 | 117 | /// 118 | [System.Xml.Serialization.XmlAttributeAttribute ()] 119 | public bool VideoSourceMode { 120 | get { 121 | return this.videoSourceModeField; 122 | } 123 | set { 124 | this.videoSourceModeField = value; 125 | } 126 | } 127 | 128 | /// 129 | [System.Xml.Serialization.XmlIgnoreAttribute ()] 130 | public bool VideoSourceModeSpecified { 131 | get { 132 | return this.videoSourceModeFieldSpecified; 133 | } 134 | set { 135 | this.videoSourceModeFieldSpecified = value; 136 | } 137 | } 138 | 139 | /// 140 | [System.Xml.Serialization.XmlAttributeAttribute ()] 141 | public bool OSD { 142 | get { 143 | return this.oSDField; 144 | } 145 | set { 146 | this.oSDField = value; 147 | } 148 | } 149 | 150 | /// 151 | [System.Xml.Serialization.XmlIgnoreAttribute ()] 152 | public bool OSDSpecified { 153 | get { 154 | return this.oSDFieldSpecified; 155 | } 156 | set { 157 | this.oSDFieldSpecified = value; 158 | } 159 | } 160 | 161 | /// 162 | [System.Xml.Serialization.XmlAttributeAttribute ()] 163 | public bool TemporaryOSDText { 164 | get { 165 | return this.temporaryOSDTextField; 166 | } 167 | set { 168 | this.temporaryOSDTextField = value; 169 | } 170 | } 171 | 172 | /// 173 | [System.Xml.Serialization.XmlIgnoreAttribute ()] 174 | public bool TemporaryOSDTextSpecified { 175 | get { 176 | return this.temporaryOSDTextFieldSpecified; 177 | } 178 | set { 179 | this.temporaryOSDTextFieldSpecified = value; 180 | } 181 | } 182 | 183 | /// 184 | [System.Xml.Serialization.XmlAttributeAttribute ()] 185 | public bool EXICompression { 186 | get { 187 | return this.eXICompressionField; 188 | } 189 | set { 190 | this.eXICompressionField = value; 191 | } 192 | } 193 | 194 | /// 195 | [System.Xml.Serialization.XmlIgnoreAttribute ()] 196 | public bool EXICompressionSpecified { 197 | get { 198 | return this.eXICompressionFieldSpecified; 199 | } 200 | set { 201 | this.eXICompressionFieldSpecified = value; 202 | } 203 | } 204 | } 205 | 206 | /// 207 | [System.CodeDom.Compiler.GeneratedCodeAttribute ("dotnet-svcutil", "1.0.3")] 208 | [System.Diagnostics.DebuggerStepThroughAttribute ()] 209 | [System.Xml.Serialization.XmlTypeAttribute (Namespace = "http://www.onvif.org/ver10/media/wsdl")] 210 | public partial class ProfileCapabilities { 211 | 212 | private System.Xml.Linq.XElement [] anyField; 213 | 214 | private int maximumNumberOfProfilesField; 215 | 216 | private bool maximumNumberOfProfilesFieldSpecified; 217 | 218 | /// 219 | [System.Xml.Serialization.XmlAnyElementAttribute (Order = 0)] 220 | public System.Xml.Linq.XElement [] Any { 221 | get { 222 | return this.anyField; 223 | } 224 | set { 225 | this.anyField = value; 226 | } 227 | } 228 | 229 | /// 230 | [System.Xml.Serialization.XmlAttributeAttribute ()] 231 | public int MaximumNumberOfProfiles { 232 | get { 233 | return this.maximumNumberOfProfilesField; 234 | } 235 | set { 236 | this.maximumNumberOfProfilesField = value; 237 | } 238 | } 239 | 240 | /// 241 | [System.Xml.Serialization.XmlIgnoreAttribute ()] 242 | public bool MaximumNumberOfProfilesSpecified { 243 | get { 244 | return this.maximumNumberOfProfilesFieldSpecified; 245 | } 246 | set { 247 | this.maximumNumberOfProfilesFieldSpecified = value; 248 | } 249 | } 250 | } 251 | 252 | 253 | /// 254 | [System.CodeDom.Compiler.GeneratedCodeAttribute ("dotnet-svcutil", "1.0.3")] 255 | [System.Diagnostics.DebuggerStepThroughAttribute ()] 256 | [System.Xml.Serialization.XmlTypeAttribute (Namespace = "http://www.onvif.org/ver10/media/wsdl")] 257 | public partial class VideoSourceModeExtension { 258 | 259 | private System.Xml.Linq.XElement [] anyField; 260 | 261 | /// 262 | [System.Xml.Serialization.XmlAnyElementAttribute (Order = 0)] 263 | public System.Xml.Linq.XElement [] Any { 264 | get { 265 | return this.anyField; 266 | } 267 | set { 268 | this.anyField = value; 269 | } 270 | } 271 | } 272 | 273 | /// 274 | [System.CodeDom.Compiler.GeneratedCodeAttribute ("dotnet-svcutil", "1.0.3")] 275 | [System.Diagnostics.DebuggerStepThroughAttribute ()] 276 | [System.Xml.Serialization.XmlTypeAttribute (Namespace = "http://www.onvif.org/ver10/media/wsdl")] 277 | public partial class VideoSourceMode { 278 | 279 | private float maxFramerateField; 280 | 281 | private VideoResolution maxResolutionField; 282 | 283 | private string encodingsField; 284 | 285 | private bool rebootField; 286 | 287 | private string descriptionField; 288 | 289 | private VideoSourceModeExtension extensionField; 290 | 291 | private string tokenField; 292 | 293 | private bool enabledField; 294 | 295 | private bool enabledFieldSpecified; 296 | 297 | /// 298 | [System.Xml.Serialization.XmlElementAttribute (Order = 0)] 299 | public float MaxFramerate { 300 | get { 301 | return this.maxFramerateField; 302 | } 303 | set { 304 | this.maxFramerateField = value; 305 | } 306 | } 307 | 308 | /// 309 | [System.Xml.Serialization.XmlElementAttribute (Order = 1)] 310 | public VideoResolution MaxResolution { 311 | get { 312 | return this.maxResolutionField; 313 | } 314 | set { 315 | this.maxResolutionField = value; 316 | } 317 | } 318 | 319 | /// 320 | [System.Xml.Serialization.XmlElementAttribute (Order = 2)] 321 | public string Encodings { 322 | get { 323 | return this.encodingsField; 324 | } 325 | set { 326 | this.encodingsField = value; 327 | } 328 | } 329 | 330 | /// 331 | [System.Xml.Serialization.XmlElementAttribute (Order = 3)] 332 | public bool Reboot { 333 | get { 334 | return this.rebootField; 335 | } 336 | set { 337 | this.rebootField = value; 338 | } 339 | } 340 | 341 | /// 342 | [System.Xml.Serialization.XmlElementAttribute (Order = 4)] 343 | public string Description { 344 | get { 345 | return this.descriptionField; 346 | } 347 | set { 348 | this.descriptionField = value; 349 | } 350 | } 351 | 352 | /// 353 | [System.Xml.Serialization.XmlElementAttribute (Order = 5)] 354 | public VideoSourceModeExtension Extension { 355 | get { 356 | return this.extensionField; 357 | } 358 | set { 359 | this.extensionField = value; 360 | } 361 | } 362 | 363 | /// 364 | [System.Xml.Serialization.XmlAttributeAttribute ()] 365 | public string token { 366 | get { 367 | return this.tokenField; 368 | } 369 | set { 370 | this.tokenField = value; 371 | } 372 | } 373 | 374 | /// 375 | [System.Xml.Serialization.XmlAttributeAttribute ()] 376 | public bool Enabled { 377 | get { 378 | return this.enabledField; 379 | } 380 | set { 381 | this.enabledField = value; 382 | } 383 | } 384 | 385 | /// 386 | [System.Xml.Serialization.XmlIgnoreAttribute ()] 387 | public bool EnabledSpecified { 388 | get { 389 | return this.enabledFieldSpecified; 390 | } 391 | set { 392 | this.enabledFieldSpecified = value; 393 | } 394 | } 395 | } 396 | 397 | 398 | /// 399 | [System.CodeDom.Compiler.GeneratedCodeAttribute ("dotnet-svcutil", "1.0.3")] 400 | [System.Diagnostics.DebuggerStepThroughAttribute ()] 401 | [System.Xml.Serialization.XmlTypeAttribute (Namespace = "http://www.onvif.org/ver10/media/wsdl")] 402 | public partial class StreamingCapabilities { 403 | 404 | private System.Xml.Linq.XElement [] anyField; 405 | 406 | private bool rTPMulticastField; 407 | 408 | private bool rTPMulticastFieldSpecified; 409 | 410 | private bool rTP_TCPField; 411 | 412 | private bool rTP_TCPFieldSpecified; 413 | 414 | private bool rTP_RTSP_TCPField; 415 | 416 | private bool rTP_RTSP_TCPFieldSpecified; 417 | 418 | private bool nonAggregateControlField; 419 | 420 | private bool nonAggregateControlFieldSpecified; 421 | 422 | private bool noRTSPStreamingField; 423 | 424 | private bool noRTSPStreamingFieldSpecified; 425 | 426 | /// 427 | [System.Xml.Serialization.XmlAnyElementAttribute (Order = 0)] 428 | public System.Xml.Linq.XElement [] Any { 429 | get { 430 | return this.anyField; 431 | } 432 | set { 433 | this.anyField = value; 434 | } 435 | } 436 | 437 | /// 438 | [System.Xml.Serialization.XmlAttributeAttribute ()] 439 | public bool RTPMulticast { 440 | get { 441 | return this.rTPMulticastField; 442 | } 443 | set { 444 | this.rTPMulticastField = value; 445 | } 446 | } 447 | 448 | /// 449 | [System.Xml.Serialization.XmlIgnoreAttribute ()] 450 | public bool RTPMulticastSpecified { 451 | get { 452 | return this.rTPMulticastFieldSpecified; 453 | } 454 | set { 455 | this.rTPMulticastFieldSpecified = value; 456 | } 457 | } 458 | 459 | /// 460 | [System.Xml.Serialization.XmlAttributeAttribute ()] 461 | public bool RTP_TCP { 462 | get { 463 | return this.rTP_TCPField; 464 | } 465 | set { 466 | this.rTP_TCPField = value; 467 | } 468 | } 469 | 470 | /// 471 | [System.Xml.Serialization.XmlIgnoreAttribute ()] 472 | public bool RTP_TCPSpecified { 473 | get { 474 | return this.rTP_TCPFieldSpecified; 475 | } 476 | set { 477 | this.rTP_TCPFieldSpecified = value; 478 | } 479 | } 480 | 481 | /// 482 | [System.Xml.Serialization.XmlAttributeAttribute ()] 483 | public bool RTP_RTSP_TCP { 484 | get { 485 | return this.rTP_RTSP_TCPField; 486 | } 487 | set { 488 | this.rTP_RTSP_TCPField = value; 489 | } 490 | } 491 | 492 | /// 493 | [System.Xml.Serialization.XmlIgnoreAttribute ()] 494 | public bool RTP_RTSP_TCPSpecified { 495 | get { 496 | return this.rTP_RTSP_TCPFieldSpecified; 497 | } 498 | set { 499 | this.rTP_RTSP_TCPFieldSpecified = value; 500 | } 501 | } 502 | 503 | /// 504 | [System.Xml.Serialization.XmlAttributeAttribute ()] 505 | public bool NonAggregateControl { 506 | get { 507 | return this.nonAggregateControlField; 508 | } 509 | set { 510 | this.nonAggregateControlField = value; 511 | } 512 | } 513 | 514 | /// 515 | [System.Xml.Serialization.XmlIgnoreAttribute ()] 516 | public bool NonAggregateControlSpecified { 517 | get { 518 | return this.nonAggregateControlFieldSpecified; 519 | } 520 | set { 521 | this.nonAggregateControlFieldSpecified = value; 522 | } 523 | } 524 | 525 | /// 526 | [System.Xml.Serialization.XmlAttributeAttribute ()] 527 | public bool NoRTSPStreaming { 528 | get { 529 | return this.noRTSPStreamingField; 530 | } 531 | set { 532 | this.noRTSPStreamingField = value; 533 | } 534 | } 535 | 536 | /// 537 | [System.Xml.Serialization.XmlIgnoreAttribute ()] 538 | public bool NoRTSPStreamingSpecified { 539 | get { 540 | return this.noRTSPStreamingFieldSpecified; 541 | } 542 | set { 543 | this.noRTSPStreamingFieldSpecified = value; 544 | } 545 | } 546 | } 547 | } -------------------------------------------------------------------------------- /src/OnvifClient.csproj: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | netstandard2.0 5 | Mictlanix.DotNet.OnvifClient 6 | Mictlanix.DotNet.Onvif 7 | 0.0.3 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | -------------------------------------------------------------------------------- /src/OnvifClientFactory.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.ServiceModel; 3 | using System.ServiceModel.Channels; 4 | using System.Threading.Tasks; 5 | using Mictlanix.DotNet.Onvif.Common; 6 | using Mictlanix.DotNet.Onvif.Device; 7 | using Mictlanix.DotNet.Onvif.Imaging; 8 | using Mictlanix.DotNet.Onvif.Media; 9 | using Mictlanix.DotNet.Onvif.Ptz; 10 | using Mictlanix.DotNet.Onvif.Security; 11 | 12 | namespace Mictlanix.DotNet.Onvif { 13 | public static class OnvifClientFactory { 14 | static Binding CreateBinding () 15 | { 16 | var binding = new CustomBinding (); 17 | var textBindingElement = new TextMessageEncodingBindingElement { 18 | MessageVersion = MessageVersion.CreateVersion (EnvelopeVersion.Soap12, AddressingVersion.None) 19 | }; 20 | var httpBindingElement = new HttpTransportBindingElement { 21 | AllowCookies = true, 22 | MaxBufferSize = int.MaxValue, 23 | MaxReceivedMessageSize = int.MaxValue 24 | }; 25 | 26 | binding.Elements.Add (textBindingElement); 27 | binding.Elements.Add (httpBindingElement); 28 | 29 | return binding; 30 | } 31 | 32 | public static async Task CreateDeviceClientAsync (string host, string username, string password) 33 | { 34 | return await CreateDeviceClientAsync (new Uri ($"http://{host}/onvif/device_service"), username, password); 35 | } 36 | 37 | public static async Task CreateDeviceClientAsync (Uri uri, string username, string password) 38 | { 39 | var binding = CreateBinding (); 40 | var endpoint = new EndpointAddress (uri); 41 | var device = new DeviceClient (binding, endpoint); 42 | var time_shift = await GetDeviceTimeShift (device); 43 | 44 | device = new DeviceClient (binding, endpoint); 45 | device.ChannelFactory.Endpoint.EndpointBehaviors.Clear (); 46 | device.ChannelFactory.Endpoint.EndpointBehaviors.Add (new SoapSecurityHeaderBehavior (username, password, time_shift)); 47 | 48 | // Connectivity Test 49 | await device.OpenAsync (); 50 | 51 | return device; 52 | } 53 | 54 | public static async Task CreateMediaClientAsync (string host, string username, string password) 55 | { 56 | var binding = CreateBinding (); 57 | var device = await CreateDeviceClientAsync (host, username, password); 58 | var caps = await device.GetCapabilitiesAsync (new CapabilityCategory [] { CapabilityCategory.Media }); 59 | var media = new MediaClient (binding, new EndpointAddress (new Uri (caps.Capabilities.Media.XAddr))); 60 | 61 | var time_shift = await GetDeviceTimeShift (device); 62 | media.ChannelFactory.Endpoint.EndpointBehaviors.Clear (); 63 | media.ChannelFactory.Endpoint.EndpointBehaviors.Add (new SoapSecurityHeaderBehavior (username, password, time_shift)); 64 | 65 | // Connectivity Test 66 | await media.OpenAsync (); 67 | 68 | return media; 69 | } 70 | 71 | public static async Task CreatePTZClientAsync (string host, string username, string password) 72 | { 73 | var binding = CreateBinding (); 74 | var device = await CreateDeviceClientAsync (host, username, password); 75 | var caps = await device.GetCapabilitiesAsync (new CapabilityCategory [] { CapabilityCategory.PTZ }); 76 | var ptz = new PTZClient (binding, new EndpointAddress (new Uri (caps.Capabilities.PTZ.XAddr))); 77 | 78 | var time_shift = await GetDeviceTimeShift (device); 79 | ptz.ChannelFactory.Endpoint.EndpointBehaviors.Clear (); 80 | ptz.ChannelFactory.Endpoint.EndpointBehaviors.Add (new SoapSecurityHeaderBehavior (username, password, time_shift)); 81 | 82 | // Connectivity Test 83 | await ptz.OpenAsync (); 84 | 85 | return ptz; 86 | } 87 | 88 | public static async Task CreateImagingClientAsync (string host, string username, string password) 89 | { 90 | var binding = CreateBinding (); 91 | var device = await CreateDeviceClientAsync (host, username, password); 92 | var caps = await device.GetCapabilitiesAsync (new CapabilityCategory [] { CapabilityCategory.Imaging }); 93 | var imaging = new ImagingClient (binding, new EndpointAddress (new Uri (caps.Capabilities.Imaging.XAddr))); 94 | 95 | var time_shift = await GetDeviceTimeShift (device); 96 | imaging.ChannelFactory.Endpoint.EndpointBehaviors.Clear (); 97 | imaging.ChannelFactory.Endpoint.EndpointBehaviors.Add (new SoapSecurityHeaderBehavior (username, password, time_shift)); 98 | 99 | // Connectivity Test 100 | await imaging.OpenAsync (); 101 | 102 | return imaging; 103 | } 104 | 105 | static async Task GetDeviceTimeShift (DeviceClient device) 106 | { 107 | var utc = (await device.GetSystemDateAndTimeAsync ()).UTCDateTime; 108 | var dt = new System.DateTime (utc.Date.Year, utc.Date.Month, utc.Date.Day, 109 | utc.Time.Hour, utc.Time.Minute, utc.Time.Second); 110 | return dt - System.DateTime.UtcNow; 111 | } 112 | } 113 | } 114 | -------------------------------------------------------------------------------- /src/Ptz/DataTypes.cs: -------------------------------------------------------------------------------- 1 | namespace Mictlanix.DotNet.Onvif.Ptz { 2 | /// 3 | [System.CodeDom.Compiler.GeneratedCodeAttribute ("dotnet-svcutil", "1.0.3")] 4 | [System.Diagnostics.DebuggerStepThroughAttribute ()] 5 | [System.Xml.Serialization.XmlTypeAttribute (Namespace = "http://www.onvif.org/ver20/ptz/wsdl")] 6 | public partial class Capabilities { 7 | 8 | private System.Xml.Linq.XElement [] anyField; 9 | 10 | private bool eFlipField; 11 | 12 | private bool eFlipFieldSpecified; 13 | 14 | private bool reverseField; 15 | 16 | private bool reverseFieldSpecified; 17 | 18 | private bool getCompatibleConfigurationsField; 19 | 20 | private bool getCompatibleConfigurationsFieldSpecified; 21 | 22 | private bool moveStatusField; 23 | 24 | private bool moveStatusFieldSpecified; 25 | 26 | private bool statusPositionField; 27 | 28 | private bool statusPositionFieldSpecified; 29 | 30 | /// 31 | [System.Xml.Serialization.XmlAnyElementAttribute (Order = 0)] 32 | public System.Xml.Linq.XElement [] Any { 33 | get { 34 | return this.anyField; 35 | } 36 | set { 37 | this.anyField = value; 38 | } 39 | } 40 | 41 | /// 42 | [System.Xml.Serialization.XmlAttributeAttribute ()] 43 | public bool EFlip { 44 | get { 45 | return this.eFlipField; 46 | } 47 | set { 48 | this.eFlipField = value; 49 | } 50 | } 51 | 52 | /// 53 | [System.Xml.Serialization.XmlIgnoreAttribute ()] 54 | public bool EFlipSpecified { 55 | get { 56 | return this.eFlipFieldSpecified; 57 | } 58 | set { 59 | this.eFlipFieldSpecified = value; 60 | } 61 | } 62 | 63 | /// 64 | [System.Xml.Serialization.XmlAttributeAttribute ()] 65 | public bool Reverse { 66 | get { 67 | return this.reverseField; 68 | } 69 | set { 70 | this.reverseField = value; 71 | } 72 | } 73 | 74 | /// 75 | [System.Xml.Serialization.XmlIgnoreAttribute ()] 76 | public bool ReverseSpecified { 77 | get { 78 | return this.reverseFieldSpecified; 79 | } 80 | set { 81 | this.reverseFieldSpecified = value; 82 | } 83 | } 84 | 85 | /// 86 | [System.Xml.Serialization.XmlAttributeAttribute ()] 87 | public bool GetCompatibleConfigurations { 88 | get { 89 | return this.getCompatibleConfigurationsField; 90 | } 91 | set { 92 | this.getCompatibleConfigurationsField = value; 93 | } 94 | } 95 | 96 | /// 97 | [System.Xml.Serialization.XmlIgnoreAttribute ()] 98 | public bool GetCompatibleConfigurationsSpecified { 99 | get { 100 | return this.getCompatibleConfigurationsFieldSpecified; 101 | } 102 | set { 103 | this.getCompatibleConfigurationsFieldSpecified = value; 104 | } 105 | } 106 | 107 | /// 108 | [System.Xml.Serialization.XmlAttributeAttribute ()] 109 | public bool MoveStatus { 110 | get { 111 | return this.moveStatusField; 112 | } 113 | set { 114 | this.moveStatusField = value; 115 | } 116 | } 117 | 118 | /// 119 | [System.Xml.Serialization.XmlIgnoreAttribute ()] 120 | public bool MoveStatusSpecified { 121 | get { 122 | return this.moveStatusFieldSpecified; 123 | } 124 | set { 125 | this.moveStatusFieldSpecified = value; 126 | } 127 | } 128 | 129 | /// 130 | [System.Xml.Serialization.XmlAttributeAttribute ()] 131 | public bool StatusPosition { 132 | get { 133 | return this.statusPositionField; 134 | } 135 | set { 136 | this.statusPositionField = value; 137 | } 138 | } 139 | 140 | /// 141 | [System.Xml.Serialization.XmlIgnoreAttribute ()] 142 | public bool StatusPositionSpecified { 143 | get { 144 | return this.statusPositionFieldSpecified; 145 | } 146 | set { 147 | this.statusPositionFieldSpecified = value; 148 | } 149 | } 150 | } 151 | } -------------------------------------------------------------------------------- /src/Ptz/PTZClient.cs: -------------------------------------------------------------------------------- 1 | using Mictlanix.DotNet.Onvif.Common; 2 | 3 | namespace Mictlanix.DotNet.Onvif.Ptz 4 | { 5 | [System.CodeDom.Compiler.GeneratedCodeAttribute("dotnet-svcutil", "1.0.3")] 6 | [System.ServiceModel.ServiceContractAttribute(Namespace="http://www.onvif.org/ver20/ptz/wsdl", ConfigurationName="Mictlanix.DotNet.Onvif.Ptz.PTZ")] 7 | public interface PTZ 8 | { 9 | 10 | [System.ServiceModel.OperationContractAttribute(Action="http://www.onvif.org/ver20/ptz/wsdl/GetServiceCapabilities", ReplyAction="*")] 11 | [System.ServiceModel.XmlSerializerFormatAttribute(SupportFaults=true)] 12 | [System.ServiceModel.ServiceKnownTypeAttribute(typeof(ConfigurationEntity))] 13 | [System.ServiceModel.ServiceKnownTypeAttribute(typeof(DeviceEntity))] 14 | [return: System.ServiceModel.MessageParameterAttribute(Name="Capabilities")] 15 | System.Threading.Tasks.Task GetServiceCapabilitiesAsync(); 16 | 17 | [System.ServiceModel.OperationContractAttribute(Action="http://www.onvif.org/ver20/ptz/wsdl/GetNodes", ReplyAction="*")] 18 | [System.ServiceModel.XmlSerializerFormatAttribute(SupportFaults=true)] 19 | [System.ServiceModel.ServiceKnownTypeAttribute(typeof(ConfigurationEntity))] 20 | [System.ServiceModel.ServiceKnownTypeAttribute(typeof(DeviceEntity))] 21 | System.Threading.Tasks.Task GetNodesAsync(Mictlanix.DotNet.Onvif.Ptz.GetNodesRequest request); 22 | 23 | [System.ServiceModel.OperationContractAttribute(Action="http://www.onvif.org/ver20/ptz/wsdl/GetNode", ReplyAction="*")] 24 | [System.ServiceModel.XmlSerializerFormatAttribute(SupportFaults=true)] 25 | [System.ServiceModel.ServiceKnownTypeAttribute(typeof(ConfigurationEntity))] 26 | [System.ServiceModel.ServiceKnownTypeAttribute(typeof(DeviceEntity))] 27 | [return: System.ServiceModel.MessageParameterAttribute(Name="PTZNode")] 28 | System.Threading.Tasks.Task GetNodeAsync(string NodeToken); 29 | 30 | [System.ServiceModel.OperationContractAttribute(Action="http://www.onvif.org/ver20/ptz/wsdl/GetConfiguration", ReplyAction="*")] 31 | [System.ServiceModel.XmlSerializerFormatAttribute(SupportFaults=true)] 32 | [System.ServiceModel.ServiceKnownTypeAttribute(typeof(ConfigurationEntity))] 33 | [System.ServiceModel.ServiceKnownTypeAttribute(typeof(DeviceEntity))] 34 | [return: System.ServiceModel.MessageParameterAttribute(Name="PTZConfiguration")] 35 | System.Threading.Tasks.Task GetConfigurationAsync(string PTZConfigurationToken); 36 | 37 | [System.ServiceModel.OperationContractAttribute(Action="http://www.onvif.org/ver20/ptz/wsdl/GetConfigurations", ReplyAction="*")] 38 | [System.ServiceModel.XmlSerializerFormatAttribute(SupportFaults=true)] 39 | [System.ServiceModel.ServiceKnownTypeAttribute(typeof(ConfigurationEntity))] 40 | [System.ServiceModel.ServiceKnownTypeAttribute(typeof(DeviceEntity))] 41 | System.Threading.Tasks.Task GetConfigurationsAsync(Mictlanix.DotNet.Onvif.Ptz.GetConfigurationsRequest request); 42 | 43 | [System.ServiceModel.OperationContractAttribute(Action="http://www.onvif.org/ver20/ptz/wsdl/SetConfiguration", ReplyAction="*")] 44 | [System.ServiceModel.XmlSerializerFormatAttribute(SupportFaults=true)] 45 | [System.ServiceModel.ServiceKnownTypeAttribute(typeof(ConfigurationEntity))] 46 | [System.ServiceModel.ServiceKnownTypeAttribute(typeof(DeviceEntity))] 47 | System.Threading.Tasks.Task SetConfigurationAsync(PTZConfiguration PTZConfiguration, bool ForcePersistence); 48 | 49 | [System.ServiceModel.OperationContractAttribute(Action="http://www.onvif.org/ver20/ptz/wsdl/GetConfigurationOptions", ReplyAction="*")] 50 | [System.ServiceModel.XmlSerializerFormatAttribute(SupportFaults=true)] 51 | [System.ServiceModel.ServiceKnownTypeAttribute(typeof(ConfigurationEntity))] 52 | [System.ServiceModel.ServiceKnownTypeAttribute(typeof(DeviceEntity))] 53 | [return: System.ServiceModel.MessageParameterAttribute(Name="PTZConfigurationOptions")] 54 | System.Threading.Tasks.Task GetConfigurationOptionsAsync(string ConfigurationToken); 55 | 56 | [System.ServiceModel.OperationContractAttribute(Action="http://www.onvif.org/ver20/ptz/wsdl/SendAuxiliaryCommand", ReplyAction="*")] 57 | [System.ServiceModel.XmlSerializerFormatAttribute(SupportFaults=true)] 58 | [System.ServiceModel.ServiceKnownTypeAttribute(typeof(ConfigurationEntity))] 59 | [System.ServiceModel.ServiceKnownTypeAttribute(typeof(DeviceEntity))] 60 | [return: System.ServiceModel.MessageParameterAttribute(Name="AuxiliaryResponse")] 61 | System.Threading.Tasks.Task SendAuxiliaryCommandAsync(string ProfileToken, string AuxiliaryData); 62 | 63 | [System.ServiceModel.OperationContractAttribute(Action="http://www.onvif.org/ver20/ptz/wsdl/GetPresets", ReplyAction="*")] 64 | [System.ServiceModel.XmlSerializerFormatAttribute(SupportFaults=true)] 65 | [System.ServiceModel.ServiceKnownTypeAttribute(typeof(ConfigurationEntity))] 66 | [System.ServiceModel.ServiceKnownTypeAttribute(typeof(DeviceEntity))] 67 | System.Threading.Tasks.Task GetPresetsAsync(Mictlanix.DotNet.Onvif.Ptz.GetPresetsRequest request); 68 | 69 | // CODEGEN: Generating message contract since the operation has multiple return values. 70 | [System.ServiceModel.OperationContractAttribute(Action="http://www.onvif.org/ver20/ptz/wsdl/SetPreset", ReplyAction="*")] 71 | [System.ServiceModel.XmlSerializerFormatAttribute(SupportFaults=true)] 72 | [System.ServiceModel.ServiceKnownTypeAttribute(typeof(ConfigurationEntity))] 73 | [System.ServiceModel.ServiceKnownTypeAttribute(typeof(DeviceEntity))] 74 | System.Threading.Tasks.Task SetPresetAsync(Mictlanix.DotNet.Onvif.Ptz.SetPresetRequest request); 75 | 76 | [System.ServiceModel.OperationContractAttribute(Action="http://www.onvif.org/ver20/ptz/wsdl/RemovePreset", ReplyAction="*")] 77 | [System.ServiceModel.XmlSerializerFormatAttribute(SupportFaults=true)] 78 | [System.ServiceModel.ServiceKnownTypeAttribute(typeof(ConfigurationEntity))] 79 | [System.ServiceModel.ServiceKnownTypeAttribute(typeof(DeviceEntity))] 80 | System.Threading.Tasks.Task RemovePresetAsync(string ProfileToken, string PresetToken); 81 | 82 | [System.ServiceModel.OperationContractAttribute(Action="http://www.onvif.org/ver20/ptz/wsdl/GotoPreset", ReplyAction="*")] 83 | [System.ServiceModel.XmlSerializerFormatAttribute(SupportFaults=true)] 84 | [System.ServiceModel.ServiceKnownTypeAttribute(typeof(ConfigurationEntity))] 85 | [System.ServiceModel.ServiceKnownTypeAttribute(typeof(DeviceEntity))] 86 | System.Threading.Tasks.Task GotoPresetAsync(string ProfileToken, string PresetToken, PTZSpeed Speed); 87 | 88 | [System.ServiceModel.OperationContractAttribute(Action="http://www.onvif.org/ver20/ptz/wsdl/GotoHomePosition", ReplyAction="*")] 89 | [System.ServiceModel.XmlSerializerFormatAttribute(SupportFaults=true)] 90 | [System.ServiceModel.ServiceKnownTypeAttribute(typeof(ConfigurationEntity))] 91 | [System.ServiceModel.ServiceKnownTypeAttribute(typeof(DeviceEntity))] 92 | System.Threading.Tasks.Task GotoHomePositionAsync(string ProfileToken, PTZSpeed Speed); 93 | 94 | [System.ServiceModel.OperationContractAttribute(Action="http://www.onvif.org/ver20/ptz/wsdl/SetHomePosition", ReplyAction="*")] 95 | [System.ServiceModel.XmlSerializerFormatAttribute(SupportFaults=true)] 96 | [System.ServiceModel.ServiceKnownTypeAttribute(typeof(ConfigurationEntity))] 97 | [System.ServiceModel.ServiceKnownTypeAttribute(typeof(DeviceEntity))] 98 | System.Threading.Tasks.Task SetHomePositionAsync(string ProfileToken); 99 | 100 | [System.ServiceModel.OperationContractAttribute(Action="http://www.onvif.org/ver20/ptz/wsdl/ContinuousMove", ReplyAction="*")] 101 | [System.ServiceModel.XmlSerializerFormatAttribute(SupportFaults=true)] 102 | [System.ServiceModel.ServiceKnownTypeAttribute(typeof(ConfigurationEntity))] 103 | [System.ServiceModel.ServiceKnownTypeAttribute(typeof(DeviceEntity))] 104 | System.Threading.Tasks.Task ContinuousMoveAsync(Mictlanix.DotNet.Onvif.Ptz.ContinuousMoveRequest request); 105 | 106 | [System.ServiceModel.OperationContractAttribute(Action="http://www.onvif.org/ver20/ptz/wsdl/RelativeMove", ReplyAction="*")] 107 | [System.ServiceModel.XmlSerializerFormatAttribute(SupportFaults=true)] 108 | [System.ServiceModel.ServiceKnownTypeAttribute(typeof(ConfigurationEntity))] 109 | [System.ServiceModel.ServiceKnownTypeAttribute(typeof(DeviceEntity))] 110 | System.Threading.Tasks.Task RelativeMoveAsync(string ProfileToken, PTZVector Translation, PTZSpeed Speed); 111 | 112 | [System.ServiceModel.OperationContractAttribute(Action="http://www.onvif.org/ver20/ptz/wsdl/GetStatus", ReplyAction="*")] 113 | [System.ServiceModel.XmlSerializerFormatAttribute(SupportFaults=true)] 114 | [System.ServiceModel.ServiceKnownTypeAttribute(typeof(ConfigurationEntity))] 115 | [System.ServiceModel.ServiceKnownTypeAttribute(typeof(DeviceEntity))] 116 | [return: System.ServiceModel.MessageParameterAttribute(Name="PTZStatus")] 117 | System.Threading.Tasks.Task GetStatusAsync(string ProfileToken); 118 | 119 | [System.ServiceModel.OperationContractAttribute(Action="http://www.onvif.org/ver20/ptz/wsdl/AbsoluteMove", ReplyAction="*")] 120 | [System.ServiceModel.XmlSerializerFormatAttribute(SupportFaults=true)] 121 | [System.ServiceModel.ServiceKnownTypeAttribute(typeof(ConfigurationEntity))] 122 | [System.ServiceModel.ServiceKnownTypeAttribute(typeof(DeviceEntity))] 123 | System.Threading.Tasks.Task AbsoluteMoveAsync(string ProfileToken, PTZVector Position, PTZSpeed Speed); 124 | 125 | [System.ServiceModel.OperationContractAttribute(Action="http://www.onvif.org/ver20/ptz/wsdl/GeoMove", ReplyAction="*")] 126 | [System.ServiceModel.XmlSerializerFormatAttribute(SupportFaults=true)] 127 | [System.ServiceModel.ServiceKnownTypeAttribute(typeof(ConfigurationEntity))] 128 | [System.ServiceModel.ServiceKnownTypeAttribute(typeof(DeviceEntity))] 129 | System.Threading.Tasks.Task GeoMoveAsync(string ProfileToken, GeoLocation Target, PTZSpeed Speed, float AreaHeight, float AreaWidth); 130 | 131 | [System.ServiceModel.OperationContractAttribute(Action="http://www.onvif.org/ver20/ptz/wsdl/Stop", ReplyAction="*")] 132 | [System.ServiceModel.XmlSerializerFormatAttribute(SupportFaults=true)] 133 | [System.ServiceModel.ServiceKnownTypeAttribute(typeof(ConfigurationEntity))] 134 | [System.ServiceModel.ServiceKnownTypeAttribute(typeof(DeviceEntity))] 135 | System.Threading.Tasks.Task StopAsync(string ProfileToken, bool PanTilt, bool Zoom); 136 | 137 | [System.ServiceModel.OperationContractAttribute(Action="http://www.onvif.org/ver20/ptz/wsdl/GetPresetTours", ReplyAction="*")] 138 | [System.ServiceModel.XmlSerializerFormatAttribute(SupportFaults=true)] 139 | [System.ServiceModel.ServiceKnownTypeAttribute(typeof(ConfigurationEntity))] 140 | [System.ServiceModel.ServiceKnownTypeAttribute(typeof(DeviceEntity))] 141 | System.Threading.Tasks.Task GetPresetToursAsync(Mictlanix.DotNet.Onvif.Ptz.GetPresetToursRequest request); 142 | 143 | [System.ServiceModel.OperationContractAttribute(Action="http://www.onvif.org/ver20/ptz/wsdl/GetPresetTour", ReplyAction="*")] 144 | [System.ServiceModel.XmlSerializerFormatAttribute(SupportFaults=true)] 145 | [System.ServiceModel.ServiceKnownTypeAttribute(typeof(ConfigurationEntity))] 146 | [System.ServiceModel.ServiceKnownTypeAttribute(typeof(DeviceEntity))] 147 | [return: System.ServiceModel.MessageParameterAttribute(Name="PresetTour")] 148 | System.Threading.Tasks.Task GetPresetTourAsync(string ProfileToken, string PresetTourToken); 149 | 150 | [System.ServiceModel.OperationContractAttribute(Action="http://www.onvif.org/ver20/ptz/wsdl/GetPresetTourOptions", ReplyAction="*")] 151 | [System.ServiceModel.XmlSerializerFormatAttribute(SupportFaults=true)] 152 | [System.ServiceModel.ServiceKnownTypeAttribute(typeof(ConfigurationEntity))] 153 | [System.ServiceModel.ServiceKnownTypeAttribute(typeof(DeviceEntity))] 154 | [return: System.ServiceModel.MessageParameterAttribute(Name="Options")] 155 | System.Threading.Tasks.Task GetPresetTourOptionsAsync(string ProfileToken, string PresetTourToken); 156 | 157 | [System.ServiceModel.OperationContractAttribute(Action="http://www.onvif.org/ver20/ptz/wsdl/CreatePresetTour", ReplyAction="*")] 158 | [System.ServiceModel.XmlSerializerFormatAttribute(SupportFaults=true)] 159 | [System.ServiceModel.ServiceKnownTypeAttribute(typeof(ConfigurationEntity))] 160 | [System.ServiceModel.ServiceKnownTypeAttribute(typeof(DeviceEntity))] 161 | [return: System.ServiceModel.MessageParameterAttribute(Name="PresetTourToken")] 162 | System.Threading.Tasks.Task CreatePresetTourAsync(string ProfileToken); 163 | 164 | [System.ServiceModel.OperationContractAttribute(Action="http://www.onvif.org/ver20/ptz/wsdl/ModifyPresetTour", ReplyAction="*")] 165 | [System.ServiceModel.XmlSerializerFormatAttribute(SupportFaults=true)] 166 | [System.ServiceModel.ServiceKnownTypeAttribute(typeof(ConfigurationEntity))] 167 | [System.ServiceModel.ServiceKnownTypeAttribute(typeof(DeviceEntity))] 168 | System.Threading.Tasks.Task ModifyPresetTourAsync(string ProfileToken, PresetTour PresetTour); 169 | 170 | [System.ServiceModel.OperationContractAttribute(Action="http://www.onvif.org/ver20/ptz/wsdl/OperatePresetTour", ReplyAction="*")] 171 | [System.ServiceModel.XmlSerializerFormatAttribute(SupportFaults=true)] 172 | [System.ServiceModel.ServiceKnownTypeAttribute(typeof(ConfigurationEntity))] 173 | [System.ServiceModel.ServiceKnownTypeAttribute(typeof(DeviceEntity))] 174 | System.Threading.Tasks.Task OperatePresetTourAsync(string ProfileToken, string PresetTourToken, PTZPresetTourOperation Operation); 175 | 176 | [System.ServiceModel.OperationContractAttribute(Action="http://www.onvif.org/ver20/ptz/wsdl/RemovePresetTour", ReplyAction="*")] 177 | [System.ServiceModel.XmlSerializerFormatAttribute(SupportFaults=true)] 178 | [System.ServiceModel.ServiceKnownTypeAttribute(typeof(ConfigurationEntity))] 179 | [System.ServiceModel.ServiceKnownTypeAttribute(typeof(DeviceEntity))] 180 | System.Threading.Tasks.Task RemovePresetTourAsync(string ProfileToken, string PresetTourToken); 181 | 182 | [System.ServiceModel.OperationContractAttribute(Action="http://www.onvif.org/ver20/ptz/wsdl/GetCompatibleConfigurations", ReplyAction="*")] 183 | [System.ServiceModel.XmlSerializerFormatAttribute(SupportFaults=true)] 184 | [System.ServiceModel.ServiceKnownTypeAttribute(typeof(ConfigurationEntity))] 185 | [System.ServiceModel.ServiceKnownTypeAttribute(typeof(DeviceEntity))] 186 | System.Threading.Tasks.Task GetCompatibleConfigurationsAsync(Mictlanix.DotNet.Onvif.Ptz.GetCompatibleConfigurationsRequest request); 187 | } 188 | 189 | [System.Diagnostics.DebuggerStepThroughAttribute()] 190 | [System.CodeDom.Compiler.GeneratedCodeAttribute("dotnet-svcutil", "1.0.3")] 191 | [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Advanced)] 192 | [System.ServiceModel.MessageContractAttribute(WrapperName="GetNodes", WrapperNamespace="http://www.onvif.org/ver20/ptz/wsdl", IsWrapped=true)] 193 | public partial class GetNodesRequest 194 | { 195 | 196 | public GetNodesRequest() 197 | { 198 | } 199 | } 200 | 201 | [System.Diagnostics.DebuggerStepThroughAttribute()] 202 | [System.CodeDom.Compiler.GeneratedCodeAttribute("dotnet-svcutil", "1.0.3")] 203 | [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Advanced)] 204 | [System.ServiceModel.MessageContractAttribute(WrapperName="GetNodesResponse", WrapperNamespace="http://www.onvif.org/ver20/ptz/wsdl", IsWrapped=true)] 205 | public partial class GetNodesResponse 206 | { 207 | 208 | [System.ServiceModel.MessageBodyMemberAttribute(Namespace="http://www.onvif.org/ver20/ptz/wsdl", Order=0)] 209 | [System.Xml.Serialization.XmlElementAttribute("PTZNode")] 210 | public PTZNode[] PTZNode; 211 | 212 | public GetNodesResponse() 213 | { 214 | } 215 | 216 | public GetNodesResponse(PTZNode[] PTZNode) 217 | { 218 | this.PTZNode = PTZNode; 219 | } 220 | } 221 | 222 | [System.Diagnostics.DebuggerStepThroughAttribute()] 223 | [System.CodeDom.Compiler.GeneratedCodeAttribute("dotnet-svcutil", "1.0.3")] 224 | [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Advanced)] 225 | [System.ServiceModel.MessageContractAttribute(WrapperName="GetConfigurations", WrapperNamespace="http://www.onvif.org/ver20/ptz/wsdl", IsWrapped=true)] 226 | public partial class GetConfigurationsRequest 227 | { 228 | 229 | public GetConfigurationsRequest() 230 | { 231 | } 232 | } 233 | 234 | [System.Diagnostics.DebuggerStepThroughAttribute()] 235 | [System.CodeDom.Compiler.GeneratedCodeAttribute("dotnet-svcutil", "1.0.3")] 236 | [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Advanced)] 237 | [System.ServiceModel.MessageContractAttribute(WrapperName="GetConfigurationsResponse", WrapperNamespace="http://www.onvif.org/ver20/ptz/wsdl", IsWrapped=true)] 238 | public partial class GetConfigurationsResponse 239 | { 240 | 241 | [System.ServiceModel.MessageBodyMemberAttribute(Namespace="http://www.onvif.org/ver20/ptz/wsdl", Order=0)] 242 | [System.Xml.Serialization.XmlElementAttribute("PTZConfiguration")] 243 | public PTZConfiguration[] PTZConfiguration; 244 | 245 | public GetConfigurationsResponse() 246 | { 247 | } 248 | 249 | public GetConfigurationsResponse(PTZConfiguration[] PTZConfiguration) 250 | { 251 | this.PTZConfiguration = PTZConfiguration; 252 | } 253 | } 254 | 255 | [System.Diagnostics.DebuggerStepThroughAttribute()] 256 | [System.CodeDom.Compiler.GeneratedCodeAttribute("dotnet-svcutil", "1.0.3")] 257 | [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Advanced)] 258 | [System.ServiceModel.MessageContractAttribute(WrapperName="GetPresets", WrapperNamespace="http://www.onvif.org/ver20/ptz/wsdl", IsWrapped=true)] 259 | public partial class GetPresetsRequest 260 | { 261 | 262 | [System.ServiceModel.MessageBodyMemberAttribute(Namespace="http://www.onvif.org/ver20/ptz/wsdl", Order=0)] 263 | public string ProfileToken; 264 | 265 | public GetPresetsRequest() 266 | { 267 | } 268 | 269 | public GetPresetsRequest(string ProfileToken) 270 | { 271 | this.ProfileToken = ProfileToken; 272 | } 273 | } 274 | 275 | [System.Diagnostics.DebuggerStepThroughAttribute()] 276 | [System.CodeDom.Compiler.GeneratedCodeAttribute("dotnet-svcutil", "1.0.3")] 277 | [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Advanced)] 278 | [System.ServiceModel.MessageContractAttribute(WrapperName="GetPresetsResponse", WrapperNamespace="http://www.onvif.org/ver20/ptz/wsdl", IsWrapped=true)] 279 | public partial class GetPresetsResponse 280 | { 281 | 282 | [System.ServiceModel.MessageBodyMemberAttribute(Namespace="http://www.onvif.org/ver20/ptz/wsdl", Order=0)] 283 | [System.Xml.Serialization.XmlElementAttribute("Preset")] 284 | public PTZPreset[] Preset; 285 | 286 | public GetPresetsResponse() 287 | { 288 | } 289 | 290 | public GetPresetsResponse(PTZPreset[] Preset) 291 | { 292 | this.Preset = Preset; 293 | } 294 | } 295 | 296 | [System.Diagnostics.DebuggerStepThroughAttribute()] 297 | [System.CodeDom.Compiler.GeneratedCodeAttribute("dotnet-svcutil", "1.0.3")] 298 | [System.ServiceModel.MessageContractAttribute(WrapperName="SetPreset", WrapperNamespace="http://www.onvif.org/ver20/ptz/wsdl", IsWrapped=true)] 299 | public partial class SetPresetRequest 300 | { 301 | 302 | [System.ServiceModel.MessageBodyMemberAttribute(Namespace="http://www.onvif.org/ver20/ptz/wsdl", Order=0)] 303 | public string ProfileToken; 304 | 305 | [System.ServiceModel.MessageBodyMemberAttribute(Namespace="http://www.onvif.org/ver20/ptz/wsdl", Order=1)] 306 | public string PresetName; 307 | 308 | [System.ServiceModel.MessageBodyMemberAttribute(Namespace="http://www.onvif.org/ver20/ptz/wsdl", Order=2)] 309 | public string PresetToken; 310 | 311 | public SetPresetRequest() 312 | { 313 | } 314 | 315 | public SetPresetRequest(string ProfileToken, string PresetName, string PresetToken) 316 | { 317 | this.ProfileToken = ProfileToken; 318 | this.PresetName = PresetName; 319 | this.PresetToken = PresetToken; 320 | } 321 | } 322 | 323 | [System.Diagnostics.DebuggerStepThroughAttribute()] 324 | [System.CodeDom.Compiler.GeneratedCodeAttribute("dotnet-svcutil", "1.0.3")] 325 | [System.ServiceModel.MessageContractAttribute(WrapperName="SetPresetResponse", WrapperNamespace="http://www.onvif.org/ver20/ptz/wsdl", IsWrapped=true)] 326 | public partial class SetPresetResponse 327 | { 328 | 329 | [System.ServiceModel.MessageBodyMemberAttribute(Namespace="http://www.onvif.org/ver20/ptz/wsdl", Order=0)] 330 | public string PresetToken; 331 | 332 | public SetPresetResponse() 333 | { 334 | } 335 | 336 | public SetPresetResponse(string PresetToken) 337 | { 338 | this.PresetToken = PresetToken; 339 | } 340 | } 341 | 342 | [System.Diagnostics.DebuggerStepThroughAttribute()] 343 | [System.CodeDom.Compiler.GeneratedCodeAttribute("dotnet-svcutil", "1.0.3")] 344 | [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Advanced)] 345 | [System.ServiceModel.MessageContractAttribute(WrapperName="ContinuousMove", WrapperNamespace="http://www.onvif.org/ver20/ptz/wsdl", IsWrapped=true)] 346 | public partial class ContinuousMoveRequest 347 | { 348 | 349 | [System.ServiceModel.MessageBodyMemberAttribute(Namespace="http://www.onvif.org/ver20/ptz/wsdl", Order=0)] 350 | public string ProfileToken; 351 | 352 | [System.ServiceModel.MessageBodyMemberAttribute(Namespace="http://www.onvif.org/ver20/ptz/wsdl", Order=1)] 353 | public PTZSpeed Velocity; 354 | 355 | [System.ServiceModel.MessageBodyMemberAttribute(Namespace="http://www.onvif.org/ver20/ptz/wsdl", Order=2)] 356 | [System.Xml.Serialization.XmlElementAttribute(DataType="duration")] 357 | public string Timeout; 358 | 359 | public ContinuousMoveRequest() 360 | { 361 | } 362 | 363 | public ContinuousMoveRequest(string ProfileToken, PTZSpeed Velocity, string Timeout) 364 | { 365 | this.ProfileToken = ProfileToken; 366 | this.Velocity = Velocity; 367 | this.Timeout = Timeout; 368 | } 369 | } 370 | 371 | [System.Diagnostics.DebuggerStepThroughAttribute()] 372 | [System.CodeDom.Compiler.GeneratedCodeAttribute("dotnet-svcutil", "1.0.3")] 373 | [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Advanced)] 374 | [System.ServiceModel.MessageContractAttribute(WrapperName="ContinuousMoveResponse", WrapperNamespace="http://www.onvif.org/ver20/ptz/wsdl", IsWrapped=true)] 375 | public partial class ContinuousMoveResponse 376 | { 377 | 378 | public ContinuousMoveResponse() 379 | { 380 | } 381 | } 382 | 383 | [System.Diagnostics.DebuggerStepThroughAttribute()] 384 | [System.CodeDom.Compiler.GeneratedCodeAttribute("dotnet-svcutil", "1.0.3")] 385 | [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Advanced)] 386 | [System.ServiceModel.MessageContractAttribute(WrapperName="GetPresetTours", WrapperNamespace="http://www.onvif.org/ver20/ptz/wsdl", IsWrapped=true)] 387 | public partial class GetPresetToursRequest 388 | { 389 | 390 | [System.ServiceModel.MessageBodyMemberAttribute(Namespace="http://www.onvif.org/ver20/ptz/wsdl", Order=0)] 391 | public string ProfileToken; 392 | 393 | public GetPresetToursRequest() 394 | { 395 | } 396 | 397 | public GetPresetToursRequest(string ProfileToken) 398 | { 399 | this.ProfileToken = ProfileToken; 400 | } 401 | } 402 | 403 | [System.Diagnostics.DebuggerStepThroughAttribute()] 404 | [System.CodeDom.Compiler.GeneratedCodeAttribute("dotnet-svcutil", "1.0.3")] 405 | [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Advanced)] 406 | [System.ServiceModel.MessageContractAttribute(WrapperName="GetPresetToursResponse", WrapperNamespace="http://www.onvif.org/ver20/ptz/wsdl", IsWrapped=true)] 407 | public partial class GetPresetToursResponse 408 | { 409 | 410 | [System.ServiceModel.MessageBodyMemberAttribute(Namespace="http://www.onvif.org/ver20/ptz/wsdl", Order=0)] 411 | [System.Xml.Serialization.XmlElementAttribute("PresetTour")] 412 | public PresetTour[] PresetTour; 413 | 414 | public GetPresetToursResponse() 415 | { 416 | } 417 | 418 | public GetPresetToursResponse(PresetTour[] PresetTour) 419 | { 420 | this.PresetTour = PresetTour; 421 | } 422 | } 423 | 424 | [System.Diagnostics.DebuggerStepThroughAttribute()] 425 | [System.CodeDom.Compiler.GeneratedCodeAttribute("dotnet-svcutil", "1.0.3")] 426 | [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Advanced)] 427 | [System.ServiceModel.MessageContractAttribute(WrapperName="GetCompatibleConfigurations", WrapperNamespace="http://www.onvif.org/ver20/ptz/wsdl", IsWrapped=true)] 428 | public partial class GetCompatibleConfigurationsRequest 429 | { 430 | 431 | [System.ServiceModel.MessageBodyMemberAttribute(Namespace="http://www.onvif.org/ver20/ptz/wsdl", Order=0)] 432 | public string ProfileToken; 433 | 434 | public GetCompatibleConfigurationsRequest() 435 | { 436 | } 437 | 438 | public GetCompatibleConfigurationsRequest(string ProfileToken) 439 | { 440 | this.ProfileToken = ProfileToken; 441 | } 442 | } 443 | 444 | [System.Diagnostics.DebuggerStepThroughAttribute()] 445 | [System.CodeDom.Compiler.GeneratedCodeAttribute("dotnet-svcutil", "1.0.3")] 446 | [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Advanced)] 447 | [System.ServiceModel.MessageContractAttribute(WrapperName="GetCompatibleConfigurationsResponse", WrapperNamespace="http://www.onvif.org/ver20/ptz/wsdl", IsWrapped=true)] 448 | public partial class GetCompatibleConfigurationsResponse 449 | { 450 | 451 | [System.ServiceModel.MessageBodyMemberAttribute(Namespace="http://www.onvif.org/ver20/ptz/wsdl", Order=0)] 452 | [System.Xml.Serialization.XmlElementAttribute("PTZConfiguration")] 453 | public PTZConfiguration[] PTZConfiguration; 454 | 455 | public GetCompatibleConfigurationsResponse() 456 | { 457 | } 458 | 459 | public GetCompatibleConfigurationsResponse(PTZConfiguration[] PTZConfiguration) 460 | { 461 | this.PTZConfiguration = PTZConfiguration; 462 | } 463 | } 464 | 465 | [System.CodeDom.Compiler.GeneratedCodeAttribute("dotnet-svcutil", "1.0.3")] 466 | public interface PTZChannel : Mictlanix.DotNet.Onvif.Ptz.PTZ, System.ServiceModel.IClientChannel 467 | { 468 | } 469 | 470 | [System.Diagnostics.DebuggerStepThroughAttribute()] 471 | [System.CodeDom.Compiler.GeneratedCodeAttribute("dotnet-svcutil", "1.0.3")] 472 | public partial class PTZClient : System.ServiceModel.ClientBase, Mictlanix.DotNet.Onvif.Ptz.PTZ 473 | { 474 | 475 | internal PTZClient(System.ServiceModel.Channels.Binding binding, System.ServiceModel.EndpointAddress remoteAddress) : 476 | base(binding, remoteAddress) 477 | { 478 | } 479 | 480 | public System.Threading.Tasks.Task GetServiceCapabilitiesAsync() 481 | { 482 | return base.Channel.GetServiceCapabilitiesAsync(); 483 | } 484 | 485 | [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Advanced)] 486 | System.Threading.Tasks.Task Mictlanix.DotNet.Onvif.Ptz.PTZ.GetNodesAsync(Mictlanix.DotNet.Onvif.Ptz.GetNodesRequest request) 487 | { 488 | return base.Channel.GetNodesAsync(request); 489 | } 490 | 491 | public System.Threading.Tasks.Task GetNodesAsync() 492 | { 493 | Mictlanix.DotNet.Onvif.Ptz.GetNodesRequest inValue = new Mictlanix.DotNet.Onvif.Ptz.GetNodesRequest(); 494 | return ((Mictlanix.DotNet.Onvif.Ptz.PTZ)(this)).GetNodesAsync(inValue); 495 | } 496 | 497 | public System.Threading.Tasks.Task GetNodeAsync(string NodeToken) 498 | { 499 | return base.Channel.GetNodeAsync(NodeToken); 500 | } 501 | 502 | public System.Threading.Tasks.Task GetConfigurationAsync(string PTZConfigurationToken) 503 | { 504 | return base.Channel.GetConfigurationAsync(PTZConfigurationToken); 505 | } 506 | 507 | [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Advanced)] 508 | System.Threading.Tasks.Task Mictlanix.DotNet.Onvif.Ptz.PTZ.GetConfigurationsAsync(Mictlanix.DotNet.Onvif.Ptz.GetConfigurationsRequest request) 509 | { 510 | return base.Channel.GetConfigurationsAsync(request); 511 | } 512 | 513 | public System.Threading.Tasks.Task GetConfigurationsAsync() 514 | { 515 | Mictlanix.DotNet.Onvif.Ptz.GetConfigurationsRequest inValue = new Mictlanix.DotNet.Onvif.Ptz.GetConfigurationsRequest(); 516 | return ((Mictlanix.DotNet.Onvif.Ptz.PTZ)(this)).GetConfigurationsAsync(inValue); 517 | } 518 | 519 | public System.Threading.Tasks.Task SetConfigurationAsync(PTZConfiguration PTZConfiguration, bool ForcePersistence) 520 | { 521 | return base.Channel.SetConfigurationAsync(PTZConfiguration, ForcePersistence); 522 | } 523 | 524 | public System.Threading.Tasks.Task GetConfigurationOptionsAsync(string ConfigurationToken) 525 | { 526 | return base.Channel.GetConfigurationOptionsAsync(ConfigurationToken); 527 | } 528 | 529 | public System.Threading.Tasks.Task SendAuxiliaryCommandAsync(string ProfileToken, string AuxiliaryData) 530 | { 531 | return base.Channel.SendAuxiliaryCommandAsync(ProfileToken, AuxiliaryData); 532 | } 533 | 534 | [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Advanced)] 535 | System.Threading.Tasks.Task Mictlanix.DotNet.Onvif.Ptz.PTZ.GetPresetsAsync(Mictlanix.DotNet.Onvif.Ptz.GetPresetsRequest request) 536 | { 537 | return base.Channel.GetPresetsAsync(request); 538 | } 539 | 540 | public System.Threading.Tasks.Task GetPresetsAsync(string ProfileToken) 541 | { 542 | Mictlanix.DotNet.Onvif.Ptz.GetPresetsRequest inValue = new Mictlanix.DotNet.Onvif.Ptz.GetPresetsRequest(); 543 | inValue.ProfileToken = ProfileToken; 544 | return ((Mictlanix.DotNet.Onvif.Ptz.PTZ)(this)).GetPresetsAsync(inValue); 545 | } 546 | 547 | public System.Threading.Tasks.Task SetPresetAsync(Mictlanix.DotNet.Onvif.Ptz.SetPresetRequest request) 548 | { 549 | return base.Channel.SetPresetAsync(request); 550 | } 551 | 552 | public System.Threading.Tasks.Task RemovePresetAsync(string ProfileToken, string PresetToken) 553 | { 554 | return base.Channel.RemovePresetAsync(ProfileToken, PresetToken); 555 | } 556 | 557 | public System.Threading.Tasks.Task GotoPresetAsync(string ProfileToken, string PresetToken, PTZSpeed Speed) 558 | { 559 | return base.Channel.GotoPresetAsync(ProfileToken, PresetToken, Speed); 560 | } 561 | 562 | public System.Threading.Tasks.Task GotoHomePositionAsync(string ProfileToken, PTZSpeed Speed) 563 | { 564 | return base.Channel.GotoHomePositionAsync(ProfileToken, Speed); 565 | } 566 | 567 | public System.Threading.Tasks.Task SetHomePositionAsync(string ProfileToken) 568 | { 569 | return base.Channel.SetHomePositionAsync(ProfileToken); 570 | } 571 | 572 | [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Advanced)] 573 | System.Threading.Tasks.Task Mictlanix.DotNet.Onvif.Ptz.PTZ.ContinuousMoveAsync(Mictlanix.DotNet.Onvif.Ptz.ContinuousMoveRequest request) 574 | { 575 | return base.Channel.ContinuousMoveAsync(request); 576 | } 577 | 578 | public System.Threading.Tasks.Task ContinuousMoveAsync(string ProfileToken, PTZSpeed Velocity, string Timeout) 579 | { 580 | Mictlanix.DotNet.Onvif.Ptz.ContinuousMoveRequest inValue = new Mictlanix.DotNet.Onvif.Ptz.ContinuousMoveRequest(); 581 | inValue.ProfileToken = ProfileToken; 582 | inValue.Velocity = Velocity; 583 | inValue.Timeout = Timeout; 584 | return ((Mictlanix.DotNet.Onvif.Ptz.PTZ)(this)).ContinuousMoveAsync(inValue); 585 | } 586 | 587 | public System.Threading.Tasks.Task RelativeMoveAsync(string ProfileToken, PTZVector Translation, PTZSpeed Speed) 588 | { 589 | return base.Channel.RelativeMoveAsync(ProfileToken, Translation, Speed); 590 | } 591 | 592 | public System.Threading.Tasks.Task GetStatusAsync(string ProfileToken) 593 | { 594 | return base.Channel.GetStatusAsync(ProfileToken); 595 | } 596 | 597 | public System.Threading.Tasks.Task AbsoluteMoveAsync(string ProfileToken, PTZVector Position, PTZSpeed Speed) 598 | { 599 | return base.Channel.AbsoluteMoveAsync(ProfileToken, Position, Speed); 600 | } 601 | 602 | public System.Threading.Tasks.Task GeoMoveAsync(string ProfileToken, GeoLocation Target, PTZSpeed Speed, float AreaHeight, float AreaWidth) 603 | { 604 | return base.Channel.GeoMoveAsync(ProfileToken, Target, Speed, AreaHeight, AreaWidth); 605 | } 606 | 607 | public System.Threading.Tasks.Task StopAsync(string ProfileToken, bool PanTilt, bool Zoom) 608 | { 609 | return base.Channel.StopAsync(ProfileToken, PanTilt, Zoom); 610 | } 611 | 612 | [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Advanced)] 613 | System.Threading.Tasks.Task Mictlanix.DotNet.Onvif.Ptz.PTZ.GetPresetToursAsync(Mictlanix.DotNet.Onvif.Ptz.GetPresetToursRequest request) 614 | { 615 | return base.Channel.GetPresetToursAsync(request); 616 | } 617 | 618 | public System.Threading.Tasks.Task GetPresetToursAsync(string ProfileToken) 619 | { 620 | Mictlanix.DotNet.Onvif.Ptz.GetPresetToursRequest inValue = new Mictlanix.DotNet.Onvif.Ptz.GetPresetToursRequest(); 621 | inValue.ProfileToken = ProfileToken; 622 | return ((Mictlanix.DotNet.Onvif.Ptz.PTZ)(this)).GetPresetToursAsync(inValue); 623 | } 624 | 625 | public System.Threading.Tasks.Task GetPresetTourAsync(string ProfileToken, string PresetTourToken) 626 | { 627 | return base.Channel.GetPresetTourAsync(ProfileToken, PresetTourToken); 628 | } 629 | 630 | public System.Threading.Tasks.Task GetPresetTourOptionsAsync(string ProfileToken, string PresetTourToken) 631 | { 632 | return base.Channel.GetPresetTourOptionsAsync(ProfileToken, PresetTourToken); 633 | } 634 | 635 | public System.Threading.Tasks.Task CreatePresetTourAsync(string ProfileToken) 636 | { 637 | return base.Channel.CreatePresetTourAsync(ProfileToken); 638 | } 639 | 640 | public System.Threading.Tasks.Task ModifyPresetTourAsync(string ProfileToken, PresetTour PresetTour) 641 | { 642 | return base.Channel.ModifyPresetTourAsync(ProfileToken, PresetTour); 643 | } 644 | 645 | public System.Threading.Tasks.Task OperatePresetTourAsync(string ProfileToken, string PresetTourToken, PTZPresetTourOperation Operation) 646 | { 647 | return base.Channel.OperatePresetTourAsync(ProfileToken, PresetTourToken, Operation); 648 | } 649 | 650 | public System.Threading.Tasks.Task RemovePresetTourAsync(string ProfileToken, string PresetTourToken) 651 | { 652 | return base.Channel.RemovePresetTourAsync(ProfileToken, PresetTourToken); 653 | } 654 | 655 | [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Advanced)] 656 | System.Threading.Tasks.Task Mictlanix.DotNet.Onvif.Ptz.PTZ.GetCompatibleConfigurationsAsync(Mictlanix.DotNet.Onvif.Ptz.GetCompatibleConfigurationsRequest request) 657 | { 658 | return base.Channel.GetCompatibleConfigurationsAsync(request); 659 | } 660 | 661 | public System.Threading.Tasks.Task GetCompatibleConfigurationsAsync(string ProfileToken) 662 | { 663 | Mictlanix.DotNet.Onvif.Ptz.GetCompatibleConfigurationsRequest inValue = new Mictlanix.DotNet.Onvif.Ptz.GetCompatibleConfigurationsRequest(); 664 | inValue.ProfileToken = ProfileToken; 665 | return ((Mictlanix.DotNet.Onvif.Ptz.PTZ)(this)).GetCompatibleConfigurationsAsync(inValue); 666 | } 667 | 668 | public virtual System.Threading.Tasks.Task OpenAsync() 669 | { 670 | return System.Threading.Tasks.Task.Factory.FromAsync(((System.ServiceModel.ICommunicationObject)(this)).BeginOpen(null, null), new System.Action(((System.ServiceModel.ICommunicationObject)(this)).EndOpen)); 671 | } 672 | 673 | public virtual System.Threading.Tasks.Task CloseAsync() 674 | { 675 | return System.Threading.Tasks.Task.Factory.FromAsync(((System.ServiceModel.ICommunicationObject)(this)).BeginClose(null, null), new System.Action(((System.ServiceModel.ICommunicationObject)(this)).EndClose)); 676 | } 677 | } 678 | } 679 | -------------------------------------------------------------------------------- /src/Security/SoapSecurityHeader.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Security.Cryptography; 3 | using System.ServiceModel.Channels; 4 | using System.Text; 5 | using System.Xml; 6 | 7 | namespace Mictlanix.DotNet.Onvif.Security { 8 | public class SoapSecurityHeader : MessageHeader { 9 | const string ns_wsu = "http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd"; 10 | readonly string username; 11 | readonly string password; 12 | readonly TimeSpan time_shift; 13 | 14 | public override string Name { get; } = "Security"; 15 | public override string Namespace { get; } = "http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd"; 16 | 17 | public SoapSecurityHeader (string username, string password, TimeSpan timeShift) 18 | { 19 | this.username = username; 20 | this.password = password; 21 | time_shift = timeShift; 22 | } 23 | 24 | protected override void OnWriteHeaderContents (XmlDictionaryWriter writer, MessageVersion messageVersion) 25 | { 26 | var nonce = GetNonce (); 27 | var created = DateTime.UtcNow.Add (time_shift).ToString ("yyyy-MM-ddTHH:mm:ss.fffZ"); 28 | var nonce_str = Convert.ToBase64String (nonce); 29 | string password_hash = PasswordDigest (nonce, created, password); 30 | 31 | writer.WriteStartElement ("UsernameToken"); 32 | 33 | writer.WriteStartElement ("Username"); 34 | writer.WriteValue (username); 35 | writer.WriteEndElement (); 36 | 37 | writer.WriteStartElement ("Password"); 38 | writer.WriteAttributeString ("Type", "http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-username-token-profile-1.0#PasswordDigest"); 39 | writer.WriteValue (password_hash); 40 | writer.WriteEndElement (); 41 | 42 | writer.WriteStartElement ("Nonce"); 43 | writer.WriteAttributeString ("EncodingType", "http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-soap-message-security-1.0#Base64Binary"); 44 | writer.WriteValue (nonce_str); 45 | writer.WriteEndElement (); 46 | 47 | writer.WriteStartElement ("Created"); 48 | writer.WriteXmlnsAttribute ("", ns_wsu); 49 | writer.WriteValue (created); 50 | writer.WriteEndElement (); 51 | 52 | writer.WriteEndElement (); 53 | } 54 | 55 | protected override void OnWriteStartHeader (XmlDictionaryWriter writer, MessageVersion messageVersion) 56 | { 57 | writer.WriteStartElement ("", Name, Namespace); 58 | writer.WriteAttributeString ("s", "mustUnderstand", "http://www.w3.org/2003/05/soap-envelope", "1"); 59 | writer.WriteXmlnsAttribute ("", Namespace); 60 | } 61 | 62 | string PasswordDigest (byte [] nonce, string created, string secret) 63 | { 64 | byte [] buffer = new byte [nonce.Length + Encoding.ASCII.GetByteCount (created + secret)]; 65 | 66 | nonce.CopyTo (buffer, 0); 67 | Encoding.ASCII.GetBytes (created + password).CopyTo (buffer, nonce.Length); 68 | 69 | return Convert.ToBase64String (SHA1.Create ().ComputeHash (buffer)); 70 | } 71 | 72 | byte [] GetNonce () 73 | { 74 | byte [] nonce = new byte [0x10]; 75 | var generator = new RNGCryptoServiceProvider (); 76 | generator.GetBytes (nonce); 77 | return nonce; 78 | } 79 | } 80 | } -------------------------------------------------------------------------------- /src/Security/SoapSecurityHeaderBehavior.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.ServiceModel.Channels; 3 | using System.ServiceModel.Description; 4 | using System.ServiceModel.Dispatcher; 5 | 6 | namespace Mictlanix.DotNet.Onvif.Security { 7 | public class SoapSecurityHeaderBehavior : IEndpointBehavior { 8 | readonly string username; 9 | readonly string password; 10 | readonly TimeSpan time_shift; 11 | 12 | public SoapSecurityHeaderBehavior (string username, string password) : this (username, password, TimeSpan.FromMilliseconds (0)) 13 | { 14 | } 15 | 16 | public SoapSecurityHeaderBehavior (string username, string password, TimeSpan timeShift) 17 | { 18 | this.username = username; 19 | this.password = password; 20 | time_shift = timeShift; 21 | } 22 | 23 | public void AddBindingParameters (ServiceEndpoint endpoint, BindingParameterCollection bindingParameters) 24 | { 25 | 26 | } 27 | 28 | public void ApplyClientBehavior (ServiceEndpoint endpoint, ClientRuntime clientRuntime) 29 | { 30 | clientRuntime.ClientMessageInspectors.Add (new SoapSecurityHeaderInspector (username, password, time_shift)); 31 | } 32 | 33 | public void ApplyDispatchBehavior (ServiceEndpoint endpoint, EndpointDispatcher endpointDispatcher) 34 | { 35 | 36 | } 37 | 38 | public void Validate (ServiceEndpoint endpoint) 39 | { 40 | 41 | } 42 | } 43 | } 44 | -------------------------------------------------------------------------------- /src/Security/SoapSecurityHeaderInspector.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.ServiceModel; 3 | using System.ServiceModel.Channels; 4 | using System.ServiceModel.Dispatcher; 5 | 6 | namespace Mictlanix.DotNet.Onvif.Security { 7 | public class SoapSecurityHeaderInspector : IClientMessageInspector { 8 | readonly string username; 9 | readonly string password; 10 | readonly TimeSpan time_shift; 11 | 12 | public SoapSecurityHeaderInspector (string username, string password, TimeSpan timeShift) 13 | { 14 | this.username = username; 15 | this.password = password; 16 | time_shift = timeShift; 17 | } 18 | 19 | public void AfterReceiveReply (ref Message reply, object correlationState) 20 | { 21 | 22 | } 23 | 24 | public object BeforeSendRequest (ref Message request, IClientChannel channel) 25 | { 26 | request.Headers.Add (new SoapSecurityHeader (username, password, time_shift)); 27 | 28 | return null; 29 | } 30 | } 31 | } 32 | -------------------------------------------------------------------------------- /test/OnvifTests.csproj: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | Exe 5 | netcoreapp2.1 6 | 0.0.3 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /test/Program.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Threading.Tasks; 3 | using Mictlanix.DotNet.Onvif.Common; 4 | using Mictlanix.DotNet.Onvif.Ptz; 5 | 6 | namespace Mictlanix.DotNet.Onvif.Tests { 7 | class Program { 8 | static void Main (string[] args) 9 | { 10 | var host = args[0]; 11 | var username = args[1]; 12 | var password = args[2]; 13 | 14 | MainAsync (host, username, password).Wait (); 15 | } 16 | 17 | static async Task MainAsync (string host, string username, string password) 18 | { 19 | var device = await OnvifClientFactory.CreateDeviceClientAsync (host, username, password); 20 | var media = await OnvifClientFactory.CreateMediaClientAsync (host, username, password); 21 | var ptz = await OnvifClientFactory.CreatePTZClientAsync (host, username, password); 22 | var imaging = await OnvifClientFactory.CreateImagingClientAsync (host, username, password); 23 | var caps = await device.GetCapabilitiesAsync (new CapabilityCategory[] { CapabilityCategory.All }); 24 | bool absolute_move = false; 25 | bool relative_move = false; 26 | bool continuous_move = false; 27 | bool focus = false; 28 | 29 | Console.WriteLine ("Capabilities"); 30 | 31 | Console.WriteLine ("\tDevice: " + caps.Capabilities.Device.XAddr); 32 | Console.WriteLine ("\tEvents: " + caps.Capabilities.Events.XAddr); 33 | Console.WriteLine ("\tImaging: " + caps.Capabilities.Imaging.XAddr); 34 | Console.WriteLine ("\tMedia: " + caps.Capabilities.Media.XAddr); 35 | Console.WriteLine ("\tPTZ: " + caps.Capabilities.PTZ.XAddr); 36 | 37 | var profiles = await media.GetProfilesAsync (); 38 | string profile_token = null; 39 | 40 | Console.WriteLine ("Profiles count :" + profiles.Profiles.Length); 41 | 42 | foreach (var profile in profiles.Profiles) { 43 | Console.WriteLine ($"Profile: {profile.token}"); 44 | 45 | if (profile_token == null) { 46 | profile_token = profile.token; 47 | absolute_move = !string.IsNullOrWhiteSpace (profile.PTZConfiguration.DefaultAbsolutePantTiltPositionSpace); 48 | relative_move = !string.IsNullOrWhiteSpace (profile.PTZConfiguration.DefaultRelativePanTiltTranslationSpace); 49 | continuous_move = !string.IsNullOrWhiteSpace (profile.PTZConfiguration.DefaultContinuousPanTiltVelocitySpace); 50 | } 51 | 52 | Console.WriteLine ($"\tTranslation Support"); 53 | Console.WriteLine ($"\t\tAbsolute Translation: {!string.IsNullOrWhiteSpace (profile.PTZConfiguration.DefaultAbsolutePantTiltPositionSpace)}"); 54 | Console.WriteLine ($"\t\tRelative Translation: {!string.IsNullOrWhiteSpace (profile.PTZConfiguration.DefaultRelativePanTiltTranslationSpace)}"); 55 | Console.WriteLine ($"\t\tContinuous Translation: {!string.IsNullOrWhiteSpace (profile.PTZConfiguration.DefaultContinuousPanTiltVelocitySpace)}"); 56 | 57 | if(!string.IsNullOrWhiteSpace (profile.PTZConfiguration.DefaultRelativePanTiltTranslationSpace)) { 58 | var pan = profile.PTZConfiguration.PanTiltLimits.Range.XRange; 59 | var tilt = profile.PTZConfiguration.PanTiltLimits.Range.YRange; 60 | var zoom = profile.PTZConfiguration.ZoomLimits.Range.XRange; 61 | 62 | Console.WriteLine ($"\tPan Limits: [{pan.Min}, {pan.Max}] Tilt Limits: [{tilt.Min}, {tilt.Max}] Tilt Limits: [{zoom.Min}, {zoom.Max}]"); 63 | } 64 | } 65 | 66 | var configs = await ptz.GetConfigurationsAsync (); 67 | 68 | foreach (var config in configs.PTZConfiguration) { 69 | Console.WriteLine ($"PTZ Configuration: {config.token}"); 70 | } 71 | 72 | var video_sources = await media.GetVideoSourcesAsync (); 73 | string vsource_token = null; 74 | 75 | foreach (var source in video_sources.VideoSources) { 76 | Console.WriteLine ($"Video Source: {source.token}"); 77 | 78 | if (vsource_token == null) { 79 | vsource_token = source.token; 80 | focus = source.Imaging.Focus != null; 81 | } 82 | 83 | Console.WriteLine ($"\tFramerate: {source.Framerate}"); 84 | Console.WriteLine ($"\tResolution: {source.Resolution.Width}x{source.Resolution.Height}"); 85 | 86 | Console.WriteLine ($"\tFocus Settings"); 87 | 88 | if (source.Imaging.Focus == null) { 89 | Console.WriteLine ($"\t\tNone"); 90 | } else { 91 | Console.WriteLine ($"\t\tMode: {source.Imaging.Focus.AutoFocusMode}"); 92 | Console.WriteLine ($"\t\tNear Limit: {source.Imaging.Focus.NearLimit}"); 93 | Console.WriteLine ($"\t\tFar Limit: {source.Imaging.Focus.FarLimit}"); 94 | Console.WriteLine ($"\t\tDefault Speed: {source.Imaging.Focus.DefaultSpeed}"); 95 | } 96 | 97 | Console.WriteLine ($"\tExposure Settings"); 98 | 99 | if (source.Imaging.Exposure == null) { 100 | Console.WriteLine ($"\t\tNone"); 101 | } else { 102 | Console.WriteLine ($"\t\tMode: {source.Imaging.Exposure.Mode}"); 103 | Console.WriteLine ($"\t\tMin Iris: {source.Imaging.Exposure.MinIris}"); 104 | Console.WriteLine ($"\t\tMax Iris: {source.Imaging.Exposure.MaxIris}"); 105 | } 106 | 107 | Console.WriteLine ($"\tImage Settings"); 108 | 109 | var imaging_opts = await imaging.GetOptionsAsync (source.token); 110 | 111 | Console.WriteLine ($"\t\tBrightness: {source.Imaging.Brightness} [{imaging_opts.Brightness?.Min}, {imaging_opts.Brightness?.Max}]"); 112 | Console.WriteLine ($"\t\tColor Saturation: {source.Imaging.ColorSaturation} [{imaging_opts.ColorSaturation?.Min}, {imaging_opts.ColorSaturation?.Max}]"); 113 | Console.WriteLine ($"\t\tContrast: {source.Imaging.Contrast} [{imaging_opts.Contrast?.Min}, {imaging_opts.Contrast?.Max}]"); 114 | Console.WriteLine ($"\t\tSharpness: {source.Imaging.Sharpness} [{imaging_opts.Sharpness?.Min}, {imaging_opts.Sharpness?.Max}]"); 115 | } 116 | 117 | if (focus) { 118 | Console.WriteLine ($"Focus"); 119 | 120 | var image_status = await imaging.GetStatusAsync (vsource_token); 121 | 122 | Console.WriteLine ($"\tStatus"); 123 | 124 | Console.WriteLine ($"\t\tPosition: {image_status.FocusStatus20.Position}"); 125 | Console.WriteLine ($"\t\tStatus: {image_status.FocusStatus20.MoveStatus}"); 126 | Console.WriteLine ($"\t\tError: {image_status.FocusStatus20.Error}"); 127 | 128 | Console.WriteLine ($"\tSetting Focus Mode: Manual"); 129 | 130 | var image_settings = await imaging.GetImagingSettingsAsync (vsource_token); 131 | 132 | if (image_settings.Focus == null) { 133 | image_settings.Focus = new FocusConfiguration20 { 134 | AutoFocusMode = AutoFocusMode.MANUAL 135 | }; 136 | 137 | await imaging.SetImagingSettingsAsync (vsource_token, image_settings, false); 138 | } else if (image_settings.Focus.AutoFocusMode != AutoFocusMode.MANUAL) { 139 | image_settings.Focus.AutoFocusMode = AutoFocusMode.MANUAL; 140 | await imaging.SetImagingSettingsAsync (vsource_token, image_settings, false); 141 | } 142 | } 143 | 144 | var focus_opts = await imaging.GetMoveOptionsAsync (vsource_token); 145 | 146 | if (focus_opts.Absolute != null) { 147 | Console.WriteLine ($"\tMoving Focus Absolute"); 148 | 149 | await imaging.MoveAsync (vsource_token, new FocusMove { 150 | Absolute = new AbsoluteFocus { 151 | Position = 0f, 152 | //Speed = 1f, 153 | //SpeedSpecified = true 154 | } 155 | }); 156 | 157 | await Task.Delay (500); 158 | } 159 | 160 | if (focus_opts.Relative != null) { 161 | Console.WriteLine ($"\tMoving Focus Relative"); 162 | 163 | await imaging.MoveAsync (vsource_token, new FocusMove { 164 | Relative = new RelativeFocus { 165 | Distance = 0.01f, 166 | //Speed = 1f, 167 | //SpeedSpecified = true 168 | } 169 | }); 170 | 171 | await Task.Delay (500); 172 | } 173 | 174 | if (focus_opts.Continuous != null) { 175 | Console.WriteLine ($"\tMoving Focus Continuous..."); 176 | 177 | await imaging.MoveAsync (vsource_token, new FocusMove { 178 | Continuous = new ContinuousFocus { 179 | Speed = 1f 180 | } 181 | }); 182 | 183 | await Task.Delay (500); 184 | 185 | await imaging.StopAsync (vsource_token); 186 | } 187 | 188 | var ptz_status = await ptz.GetStatusAsync (profile_token); 189 | 190 | Console.WriteLine ($"Position: [{ptz_status.Position.PanTilt.x}, {ptz_status.Position.PanTilt.y}, {ptz_status.Position.Zoom.x}]"); 191 | Console.WriteLine ($"Pan/Tilt Status: {ptz_status.MoveStatus.PanTilt} Zoom Status: {ptz_status.MoveStatus.Zoom}"); 192 | 193 | if (absolute_move) { 194 | Console.WriteLine ($"Absolute Move..."); 195 | 196 | await ptz.AbsoluteMoveAsync (profile_token, new PTZVector { 197 | PanTilt = new Vector2D { 198 | x = 0.5f, 199 | y = 0 200 | }, 201 | Zoom = new Vector1D { 202 | x = 0f 203 | } 204 | }, new PTZSpeed { 205 | PanTilt = new Vector2D { 206 | x = 1f, 207 | y = 1f 208 | }, 209 | Zoom = new Vector1D { 210 | x = 0f 211 | } 212 | }); 213 | 214 | await Task.Delay (3000); 215 | 216 | ptz_status = await ptz.GetStatusAsync (profile_token); 217 | 218 | Console.WriteLine ($"Position: [{ptz_status.Position.PanTilt.x}, {ptz_status.Position.PanTilt.y}, {ptz_status.Position.Zoom.x}]"); 219 | Console.WriteLine ($"Pan/Tilt Status: {ptz_status.MoveStatus.PanTilt} Zoom Status: {ptz_status.MoveStatus.Zoom}"); 220 | } 221 | 222 | if (relative_move) { 223 | Console.WriteLine ($"Relative Move..."); 224 | 225 | await ptz.RelativeMoveAsync (profile_token, new PTZVector { 226 | PanTilt = new Vector2D { 227 | x = 0.1f, 228 | y = 0.1f 229 | }, 230 | Zoom = new Vector1D { 231 | x = 0.1f 232 | } 233 | }, new PTZSpeed { 234 | PanTilt = new Vector2D { 235 | x = 0.1f, 236 | y = 0.1f 237 | }, 238 | Zoom = new Vector1D { 239 | x = 0.1f 240 | } 241 | }); 242 | 243 | await Task.Delay (3000); 244 | 245 | ptz_status = await ptz.GetStatusAsync (profile_token); 246 | 247 | Console.WriteLine ($"Position: [{ptz_status.Position.PanTilt.x}, {ptz_status.Position.PanTilt.y}, {ptz_status.Position.Zoom.x}]"); 248 | Console.WriteLine ($"Pan/Tilt Status: {ptz_status.MoveStatus.PanTilt} Zoom Status: {ptz_status.MoveStatus.Zoom}"); 249 | } 250 | 251 | if (continuous_move) { 252 | Console.WriteLine ($"Continuous Move..."); 253 | 254 | await ptz.ContinuousMoveAsync (profile_token, new PTZSpeed { 255 | PanTilt = new Vector2D { 256 | x = 0, 257 | y = -1 258 | }, 259 | Zoom = new Vector1D { 260 | x = 0 261 | } 262 | }, null); 263 | 264 | await Task.Delay (1500); 265 | await ptz.StopAsync (profile_token, true, true); 266 | 267 | ptz_status = await ptz.GetStatusAsync (profile_token); 268 | 269 | Console.WriteLine ($"Position: [{ptz_status.Position.PanTilt.x}, {ptz_status.Position.PanTilt.y}, {ptz_status.Position.Zoom.x}]"); 270 | Console.WriteLine ($"Pan/Tilt Status: {ptz_status.MoveStatus.PanTilt} Zoom Status: {ptz_status.MoveStatus.Zoom}"); 271 | } 272 | 273 | var presets = await ptz.GetPresetsAsync (profile_token); 274 | 275 | Console.WriteLine ("Presets count: " + presets.Preset.Length); 276 | 277 | foreach (var preset in presets.Preset) { 278 | var pan = preset.PTZPosition.PanTilt.x; 279 | var tilt = preset.PTZPosition.PanTilt.y; 280 | var zoom = preset.PTZPosition.Zoom.x; 281 | 282 | Console.WriteLine ($"Preset: {preset.token} Name: {preset.Name} Pan: {pan} Tilt: {tilt} Zoom: {zoom}"); 283 | 284 | await ptz.GotoPresetAsync (profile_token, preset.token, null); 285 | await Task.Delay (1500); 286 | //await ptz.RemovePresetAsync (profile_token, preset.token); 287 | } 288 | 289 | if (presets.Preset.Length == 0) { 290 | var new_preset = await ptz.SetPresetAsync (new SetPresetRequest { 291 | ProfileToken = profile_token, 292 | PresetName = "P1" 293 | }); 294 | 295 | Console.WriteLine ($"New Preset: {new_preset.PresetToken}"); 296 | } 297 | } 298 | } 299 | } 300 | -------------------------------------------------------------------------------- /wsdl/common.xsd: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | Unique identifier for a physical or logical resource. 10 | Tokens should be assigned such that they are unique within a device. Tokens must be at least unique within its class. 11 | Length up to 64 characters. 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | Pan/tilt coordinate space selector. The following options are defined:
    27 |
  • http://www.onvif.org/ver10/tptz/PanTiltSpaces/PositionGenericSpace
  • 28 |
  • http://www.onvif.org/ver10/tptz/PanTiltSpaces/TranslationGenericSpace
  • 29 |
  • http://www.onvif.org/ver10/tptz/PanTiltSpaces/VelocityGenericSpace
  • 30 |
  • http://www.onvif.org/ver10/tptz/PanTiltSpaces/GenericSpeedSpace
  • 31 |
32 |
33 |
34 |
35 |
36 | 37 | 38 | 39 | 40 | 41 | Zoom coordinate space selector. The following options are defined:
    42 |
  • http://www.onvif.org/ver10/tptz/ZoomSpaces/PositionGenericSpace
  • 43 |
  • http://www.onvif.org/ver10/tptz/ZoomSpaces/TranslationGenericSpace
  • 44 |
  • http://www.onvif.org/ver10/tptz/ZoomSpaces/VelocityGenericSpace
  • 45 |
  • http://www.onvif.org/ver10/tptz/ZoomSpaces/ZoomGenericSpeedSpace
  • 46 |
47 |
48 |
49 |
50 |
51 | 52 | 53 | 54 | 55 | Pan and tilt position. The x component corresponds to pan and the y component to tilt. 56 | 57 | 58 | 59 | 60 | 61 | A zoom position. 62 | 63 | 64 | 65 | 66 | 67 | 68 | 69 | 70 | 71 | 72 | Specifies the absolute position of the PTZ unit together with the Space references. The default absolute spaces of the corresponding PTZ configuration MUST be referenced within the Position element. 73 | 74 | 75 | 76 | 77 | 78 | 79 | Indicates if the Pan/Tilt/Zoom device unit is currently moving, idle or in an unknown state. 80 | 81 | 82 | 83 | 84 | 85 | 86 | States a current PTZ error. 87 | 88 | 89 | 90 | 91 | 92 | 93 | Specifies the UTC time when this status was generated. 94 | 95 | 96 | 97 | 98 | 99 | 100 | 101 | 102 | 103 | 104 | 105 | 106 | 107 | 108 | 109 | 110 | 111 | 112 | 113 | 114 | 115 | 116 | 117 | 118 | 119 | 120 | 121 | 122 | 123 | 124 | 125 | 126 | 127 | 128 | 129 | 130 | 131 | 132 | 133 | 134 | 135 | 136 | 137 | 138 | 139 | 140 | 141 | 142 | 143 | 144 | 145 | 146 | 147 | 148 | 149 | 150 | 151 | 152 | 153 | 154 | 155 | 156 | 157 | 158 | 159 | 160 | 161 | 162 | 163 | 164 | 165 | 166 | 167 | 168 | 169 | 170 | 171 | 172 | 173 | 174 | 175 | 176 | 177 | 178 | 179 | 180 | 181 | 182 | 183 | East west location as angle. 184 | 185 | 186 | 187 | 188 | North south location as angle. 189 | 190 | 191 | 192 | 193 | Hight in meters above sea level. 194 | 195 | 196 | 197 | 198 | 199 | 200 | 201 | 202 | 203 | 204 | 205 | Rotation around the x axis. 206 | 207 | 208 | 209 | 210 | Rotation around the y axis. 211 | 212 | 213 | 214 | 215 | Rotation around the z axis. 216 | 217 | 218 | 219 | 220 | 221 | 222 | 223 | 224 | 225 | 226 | 227 | East west location as angle. 228 | 229 | 230 | 231 | 232 | North south location as angle. 233 | 234 | 235 | 236 | 237 | Offset in meters from the sea level. 238 | 239 | 240 | 241 | 242 | 243 | 244 | 245 | 246 | 247 | 248 | 249 | Rotation around the y axis. 250 | 251 | 252 | 253 | 254 | Rotation around the z axis. 255 | 256 | 257 | 258 | 259 | Rotation around the x axis. 260 | 261 | 262 | 263 | 264 | 265 | 266 | 267 | 268 | 269 | 270 | 271 | 272 | 273 | 274 | 275 | 276 | Location on earth. 277 | 278 | 279 | Orientation relative to earth. 280 | 281 | 282 | Indoor location offset. 283 | 284 | 285 | Indoor orientation offset. 286 | 287 | 288 | 289 | Entity type the entry refers to, use a value from the tt:Entity enumeration. 290 | 291 | 292 | Optional entity token. 293 | 294 | 295 | If this value is true the entity cannot be deleted. 296 | 297 | 298 | Optional reference to the XAddr of another devices DeviceManagement service. 299 | 300 | 301 | If set the geo location is obtained internally. 302 | 303 | 304 | 305 |
306 | -------------------------------------------------------------------------------- /wsdl/imaging.wsdl: -------------------------------------------------------------------------------- 1 | 2 | 3 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | The capabilities for the imaging service is returned in the Capabilities element. 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | Indicates whether or not Image Stabilization feature is supported. 41 | 42 | 43 | 44 | 45 | Indicates whether or not Imaging Presets feature is supported. 46 | 47 | 48 | 49 | 50 | 51 | 52 | 53 | 54 | 55 | 56 | 57 | 58 | Reference token to the VideoSource for which the ImagingSettings. 59 | 60 | 61 | 62 | 63 | 64 | 65 | 66 | 67 | 68 | 69 | 70 | 71 | ImagingSettings for the VideoSource that was requested. 72 | 73 | 74 | 75 | 76 | 77 | 78 | 79 | 80 | 81 | 82 | 83 | 84 | 85 | 86 | 87 | 88 | 89 | 90 | 91 | 92 | 93 | 94 | 95 | 96 | 97 | 98 | Reference token to the VideoSource for which the imaging parameter options are requested. 99 | 100 | 101 | 102 | 103 | 104 | 105 | 106 | 107 | 108 | 109 | 110 | 111 | Valid ranges for the imaging parameters that are categorized as device specific. 112 | 113 | 114 | 115 | 116 | 117 | 118 | 119 | 120 | 121 | 122 | 123 | 124 | 125 | Reference to the VideoSource for the requested move (focus) operation. 126 | 127 | 128 | 129 | 130 | 131 | 132 | Content of the requested move (focus) operation. 133 | 134 | 135 | 136 | 137 | 138 | 139 | 140 | 141 | 142 | 143 | 144 | 145 | 146 | 147 | 148 | 149 | 150 | 151 | Reference token to the VideoSource for the requested move options. 152 | 153 | 154 | 155 | 156 | 157 | 158 | 159 | 160 | 161 | 162 | 163 | 164 | Valid ranges for the focus lens move options. 165 | 166 | 167 | 168 | 169 | 170 | 171 | 172 | 173 | 174 | 175 | 176 | 177 | 178 | Reference token to the VideoSource where the focus movement should be stopped. 179 | 180 | 181 | 182 | 183 | 184 | 185 | 186 | 187 | 188 | 189 | 190 | 191 | 192 | 193 | 194 | 195 | 196 | 197 | 198 | Reference token to the VideoSource where the imaging status should be requested. 199 | 200 | 201 | 202 | 203 | 204 | 205 | 206 | 207 | 208 | 209 | 210 | 211 | Requested imaging status. 212 | 213 | 214 | 215 | 216 | 217 | 218 | 219 | 220 | 221 | Describes standard Imaging Preset types, used to facilitate Multi-language support and client display. 222 | "Custom" Type shall be used when Imaging Preset Name does not match any of the types included in the standard classification. 223 | 224 | 225 | 226 | 227 | 228 | 229 | 230 | 231 | 232 | 233 | 234 | 235 | 236 | 237 | 238 | 239 | 240 | 241 | 242 | 243 | 244 | 245 | 246 | 247 | 248 | 249 | 250 | 251 | 252 | 253 | 254 | Type describing the Imaging Preset settings. 255 | 256 | 257 | 258 | 259 | Human readable name of the Imaging Preset. 260 | 261 | 262 | 263 | 264 | 265 | Unique identifier of this Imaging Preset. 266 | 267 | 268 | 269 | 270 | Indicates Imaging Preset Type. Use timg:ImagingPresetType. 271 | Used for multi-language support and display. 272 | 273 | 274 | 275 | 276 | 277 | 278 | 279 | 280 | 281 | 282 | 283 | A reference to the VideoSource where the operation should take place. 284 | 285 | 286 | 287 | 288 | 289 | 290 | 291 | 292 | 293 | 294 | 295 | 296 | List of Imaging Presets which are available for the requested VideoSource. 297 | 298 | 299 | 300 | 301 | 302 | 303 | 304 | 305 | 306 | 307 | 308 | 309 | Reference token to the VideoSource where the current Imaging Preset should be requested. 310 | 311 | 312 | 313 | 314 | 315 | 316 | 317 | 318 | 319 | 320 | Current Imaging Preset in use for the specified Video Source. 321 | 322 | 323 | 324 | 325 | 326 | 327 | 328 | 329 | 330 | 331 | 332 | 333 | Reference token to the VideoSource to which the specified Imaging Preset should be applied. 334 | 335 | 336 | 337 | 338 | 339 | Reference token to the Imaging Preset to be applied to the specified Video Source. 340 | 341 | 342 | 343 | 344 | 345 | 346 | 347 | 348 | 349 | 350 | 351 | 352 | 353 | 354 | 355 | 356 | 357 | 358 | 359 | 360 | 361 | 362 | 363 | 364 | 365 | 366 | 367 | 368 | 369 | 370 | 371 | 372 | 373 | 374 | 375 | 376 | 377 | 378 | 379 | 380 | 381 | 382 | 383 | 384 | 385 | 386 | 387 | 388 | 389 | 390 | 391 | 392 | 393 | 394 | 395 | 396 | 397 | 398 | 399 | 400 | 401 | 402 | 403 | 404 | 405 | 406 | 407 | 408 | 409 | 410 | 411 | 412 | 413 | 414 | 415 | 416 | 417 | 418 | 419 | 420 | 421 | Returns the capabilities of the imaging service. The result is returned in a typed answer. 422 | 423 | 424 | 425 | 426 | Get the ImagingConfiguration for the requested VideoSource. 427 | 428 | 429 | 430 | 431 | Set the ImagingConfiguration for the requested VideoSource. 432 | 433 | 434 | 435 | 436 | This operation gets the valid ranges for the imaging parameters that have device specific ranges. 437 | This command is mandatory for all device implementing the imaging service. The command returns all supported parameters and their ranges 438 | such that these can be applied to the SetImagingSettings command.
439 | For read-only parameters which cannot be modified via the SetImagingSettings command only a single option or identical Min and Max values 440 | is provided.
441 | 442 | 443 |
444 | 445 | The Move command moves the focus lens in an absolute, a relative or in a continuous manner from its current position. 446 | The speed argument is optional for absolute and relative control, but required for continuous. If no speed argument is used, the default speed is used. 447 | Focus adjustments through this operation will turn off the autofocus. A device with support for remote focus control should support absolute, 448 | relative or continuous control through the Move operation. The supported MoveOpions are signalled via the GetMoveOptions command. 449 | At least one focus control capability is required for this operation to be functional.
450 | The move operation contains the following commands:
451 | Absolute – Requires position parameter and optionally takes a speed argument. A unitless type is used by default for focus positioning and speed. Optionally, if supported, the position may be requested in m-1 units.
452 | Relative – Requires distance parameter and optionally takes a speed argument. Negative distance means negative direction. 453 | Continuous – Requires a speed argument. Negative speed argument means negative direction. 454 |
455 | 456 | 457 |
458 | 459 | Imaging move operation options supported for the Video source. 460 | 461 | 462 | 463 | 464 | The Stop command stops all ongoing focus movements of the lense. A device with support for remote focus control as signalled via 465 | the GetMoveOptions supports this command.
The operation will not affect ongoing autofocus operation.
466 | 467 | 468 |
469 | 470 | Via this command the current status of the Move operation can be requested. Supported for this command is available if the support for the Move operation is signalled via GetMoveOptions. 471 | 472 | 473 | 474 | 475 | Via this command the list of available Imaging Presets can be requested. 476 | 477 | 478 | 479 | 480 | Via this command the last Imaging Preset applied can be requested. 481 | If the camera configuration does not match any of the existing Imaging Presets, the output of GetCurrentPreset shall be Empty. 482 | GetCurrentPreset shall return 0 if Imaging Presets are not supported by the Video Source. 483 | 484 | 485 | 486 | 487 | The SetCurrentPreset command shall request a given Imaging Preset to be applied to the specified Video Source. 488 | SetCurrentPreset shall only be available for Video Sources with Imaging Presets Capability. 489 | Imaging Presets are defined by the Manufacturer, and offered as a tool to simplify Imaging Settings adjustments for specific scene content. 490 | When the new Imaging Preset is applied by SetCurrentPreset, the Device shall adjust the Video Source settings to match those defined by the specified Imaging Preset. 491 | 492 | 493 | 494 |
495 | 496 | 497 | 498 | 499 | 500 | 501 | 502 | 503 | 504 | 505 | 506 | 507 | 508 | 509 | 510 | 511 | 512 | 513 | 514 | 515 | 516 | 517 | 518 | 519 | 520 | 521 | 522 | 523 | 524 | 525 | 526 | 527 | 528 | 529 | 530 | 531 | 532 | 533 | 534 | 535 | 536 | 537 | 538 | 539 | 540 | 541 | 542 | 543 | 544 | 545 | 546 | 547 | 548 | 549 | 550 | 551 | 552 | 553 | 554 | 555 | 556 | 557 | 558 | 559 | 560 | 561 | 562 | 563 | 564 | 565 | 566 | 567 | 568 | 569 | 570 | 571 | 572 | 573 | 574 | 575 | 576 | 577 | 578 | 579 | 580 | 581 | 582 | 583 | 584 | 585 | 586 | 587 | 588 | 589 | 590 | 591 | 592 | 593 | 594 | 595 | 596 | 597 |
598 | --------------------------------------------------------------------------------