-
Notifications
You must be signed in to change notification settings - Fork 103
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Media2 spec update for audio clip management feature #448
base: development
Are you sure you want to change the base?
Conversation
Media2 spec doc and wsdl update for Audio Clip Management feature. Action Engine spec doc updated with audio clip play command action example.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
One very general question: why is this functionality part of the media service and doesn't define its own service? Rationale should be the relationship to the media profiles.
Currently ONVIF Media2 Service have the APIs for the following features: Configuration APIs for Video Source, Video Encoder, Audio Source, Audio Encoder, Audio Output, Audio Decoder, Metadta, Analytics Video Source Mode APIs - associated with video source OSD APIs - associated with video source Privacy Mask APIs - associated with video source Media Profile management APIs - associated with media profile Streaming related APIs - GetStreamUri, SetSynchronizationPoint, StartMulticast, Stopmulticast ->associated with media profile Snapshot related APIs - GetSnapshotUri associated with media profile WebRTC Configuration APIs ->associated with media profile. Audio Clips are associated with audio output i.e device speaker and this is the reason for defining them in ONVIF Media2 service. |
Configuration Prefix removed from Audio Clip Management APIs.
• AudioOutputToken parameter made as mandatory as part of AddAudioClip, SetAudioClip APIs. • PlayStatus read only optional parameter added in GetAudioClips to know the clip is currently playing or not. • AudioOutputToken parameter made as optional in PlayAudioClip API. • RepeatCycles optional parameter is added in PlayAudioClip API.
<varlistentry> | ||
<term>request</term> | ||
<listitem> | ||
<para role="param">Token - [tt:ReferenceToken]</para> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
For stop operation, token optional to be able to stop whatever active.
1. Multiple audio outputs are considered in AddAudioClip/SetAudioClip/PlayAudioClip APIs. 2. Token is separate out from Audio Clip Configuration structure. 3. PlayStatus parameter is added only in GetAudioClips response. 4. RepeatInterval optional parameter added in Audio clip Configuration to provide time interval b/w the audio clips when repeated. 5. HTTP specific error codes are defined in spec document when audio clip upload fails. 6. Gain parameter name is changed to AudioOuputLevel in Audio Clip Configuration structure.
SupportedAudioClipFormat enumerations are defined.
…nges. 1. Optional Token added in AddAudioClip API request. 2. Audio Clip Capabilities made as optional in Capabilities2 element. 3.Editorial changes in spec doc and wsdl.
doc/Media2.xml
Outdated
@@ -2183,7 +2183,7 @@ | |||
<para>AudioOutputToken [tt:ReferenceToken] optional, unbounded – Optional token list of physical audio outputs. If no AudioOutputToken is provided, the device should play the audio clip through all physical audio outputs.</para> | |||
</listitem> | |||
<listitem> | |||
<para>Type [xs:string] - Format of the audio clip. For definitions see tr2:SupportedAudioClipFormat parameter.</para> | |||
<para>Type [xs:string] - Format of the audio clip. Supported audio Clip formats are WAV, MP3, OGG-Opus, OGG-Vorbis, OGG-Flac, OGG-Speex.</para> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should we individually list these strings OR refer to the IANA like we did for Audio/Video Encoding?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Preferred to list individual strings for this feature.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should't we use IANA mime types or names for the formats if possible?
E.g. audio/ogg;codecs=opus, audio/ogg;codecs=flac etc?
https://www.rfc-editor.org/rfc/rfc7845.html#section-9
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, I will update PR with IANA mime types as below
RFC: https://datatracker.ietf.org/doc/html/rfc5334
audio/ogg;codecs=speex
audio/ogg;codecs=vorbis
audio/ogg;codecs=flac
RFC: https://datatracker.ietf.org/doc/html/rfc7845
audio/ogg;codecs=opus
RFC: https://tools.ietf.org/html/rfc3003
audio/mpeg
RFC: https://tools.ietf.org/html/rfc2361
audio/wav;codecs=g711-ulaw
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@venki5685 a few small minor typo's that I raised for your review. Otherwise I am happy with the changes. I see @bsriramprasad has made a further suggestion on the codecs and will await your response before approving your PR.
editorial changes review comments addressed
editorial changes review comments addressed
But Audio Output is a part of DeviceIO, not of Media2 service. 11/16/2024 Video Source Mode/OSD/Privacy Mask APIs associated with video source which are defined in Media Service not defined in Device IO Service. we do not need to media profile to apply osd, privacy mask to the video source. Similar way audio clip apis are defined in media service play them on device physical audio outputs which does not need media profile to play it. |
1. Audio Clip start and stop event schema is defined. 2.PlayStatus is removed form GetAudioClips API response. 3.GetPlayingAudioClips API is defined to get the list of audio clips currently playing in the device. Feedback from Axis is incorporated.
Audio Clip event schema updated as per feedback from VEWG telco on Dec 5th 2024.
1. SupportedAudioClipFormat data type is changed to tt:StringAttrList from tt:StringList. 2.PlayAudioClipError code is added in PlayAudioClip API which is used when user tries to play the audio clip when clip is disabled. 3. Audio clip event topic change to tns1:Media/AudioClip/State, Token parameter is added in Audio Clip event to uniquely identify the audio clip state event.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@venki5685 re-reviewed PR I am ok with the latest updates. I have noted the lads points regarding the IANA codecs but I see you want to just list them.
Media2 spec doc and wsdl update for Audio Clip Management feature. Action Engine spec doc updated with audio clip play command action example.