Reference time stamp for SVC. (#2185)
SVC has only one stream and when calculating reference time stamp, irrespective of reference layer, reference time stamp will be the same as the given time stamp as there is only one stream and no offset. TODO: Need better all around SVC handling.
This commit is contained in:
@@ -651,6 +651,12 @@ func (s *StreamTrackerManager) GetReferenceLayerRTPTimestamp(ts uint32, layer in
|
||||
return 0, fmt.Errorf("invalid layer, target: %d, reference: %d", layer, referenceLayer)
|
||||
}
|
||||
|
||||
// SVC-TODO: better SVC detection
|
||||
if s.isSVC {
|
||||
// there is only one stream in SVC
|
||||
return ts, nil
|
||||
}
|
||||
|
||||
if layer != referenceLayer && s.layerOffsets[referenceLayer][layer] == 0 {
|
||||
return 0, fmt.Errorf("offset unavailable, target: %d, reference: %d", layer, referenceLayer)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user