Fix botched merge in ONVIF.PM
This commit is contained in:
parent
8bebb2b890
commit
7938952a90
|
@ -185,16 +185,12 @@ sub discover {
|
|||
push @responses, $response;
|
||||
};
|
||||
|
||||
## try both soap versions
|
||||
|
||||
my $uuid_gen = Data::UUID->new();
|
||||
|
||||
if ( ( ! $soap_version ) or ( $soap_version eq '1.1' ) ) {
|
||||
my %services;
|
||||
|
||||
if ( $verbose ) {
|
||||
print "Probing for SOAP 1.1\n";
|
||||
}
|
||||
print "Probing for SOAP 1.1\n" if $verbose;
|
||||
my $svc_discover = WSDiscovery10::Interfaces::WSDiscovery::WSDiscoveryPort->new({
|
||||
# no_dispatch => '1',
|
||||
});
|
||||
|
@ -226,9 +222,7 @@ sub discover {
|
|||
|
||||
if ( ( ! $soap_version ) or ( $soap_version eq '1.2' ) ) {
|
||||
my %services;
|
||||
if ( $verbose ) {
|
||||
print "Probing for SOAP 1.2\n";
|
||||
}
|
||||
print "Probing for SOAP 1.2\n" if $verbose;
|
||||
my $svc_discover = WSDiscovery10::Interfaces::WSDiscovery::WSDiscoveryPort->new({
|
||||
# no_dispatch => '1',
|
||||
});
|
||||
|
@ -281,19 +275,16 @@ sub profiles {
|
|||
}
|
||||
my @profiles;
|
||||
|
||||
|
||||
foreach my $profile ( @{ $result->get_Profiles() } ) {
|
||||
|
||||
my $token = $profile->attr()->get_token() ;
|
||||
my $Name = $profile->get_Name();
|
||||
|
||||
my $VideoEncoderConfiguration = $profile->get_VideoEncoderConfiguration();
|
||||
if ( ! $VideoEncoderConfiguration ) {
|
||||
print "Unknown profile $token $Name.\n";
|
||||
print "No VideoEncoderConfiguration in profile $token $Name.\n";
|
||||
next;
|
||||
}
|
||||
|
||||
my $token = $profile->attr()->get_token() ;
|
||||
my $Name = $profile->get_Name();
|
||||
|
||||
# Specification gives conflicting values for unicast stream types, try both.
|
||||
# http://www.onvif.org/onvif/ver10/media/wsdl/media.wsdl#op.GetStreamUri
|
||||
foreach my $streamtype ( 'RTP_unicast', 'RTP-Unicast', 'RTP-multicast', 'RTP-Multicast' ) {
|
||||
|
@ -315,15 +306,15 @@ sub profiles {
|
|||
my $Width = $Resolution ? $Resolution->get_Width() : 0;
|
||||
my $Height = $Resolution ? $Resolution->get_Height() : 0;
|
||||
|
||||
push @profiles, {
|
||||
print join(', ', $token,
|
||||
push @profiles, [
|
||||
$token,
|
||||
$Name,
|
||||
$VideoEncoderConfiguration->get_Encoding(),
|
||||
$Width,
|
||||
$Height,
|
||||
$VideoEncoderConfiguration->get_RateControl()->get_FrameRateLimit(),
|
||||
$Uri,
|
||||
) . "\n";
|
||||
];
|
||||
} # end foreach streamtype
|
||||
|
||||
} # end foreach profile
|
||||
|
|
Loading…
Reference in New Issue