Commit graph

87 commits

Author SHA1 Message Date
Danil Chapovalov
350531e2a3 Revert "Move class VideoCodec from common_types.h to its own api header file."
This reverts commit efc71e565e.

Reason for revert: probably breaks downstream test

Original change's description:
> Move class VideoCodec from common_types.h to its own api header file.
> 
> Bug: webrtc:7660
> Change-Id: I91f19bfc2565461328f30081f8383e136419aefb
> Reviewed-on: https://webrtc-review.googlesource.com/79881
> Commit-Queue: Niels Moller <nisse@webrtc.org>
> Reviewed-by: Rasmus Brandt <brandtr@webrtc.org>
> Reviewed-by: Danil Chapovalov <danilchap@webrtc.org>
> Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
> Cr-Commit-Position: refs/heads/master@{#23544}

TBR=danilchap@webrtc.org,brandtr@webrtc.org,kwiberg@webrtc.org,nisse@webrtc.org

Change-Id: Id8bd37c79c2f8d09a4d88368765230103f1db2c8
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: webrtc:7660
Reviewed-on: https://webrtc-review.googlesource.com/82101
Reviewed-by: Danil Chapovalov <danilchap@webrtc.org>
Commit-Queue: Danil Chapovalov <danilchap@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#23547}
2018-06-08 11:04:23 +00:00
Niels Möller
efc71e565e Move class VideoCodec from common_types.h to its own api header file.
Bug: webrtc:7660
Change-Id: I91f19bfc2565461328f30081f8383e136419aefb
Reviewed-on: https://webrtc-review.googlesource.com/79881
Commit-Queue: Niels Moller <nisse@webrtc.org>
Reviewed-by: Rasmus Brandt <brandtr@webrtc.org>
Reviewed-by: Danil Chapovalov <danilchap@webrtc.org>
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#23544}
2018-06-08 07:55:04 +00:00
Niels Möller
65ec0fc81e Delete unneeded includes of basictypes.h.
This is a kitchen-sink header, some pieces should be moved to
byteorder.h, the rest likely deleted.

Delete most includes of basictypes.h. In leaf headers,
include stddef.h and stdint.h explicitly where needed.

Bug: webrtc:6853
Change-Id: Ibc809936a8f94d418e4eb650da1e89c1b9142073
Reviewed-on: https://webrtc-review.googlesource.com/77721
Commit-Queue: Niels Moller <nisse@webrtc.org>
Reviewed-by: Fredrik Solenberg <solenberg@webrtc.org>
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#23333}
2018-05-21 19:35:08 +00:00
Sergey Silkin
be71a1ee08 Replace VP9 screen sharing.
- Remove referencing control from encoder wrapper. Use fixed temporal
prediction structure.
- Remove flexible mode from encoder wrapper. It only worked with
referencing control which this CL removes.
- Remove external framerate/bitrate controller. Keep codec's internal
frame dropping enabled at screen sharing.
- Use GetSvcConfig() to configure layering.

Bug: webrtc:9261
Change-Id: I355baa6aab7b98ac5028b3851d1f8ccc82a308e0
Reviewed-on: https://webrtc-review.googlesource.com/76801
Reviewed-by: Stefan Holmer <stefan@webrtc.org>
Reviewed-by: Erik Språng <sprang@webrtc.org>
Commit-Queue: Sergey Silkin <ssilkin@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#23311}
2018-05-18 15:11:46 +00:00
Sergey Silkin
dfe8ca0d43 Layering and rate allocation for VP9 screen sharing.
- Two quality layers (same resolution, different bitrate).
- Max bitrate of low layer is limited to 200kbps. The choice of the
limit is driven by VP8 screen sharing which limits max bitrate of low
temporal layer to 200kbps. Using the same value for VP9 guarantees
that there will be no regressions for participants with limited
bandwidth.
- Max bitrate of high layer is limited to 500kbps. According to test
results this value is enough to get up to +5dB higher PSNR than VP8
SS provides on 1.2Mbps (max total bitrate for VP8 SS) link.
- Max total sent bitrate is limited to 700kbps. It is 500kbps lower
than that in VP8 SS (1200kbps).

Bug: webrtc:9261
Change-Id: I7919cc3933064664567c39e380a44cad0c65f1e8
Reviewed-on: https://webrtc-review.googlesource.com/76380
Commit-Queue: Sergey Silkin <ssilkin@webrtc.org>
Reviewed-by: Erik Språng <sprang@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#23226}
2018-05-15 07:06:10 +00:00
Niels Möller
f133856dfa Delete nack_enabled flag in encoder configuration.
This is a followup to cl https://webrtc-review.googlesource.com/71380,
which reworked the way encoder resilience is done, and made the
nack_enabled flag unused.

Bug: webrtc:8830
Change-Id: I3de2508c97bc71e01c8f2232d16cd1f33e57fe4a
Reviewed-on: https://webrtc-review.googlesource.com/69986
Reviewed-by: Rasmus Brandt <brandtr@webrtc.org>
Reviewed-by: Stefan Holmer <stefan@webrtc.org>
Commit-Queue: Niels Moller <nisse@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#23080}
2018-05-02 16:05:27 +00:00
Niels Möller
65fb4049c1 Don't expose resilience mode in VP8 and VP9 configuration.
This deletes the resilienceOn flag in VideoCodecVP8 and VideoCodecVP9.
Instead, the implementations of VP8 and VP9 set resilience mode
internally, based on the configuration of temporal and spatial layers.

The nack_enabled argument to VideoCodecInitializer::SetupCodec becomes
unused with this cl. In a followup, it will be deleted, together with
the corresponding argument to VideoStreamEncoder methods.

An applications which really wants to configure resilience differently
can do that by injecting an EncoderFactory with encoders behaving
as desired.

Bug: webrtc:8830
Change-Id: I9990faf07d3e95c0fb4a56fcc9a56c2005b4a6fa
Reviewed-on: https://webrtc-review.googlesource.com/71380
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Reviewed-by: Sergey Silkin <ssilkin@webrtc.org>
Reviewed-by: Rasmus Brandt <brandtr@webrtc.org>
Commit-Queue: Niels Moller <nisse@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#23025}
2018-04-25 13:54:33 +00:00
Niels Möller
e8a9c45cc1 Delete enum VP8ResilienceMode.
We only support on (formely kResilientStream) and off (formely
kResilienceOff). The third mode, kResilientFrames, was not
implemented.

Bug: None
Change-Id: Ida82f6a33eda9d943ea70bc8ae4e6bddb720b0e8
Reviewed-on: https://webrtc-review.googlesource.com/71481
Reviewed-by: Åsa Persson <asapersson@webrtc.org>
Reviewed-by: Erik Språng <sprang@webrtc.org>
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Commit-Queue: Niels Moller <nisse@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#22984}
2018-04-23 15:10:26 +00:00
Sergey Silkin
fafeac3517 Use codec's bitrate limits if SVC is off.
Adding SVC rate allocator and layering configurator caused regression
for VP9 non-SVC senders. SVC bitrate limits, which were supposed to
be used only when spatial layering is enabled, are applied when
encoding single spatial layer. E.g. for VP9 360p sender maximum bitrate
is limited to 500kbps.

This fixes the regression. If sender is configured to send VP9 single
layer then codec's bitrate limits are applied to this layer.

Bug: webrtc:9151, chromium:831093
Change-Id: Ia1ae4087155ad7917a3443304a21532f1e68ea65
Reviewed-on: https://webrtc-review.googlesource.com/69813
Commit-Queue: Sergey Silkin <ssilkin@webrtc.org>
Reviewed-by: Michael Horowitz <mhoro@webrtc.org>
Reviewed-by: Rasmus Brandt <brandtr@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#22862}
2018-04-13 16:11:18 +00:00
Danil Chapovalov
4da18e89bd compare Optional<unsigned> only to unsigned integers
more standard optional<T> inlines compares instead of converting second argument to T.
that leads to warnings about comparing unsigned to signed integers.

Bug: webrtc:9078
Change-Id: I43cc729d3b85d789b0c394064dc7e11dc27a37aa
Reviewed-on: https://webrtc-review.googlesource.com/66782
Commit-Queue: Danil Chapovalov <danilchap@webrtc.org>
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#22779}
2018-04-07 10:07:47 +00:00
Niels Möller
259a497632 Reland "Reland "Move rtp-specific config out of EncoderSettings.""
This reverts commit 6c2c13af06.

Reason for revert: Intend to investigate and fix perf problems.

Original change's description:
> Revert "Reland "Move rtp-specific config out of EncoderSettings.""
> 
> This reverts commit 04dd176862.
> 
> Reason for revert: Regression in ramp up perf tests.
> 
> Original change's description:
> > Reland "Move rtp-specific config out of EncoderSettings."
> >
> > This is a reland of bc900cb1d1
> >
> > Original change's description:
> > > Move rtp-specific config out of EncoderSettings.
> > >
> > > In VideoSendStream::Config, move payload_name and payload_type from
> > > EncoderSettings to Rtp.
> > >
> > > EncoderSettings now contains configuration for VideoStreamEncoder only,
> > > and should perhaps be renamed in a follow up cl. It's no longer
> > > passed as an argument to VideoCodecInitializer::SetupCodec.
> > >
> > > The latter then needs a different way to know the codec type,
> > > which is provided by a new codec_type member in VideoEncoderConfig.
> > >
> > > Bug: webrtc:8830
> > > Change-Id: Ifcc691aef1ee6a95e43c0452c5e630d92a511cd6
> > > Reviewed-on: https://webrtc-review.googlesource.com/62062
> > > Commit-Queue: Niels Moller <nisse@webrtc.org>
> > > Reviewed-by: Magnus Jedvert <magjed@webrtc.org>
> > > Reviewed-by: Stefan Holmer <stefan@webrtc.org>
> > > Reviewed-by: Rasmus Brandt <brandtr@webrtc.org>
> > > Cr-Commit-Position: refs/heads/master@{#22532}
> >
> > Bug: webrtc:8830
> > Change-Id: If88ef7d57cdaa4fae3c7b2a97ea5a6e1b833e019
> > Reviewed-on: https://webrtc-review.googlesource.com/63721
> > Reviewed-by: Rasmus Brandt <brandtr@webrtc.org>
> > Reviewed-by: Stefan Holmer <stefan@webrtc.org>
> > Commit-Queue: Niels Moller <nisse@webrtc.org>
> > Cr-Commit-Position: refs/heads/master@{#22595}
> 
> TBR=brandtr@webrtc.org,magjed@webrtc.org,nisse@webrtc.org,stefan@webrtc.org
> 
> Bug: webrtc:8830,chromium:827080
> Change-Id: Iaaf146de91ec5c0d741b8efdf143f7e173084fef
> Reviewed-on: https://webrtc-review.googlesource.com/65520
> Commit-Queue: Niels Moller <nisse@webrtc.org>
> Reviewed-by: Niels Moller <nisse@webrtc.org>
> Cr-Commit-Position: refs/heads/master@{#22677}

TBR=brandtr@webrtc.org,magjed@webrtc.org,nisse@webrtc.org,stefan@webrtc.org

# Not skipping CQ checks because original CL landed > 1 day ago.

Bug: webrtc:8830, chromium:827080
Change-Id: I9b62987bf5daced90dfeb3ebb6739c80117c487f
Reviewed-on: https://webrtc-review.googlesource.com/66862
Commit-Queue: Niels Moller <nisse@webrtc.org>
Reviewed-by: Niels Moller <nisse@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#22751}
2018-04-05 14:30:09 +00:00
Niels Möller
6c2c13af06 Revert "Reland "Move rtp-specific config out of EncoderSettings.""
This reverts commit 04dd176862.

Reason for revert: Regression in ramp up perf tests.

Original change's description:
> Reland "Move rtp-specific config out of EncoderSettings."
>
> This is a reland of bc900cb1d1
>
> Original change's description:
> > Move rtp-specific config out of EncoderSettings.
> >
> > In VideoSendStream::Config, move payload_name and payload_type from
> > EncoderSettings to Rtp.
> >
> > EncoderSettings now contains configuration for VideoStreamEncoder only,
> > and should perhaps be renamed in a follow up cl. It's no longer
> > passed as an argument to VideoCodecInitializer::SetupCodec.
> >
> > The latter then needs a different way to know the codec type,
> > which is provided by a new codec_type member in VideoEncoderConfig.
> >
> > Bug: webrtc:8830
> > Change-Id: Ifcc691aef1ee6a95e43c0452c5e630d92a511cd6
> > Reviewed-on: https://webrtc-review.googlesource.com/62062
> > Commit-Queue: Niels Moller <nisse@webrtc.org>
> > Reviewed-by: Magnus Jedvert <magjed@webrtc.org>
> > Reviewed-by: Stefan Holmer <stefan@webrtc.org>
> > Reviewed-by: Rasmus Brandt <brandtr@webrtc.org>
> > Cr-Commit-Position: refs/heads/master@{#22532}
>
> Bug: webrtc:8830
> Change-Id: If88ef7d57cdaa4fae3c7b2a97ea5a6e1b833e019
> Reviewed-on: https://webrtc-review.googlesource.com/63721
> Reviewed-by: Rasmus Brandt <brandtr@webrtc.org>
> Reviewed-by: Stefan Holmer <stefan@webrtc.org>
> Commit-Queue: Niels Moller <nisse@webrtc.org>
> Cr-Commit-Position: refs/heads/master@{#22595}

TBR=brandtr@webrtc.org,magjed@webrtc.org,nisse@webrtc.org,stefan@webrtc.org

Bug: webrtc:8830,chromium:827080
Change-Id: Iaaf146de91ec5c0d741b8efdf143f7e173084fef
Reviewed-on: https://webrtc-review.googlesource.com/65520
Commit-Queue: Niels Moller <nisse@webrtc.org>
Reviewed-by: Niels Moller <nisse@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#22677}
2018-03-29 11:45:18 +00:00
Sergey Silkin
86684960b3 Adding layering configurator and rate allocator for VP9 SVC.
The configurator decides number of spatial layers, their resolution
and bitrate thresholds based on given input resolution and maximum
number of spatial layers.

The allocator distributes available bitrate across spatial and
temporal layers. If there is not enough bitrate to provide acceptable
quality for all spatial layers allocator disables enhancement layers
one by one until the condition is met or number of layers is reduced
to one.

VP9 SVC related unit tests have been updated. Input resolution and
bitrate in these tests have been increased to the level enough to
provide desirable number of spatial layers.

Bug: webrtc:8518
Change-Id: I9df790920227c7f7dd4d42a50a856c22f0f4389b
Reviewed-on: https://webrtc-review.googlesource.com/60340
Commit-Queue: Sergey Silkin <ssilkin@webrtc.org>
Reviewed-by: Erik Språng <sprang@webrtc.org>
Reviewed-by: Stefan Holmer <stefan@webrtc.org>
Reviewed-by: Rasmus Brandt <brandtr@webrtc.org>
Reviewed-by: Michael Horowitz <mhoro@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#22672}
2018-03-29 10:16:47 +00:00
Niels Möller
04dd176862 Reland "Move rtp-specific config out of EncoderSettings."
This is a reland of bc900cb1d1

Original change's description:
> Move rtp-specific config out of EncoderSettings.
> 
> In VideoSendStream::Config, move payload_name and payload_type from
> EncoderSettings to Rtp.
> 
> EncoderSettings now contains configuration for VideoStreamEncoder only,
> and should perhaps be renamed in a follow up cl. It's no longer
> passed as an argument to VideoCodecInitializer::SetupCodec.
> 
> The latter then needs a different way to know the codec type,
> which is provided by a new codec_type member in VideoEncoderConfig.
> 
> Bug: webrtc:8830
> Change-Id: Ifcc691aef1ee6a95e43c0452c5e630d92a511cd6
> Reviewed-on: https://webrtc-review.googlesource.com/62062
> Commit-Queue: Niels Moller <nisse@webrtc.org>
> Reviewed-by: Magnus Jedvert <magjed@webrtc.org>
> Reviewed-by: Stefan Holmer <stefan@webrtc.org>
> Reviewed-by: Rasmus Brandt <brandtr@webrtc.org>
> Cr-Commit-Position: refs/heads/master@{#22532}

Bug: webrtc:8830
Change-Id: If88ef7d57cdaa4fae3c7b2a97ea5a6e1b833e019
Reviewed-on: https://webrtc-review.googlesource.com/63721
Reviewed-by: Rasmus Brandt <brandtr@webrtc.org>
Reviewed-by: Stefan Holmer <stefan@webrtc.org>
Commit-Queue: Niels Moller <nisse@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#22595}
2018-03-26 08:39:39 +00:00
Niels Möller
24a842a15c Add field VideoEncoderConfig::codec_type.
First step of the transition needed to reland cl
https://webrtc-review.googlesource.com/62062, and move payload_name
and payload_type out of VideoSendStream::Config::EncoderSettings.

If the new field is set to something different than kVideoCodecUnkown,
payload_name from EncoderSettings is ignored.

Bug: webrtc:8830
Change-Id: I515a91f8291cda79017332102cc6a10736d8a648
Reviewed-on: https://webrtc-review.googlesource.com/64001
Reviewed-by: Rasmus Brandt <brandtr@webrtc.org>
Commit-Queue: Niels Moller <nisse@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#22555}
2018-03-22 09:39:13 +00:00
Niels Moller
92be1caf4f Revert "Move rtp-specific config out of EncoderSettings."
This reverts commit bc900cb1d1.

Reason for revert: Broke downstream projects.

Original change's description:
> Move rtp-specific config out of EncoderSettings.
> 
> In VideoSendStream::Config, move payload_name and payload_type from
> EncoderSettings to Rtp.
> 
> EncoderSettings now contains configuration for VideoStreamEncoder only,
> and should perhaps be renamed in a follow up cl. It's no longer
> passed as an argument to VideoCodecInitializer::SetupCodec.
> 
> The latter then needs a different way to know the codec type,
> which is provided by a new codec_type member in VideoEncoderConfig.
> 
> Bug: webrtc:8830
> Change-Id: Ifcc691aef1ee6a95e43c0452c5e630d92a511cd6
> Reviewed-on: https://webrtc-review.googlesource.com/62062
> Commit-Queue: Niels Moller <nisse@webrtc.org>
> Reviewed-by: Magnus Jedvert <magjed@webrtc.org>
> Reviewed-by: Stefan Holmer <stefan@webrtc.org>
> Reviewed-by: Rasmus Brandt <brandtr@webrtc.org>
> Cr-Commit-Position: refs/heads/master@{#22532}

TBR=brandtr@webrtc.org,magjed@webrtc.org,nisse@webrtc.org,stefan@webrtc.org

Change-Id: I01f06c1fcf21eb2cd40dca7d4f268614200ee490
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: webrtc:8830
Reviewed-on: https://webrtc-review.googlesource.com/63720
Reviewed-by: Niels Moller <nisse@webrtc.org>
Commit-Queue: Niels Moller <nisse@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#22537}
2018-03-21 13:53:49 +00:00
Niels Möller
bc900cb1d1 Move rtp-specific config out of EncoderSettings.
In VideoSendStream::Config, move payload_name and payload_type from
EncoderSettings to Rtp.

EncoderSettings now contains configuration for VideoStreamEncoder only,
and should perhaps be renamed in a follow up cl. It's no longer
passed as an argument to VideoCodecInitializer::SetupCodec.

The latter then needs a different way to know the codec type,
which is provided by a new codec_type member in VideoEncoderConfig.

Bug: webrtc:8830
Change-Id: Ifcc691aef1ee6a95e43c0452c5e630d92a511cd6
Reviewed-on: https://webrtc-review.googlesource.com/62062
Commit-Queue: Niels Moller <nisse@webrtc.org>
Reviewed-by: Magnus Jedvert <magjed@webrtc.org>
Reviewed-by: Stefan Holmer <stefan@webrtc.org>
Reviewed-by: Rasmus Brandt <brandtr@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#22532}
2018-03-21 12:55:08 +00:00
Erik Språng
82fad3d513 Remove TemporalLayersFactory and associated classes
As the rate allocation has been moved into entirely into
SimulcastRateAllocator, and the listeners are thus no longer needed,
this class doesn't fill any other purpose than to determine if
ScreenshareLayers or TemporalLayers should be created for a given
simulcast stream. This can however be done just from looking at the
VideoCodec instance, so changing this into a static factory method.

Due to dependencies from upstream projects, keep the class name and
field in VideoCodec around for now.

Bug: webrtc:9012
Change-Id: I028fe6b2a19e0d16b35956cc2df01dcf5bfa7979
Reviewed-on: https://webrtc-review.googlesource.com/63264
Commit-Queue: Erik Språng <sprang@webrtc.org>
Reviewed-by: Ilya Nikolaevskiy <ilnik@webrtc.org>
Reviewed-by: Stefan Holmer <stefan@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#22529}
2018-03-21 10:20:48 +00:00
Niels Möller
2e1d784956 Delete the VideoCodec::plName string.
It holds the same information as codecType, but in different format.

Bug: webrtc:8830
Change-Id: Ia83e2dff4fd9a5ddb489501b7a1fe80759fa4218
Reviewed-on: https://webrtc-review.googlesource.com/56100
Reviewed-by: Erik Språng <sprang@webrtc.org>
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Reviewed-by: Danil Chapovalov <danilchap@webrtc.org>
Commit-Queue: Niels Moller <nisse@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#22307}
2018-03-06 11:17:41 +00:00
Sergey Silkin
a796a7ee85 Reland "Replaced temporal_layer_thresholds_bps[] field with num_temporal_layers."
This reverts commit e27e0aca94.

Reason for revert: <INSERT REASONING HERE>

Original change's description:
> Revert "Replaced temporal_layer_thresholds_bps[] field with num_temporal_layers."
> 
> This reverts commit d2ed0a4c9e.
> 
> Reason for revert: Breaks downstream projects.
> 
> Original change's description:
> > Replaced temporal_layer_thresholds_bps[] field with num_temporal_layers.
> > 
> > temporal_layer_thresholds_bps served only one purpose: its size was used
> > to infer number of temporal layers. I replaced it with num_temporal_layers,
> > which does what is says.
> > 
> > The practical reason for this change is the need to have possibility to
> > distinguish between cases when VP9 SVC temporal layering was/not set
> > through field trial. That was not possible with
> > temporal_layer_thresholds_bps[] because empty vector means 1 temporal
> > layer.
> > 
> > Bug: webrtc:8518
> > Change-Id: I275ec3a8c74e8ba409eb049878199f132a20ec51
> > Reviewed-on: https://webrtc-review.googlesource.com/58084
> > Commit-Queue: Sergey Silkin <ssilkin@webrtc.org>
> > Reviewed-by: Erik Språng <sprang@webrtc.org>
> > Reviewed-by: Stefan Holmer <stefan@webrtc.org>
> > Cr-Commit-Position: refs/heads/master@{#22230}
> 
> TBR=sprang@webrtc.org,stefan@webrtc.org,ssilkin@webrtc.org
> 
> Change-Id: Ic2940f7f78a74312170940d51ad8967cde8ad42f
> No-Presubmit: true
> No-Tree-Checks: true
> No-Try: true
> Bug: webrtc:8518
> Reviewed-on: https://webrtc-review.googlesource.com/58902
> Reviewed-by: Philip Eliasson <philipel@webrtc.org>
> Commit-Queue: Philip Eliasson <philipel@webrtc.org>
> Cr-Commit-Position: refs/heads/master@{#22234}

TBR=sprang@webrtc.org,stefan@webrtc.org,philipel@webrtc.org,ssilkin@webrtc.org

Change-Id: I1900c6b845b9baa9430fb72c3f4e7f2a44b3a8b1
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: webrtc:8518
Reviewed-on: https://webrtc-review.googlesource.com/59160
Commit-Queue: Sergey Silkin <ssilkin@webrtc.org>
Reviewed-by: Sergey Silkin <ssilkin@webrtc.org>
Reviewed-by: Erik Språng <sprang@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#22256}
2018-03-01 18:07:29 +00:00
Philip Eliasson
e27e0aca94 Revert "Replaced temporal_layer_thresholds_bps[] field with num_temporal_layers."
This reverts commit d2ed0a4c9e.

Reason for revert: Breaks downstream projects.

Original change's description:
> Replaced temporal_layer_thresholds_bps[] field with num_temporal_layers.
> 
> temporal_layer_thresholds_bps served only one purpose: its size was used
> to infer number of temporal layers. I replaced it with num_temporal_layers,
> which does what is says.
> 
> The practical reason for this change is the need to have possibility to
> distinguish between cases when VP9 SVC temporal layering was/not set
> through field trial. That was not possible with
> temporal_layer_thresholds_bps[] because empty vector means 1 temporal
> layer.
> 
> Bug: webrtc:8518
> Change-Id: I275ec3a8c74e8ba409eb049878199f132a20ec51
> Reviewed-on: https://webrtc-review.googlesource.com/58084
> Commit-Queue: Sergey Silkin <ssilkin@webrtc.org>
> Reviewed-by: Erik Språng <sprang@webrtc.org>
> Reviewed-by: Stefan Holmer <stefan@webrtc.org>
> Cr-Commit-Position: refs/heads/master@{#22230}

TBR=sprang@webrtc.org,stefan@webrtc.org,ssilkin@webrtc.org

Change-Id: Ic2940f7f78a74312170940d51ad8967cde8ad42f
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: webrtc:8518
Reviewed-on: https://webrtc-review.googlesource.com/58902
Reviewed-by: Philip Eliasson <philipel@webrtc.org>
Commit-Queue: Philip Eliasson <philipel@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#22234}
2018-02-28 16:01:32 +00:00
Sergey Silkin
d2ed0a4c9e Replaced temporal_layer_thresholds_bps[] field with num_temporal_layers.
temporal_layer_thresholds_bps served only one purpose: its size was used
to infer number of temporal layers. I replaced it with num_temporal_layers,
which does what is says.

The practical reason for this change is the need to have possibility to
distinguish between cases when VP9 SVC temporal layering was/not set
through field trial. That was not possible with
temporal_layer_thresholds_bps[] because empty vector means 1 temporal
layer.

Bug: webrtc:8518
Change-Id: I275ec3a8c74e8ba409eb049878199f132a20ec51
Reviewed-on: https://webrtc-review.googlesource.com/58084
Commit-Queue: Sergey Silkin <ssilkin@webrtc.org>
Reviewed-by: Erik Språng <sprang@webrtc.org>
Reviewed-by: Stefan Holmer <stefan@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#22230}
2018-02-28 14:46:03 +00:00
Anders Carlsson
dd8c16574e Enable building WebRTC without built-in software codecs
This CL adds a GN build flag to include builtin software codecs
(enabled by default).

When setting the flag to false, libvpx can also be excluded. The
benefit is that the resulting binary is smaller.

Replaces https://webrtc-review.googlesource.com/c/src/+/29203

Bug: webrtc:7925
Change-Id: Id330ea8a43169e449ee139eca18e4557cc932e10
Reviewed-on: https://webrtc-review.googlesource.com/36340
Commit-Queue: Anders Carlsson <andersc@webrtc.org>
Reviewed-by: Patrik Höglund <phoglund@webrtc.org>
Reviewed-by: Taylor Brandstetter <deadbeef@webrtc.org>
Reviewed-by: Erik Språng <sprang@webrtc.org>
Reviewed-by: Magnus Jedvert <magjed@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#21818}
2018-01-31 08:33:59 +00:00
Emircan Uysaler
d7ae3c34e5 Reland "Rename stereo video codec to multiplex"
This is a reland of bbdabe50db.

Original change's description:
> Rename stereo video codec to multiplex
>
> This CL only does the rename from"stereo" to multiplex". With this we have a
> better name that doesn't clash with audio's usage of stereo.
>
> Bug: webrtc:7671
> Change-Id: Iebc3fc20839025f1bc8bcf0e16141bf9744ef652
> Reviewed-on: https://webrtc-review.googlesource.com/43242
> Commit-Queue: Emircan Uysaler <emircan@webrtc.org>
> Reviewed-by: Niklas Enbom <niklas.enbom@webrtc.org>
> Cr-Commit-Position: refs/heads/master@{#21769}

TBR=niklas.enbom@webrtc.org

Bug: webrtc:7671
Change-Id: I6f38dc46126f279f334d52b56339b40acdc30511
Reviewed-on: https://webrtc-review.googlesource.com/45820
Reviewed-by: Emircan Uysaler <emircan@webrtc.org>
Commit-Queue: Emircan Uysaler <emircan@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#21794}
2018-01-29 20:37:59 +00:00
Taylor Brandstetter
1204448a68 Revert "Reland "Rename stereo video codec to multiplex""
This reverts commit 4954a77cf8.

Reason for revert: Breaks downstream build which was depending on the name "kVideoCodecStereo". Will need to do some sort of trickery to make this change without breaking the relevant code. Sorry. :(

Original change's description:
> Reland "Rename stereo video codec to multiplex"
> 
> This is a reland of bbdabe50db.
> This was reverted because of breaking internal build. I contacted sheriff
> and looked at logs but cannot find anything related to this CL. This was landed
> with #3850 build which caused exception, but 3847-3855 seem to all have failed.
> I am relanding to see if it will work this time or it will give some related
> error message that can guide me.
> 
> Original change's description:
> > Rename stereo video codec to multiplex
> >
> > This CL only does the rename from"stereo" to multiplex". With this we have a
> > better name that doesn't clash with audio's usage of stereo.
> >
> > Bug: webrtc:7671
> > Change-Id: Iebc3fc20839025f1bc8bcf0e16141bf9744ef652
> > Reviewed-on: https://webrtc-review.googlesource.com/43242
> > Commit-Queue: Emircan Uysaler <emircan@webrtc.org>
> > Reviewed-by: Niklas Enbom <niklas.enbom@webrtc.org>
> > Cr-Commit-Position: refs/heads/master@{#21769}
> 
> TBR=niklas.enbom@webrtc.org
> 
> Bug: webrtc:7671
> Change-Id: I5934abad1ce28acf02842ea8ee2af7768a826eb8
> Reviewed-on: https://webrtc-review.googlesource.com/44520
> Reviewed-by: Emircan Uysaler <emircan@webrtc.org>
> Commit-Queue: Emircan Uysaler <emircan@webrtc.org>
> Cr-Commit-Position: refs/heads/master@{#21780}

TBR=sprang@webrtc.org,niklas.enbom@webrtc.org,qiangchen@chromium.org,emircan@webrtc.org

Change-Id: I0a71327c2ddfdd030b1e058cd6a41b1689836719
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: webrtc:7671
Reviewed-on: https://webrtc-review.googlesource.com/44621
Reviewed-by: Taylor Brandstetter <deadbeef@webrtc.org>
Commit-Queue: Taylor Brandstetter <deadbeef@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#21783}
2018-01-27 00:45:20 +00:00
Emircan Uysaler
4954a77cf8 Reland "Rename stereo video codec to multiplex"
This is a reland of bbdabe50db.
This was reverted because of breaking internal build. I contacted sheriff
and looked at logs but cannot find anything related to this CL. This was landed
with #3850 build which caused exception, but 3847-3855 seem to all have failed.
I am relanding to see if it will work this time or it will give some related
error message that can guide me.

Original change's description:
> Rename stereo video codec to multiplex
>
> This CL only does the rename from"stereo" to multiplex". With this we have a
> better name that doesn't clash with audio's usage of stereo.
>
> Bug: webrtc:7671
> Change-Id: Iebc3fc20839025f1bc8bcf0e16141bf9744ef652
> Reviewed-on: https://webrtc-review.googlesource.com/43242
> Commit-Queue: Emircan Uysaler <emircan@webrtc.org>
> Reviewed-by: Niklas Enbom <niklas.enbom@webrtc.org>
> Cr-Commit-Position: refs/heads/master@{#21769}

TBR=niklas.enbom@webrtc.org

Bug: webrtc:7671
Change-Id: I5934abad1ce28acf02842ea8ee2af7768a826eb8
Reviewed-on: https://webrtc-review.googlesource.com/44520
Reviewed-by: Emircan Uysaler <emircan@webrtc.org>
Commit-Queue: Emircan Uysaler <emircan@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#21780}
2018-01-26 21:11:54 +00:00
Ivo Creusen
6bc7bb659e Revert "Rename stereo video codec to multiplex"
This reverts commit bbdabe50db.

Reason for revert: This breaks the internal build.

Original change's description:
> Rename stereo video codec to multiplex
> 
> This CL only does the rename from"stereo" to multiplex". With this we have a
> better name that doesn't clash with audio's usage of stereo.
> 
> Bug: webrtc:7671
> Change-Id: Iebc3fc20839025f1bc8bcf0e16141bf9744ef652
> Reviewed-on: https://webrtc-review.googlesource.com/43242
> Commit-Queue: Emircan Uysaler <emircan@webrtc.org>
> Reviewed-by: Niklas Enbom <niklas.enbom@webrtc.org>
> Cr-Commit-Position: refs/heads/master@{#21769}

TBR=sprang@webrtc.org,niklas.enbom@webrtc.org,qiangchen@chromium.org,emircan@webrtc.org

Change-Id: Icf019cb09e07de45821d31d7d8ea7707d01346ee
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: webrtc:7671
Reviewed-on: https://webrtc-review.googlesource.com/44360
Commit-Queue: Ivo Creusen <ivoc@webrtc.org>
Reviewed-by: Ivo Creusen <ivoc@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#21774}
2018-01-26 12:44:54 +00:00
Emircan Uysaler
bbdabe50db Rename stereo video codec to multiplex
This CL only does the rename from"stereo" to multiplex". With this we have a
better name that doesn't clash with audio's usage of stereo.

Bug: webrtc:7671
Change-Id: Iebc3fc20839025f1bc8bcf0e16141bf9744ef652
Reviewed-on: https://webrtc-review.googlesource.com/43242
Commit-Queue: Emircan Uysaler <emircan@webrtc.org>
Reviewed-by: Niklas Enbom <niklas.enbom@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#21769}
2018-01-25 23:16:04 +00:00
Seth Hampson
46e31ba5b5 Reland "Enables/disables simulcast streams by allocating a bitrate of 0 to the spatial layer."
This is a reland of 18c4261339
Original change's description:
> Enables/disables simulcast streams by allocating a bitrate of 0 to the spatial layer.
>
> Creates VideoStreams & VideoCodec.simulcastStreams with an active field, and then allocates 0 bitrate to simulcast streams that are inactive. This turns off the encoder for specific simulcast streams.
>
> Bug: webrtc:8653
> Change-Id: Id93b03dcd8d1191a7d3300bd77882c8af96ee469
> Reviewed-on: https://webrtc-review.googlesource.com/37740
> Reviewed-by: Stefan Holmer <stefan@webrtc.org>
> Reviewed-by: Taylor Brandstetter <deadbeef@webrtc.org>
> Reviewed-by: Erik Språng <sprang@webrtc.org>
> Commit-Queue: Seth Hampson <shampson@webrtc.org>
> Cr-Commit-Position: refs/heads/master@{#21646}

TBR=sprang@webrtc.org,stefan@webrtc.org,deadbeef@webrtc.org

Bug: webrtc:8630
Change-Id: Ib3df6f9b7158bff362a7ec66fc57e368682c5846
Reviewed-on: https://webrtc-review.googlesource.com/40980
Reviewed-by: Seth Hampson <shampson@webrtc.org>
Reviewed-by: Erik Språng <sprang@webrtc.org>
Commit-Queue: Seth Hampson <shampson@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#21688}
2018-01-18 22:42:23 +00:00
Lu Liu
0f17f9ce28 Revert "Enables/disables simulcast streams by allocating a bitrate of 0 to the spatial layer."
This reverts commit 18c4261339.

Reason for revert: Broke internal tests

Original change's description:
> Enables/disables simulcast streams by allocating a bitrate of 0 to the spatial layer.
> 
> Creates VideoStreams & VideoCodec.simulcastStreams with an active field, and then allocates 0 bitrate to simulcast streams that are inactive. This turns off the encoder for specific simulcast streams.
> 
> Bug: webrtc:8653
> Change-Id: Id93b03dcd8d1191a7d3300bd77882c8af96ee469
> Reviewed-on: https://webrtc-review.googlesource.com/37740
> Reviewed-by: Stefan Holmer <stefan@webrtc.org>
> Reviewed-by: Taylor Brandstetter <deadbeef@webrtc.org>
> Reviewed-by: Erik Språng <sprang@webrtc.org>
> Commit-Queue: Seth Hampson <shampson@webrtc.org>
> Cr-Commit-Position: refs/heads/master@{#21646}

TBR=deadbeef@webrtc.org,sprang@webrtc.org,stefan@webrtc.org,shampson@webrtc.org

Change-Id: I0aeb743cbd2e8d564aa732c937587c25a4c49b09
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: webrtc:8653
Reviewed-on: https://webrtc-review.googlesource.com/39883
Reviewed-by: Lu Liu <lliuu@webrtc.org>
Commit-Queue: Lu Liu <lliuu@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#21647}
2018-01-17 00:28:27 +00:00
Seth Hampson
18c4261339 Enables/disables simulcast streams by allocating a bitrate of 0 to the spatial layer.
Creates VideoStreams & VideoCodec.simulcastStreams with an active field, and then allocates 0 bitrate to simulcast streams that are inactive. This turns off the encoder for specific simulcast streams.

Bug: webrtc:8653
Change-Id: Id93b03dcd8d1191a7d3300bd77882c8af96ee469
Reviewed-on: https://webrtc-review.googlesource.com/37740
Reviewed-by: Stefan Holmer <stefan@webrtc.org>
Reviewed-by: Taylor Brandstetter <deadbeef@webrtc.org>
Reviewed-by: Erik Språng <sprang@webrtc.org>
Commit-Queue: Seth Hampson <shampson@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#21646}
2018-01-16 19:36:14 +00:00
Qiang Chen
a9329dbae2 Bug Fix: Peers Cannot Communicate If One With Stereo Codec, One Not
When Chromium hooks up with the stereo codec, then it has difficulty
communicating with a google chrome without stereo codec. By design, we
do allow codec choice for the standalone codecs, but the problem is
that we do not handle the payload correctly, and thus the existence
of stereo codec will remove the payload registry of the standalone
version of its associated codec. (For example, stereo codec on top of
VP9 will remove the payload registry of standalone VP9 codec.)

This CL fixes the issue. When generating payload data, we should use
"stereo" as payload name, instead of its associated codecs.


Bug: webrtc:8657
Change-Id: I9e0b54de6bd41d370b9353f9553c998e4049789f
Reviewed-on: https://webrtc-review.googlesource.com/33122
Reviewed-by: Emircan Uysaler <emircan@webrtc.org>
Reviewed-by: Stefan Holmer <stefan@webrtc.org>
Commit-Queue: Qiang Chen <qiangchen@chromium.org>
Cr-Commit-Position: refs/heads/master@{#21523}
2018-01-08 17:53:39 +00:00
Emircan Uysaler
0a37547033 Add optional stereo codec to SDP negotiation
- Defines stereo codec case, similar to RTX, that adds stereo codec to the SDP
negotiation. The underlying codec's payload type is similarly defined by "apt".
- If this negotiation is successful, codec name is included in sdp line via
"acn".
- Adds codec setting initializers for these specific stereo cases.
- Introduces new Stereo*Factory classes as optional convenience wrappers that
inserts stereo codec to the existing set of supported codecs on demand.

This CL is the step 5 for adding alpha channel support over the wire in webrtc.
Design Doc: https://goo.gl/sFeSUT

Bug: webrtc:7671
Change-Id: Ie12c56c8fcf7934e216135d73af33adec5248f76
Reviewed-on: https://webrtc-review.googlesource.com/22901
Commit-Queue: Niklas Enbom <niklas.enbom@webrtc.org>
Reviewed-by: Niklas Enbom <niklas.enbom@webrtc.org>
Reviewed-by: Magnus Jedvert <magjed@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#21210}
2017-12-11 16:30:06 +00:00
Mirko Bonadei
675513b96a Stop using LOG macros in favor of RTC_ prefixed macros.
This CL has been generated with the following script:

for m in PLOG \
  LOG_TAG \
  LOG_GLEM \
  LOG_GLE_EX \
  LOG_GLE \
  LAST_SYSTEM_ERROR \
  LOG_ERRNO_EX \
  LOG_ERRNO \
  LOG_ERR_EX \
  LOG_ERR \
  LOG_V \
  LOG_F \
  LOG_T_F \
  LOG_E \
  LOG_T \
  LOG_CHECK_LEVEL_V \
  LOG_CHECK_LEVEL \
  LOG
do
  git grep -l $m | xargs sed -i "s,\b$m\b,RTC_$m,g"
done
git checkout rtc_base/logging.h
git cl format

Bug: webrtc:8452
Change-Id: I1a53ef3e0a5ef6e244e62b2e012b864914784600
Reviewed-on: https://webrtc-review.googlesource.com/21325
Reviewed-by: Niels Moller <nisse@webrtc.org>
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Commit-Queue: Mirko Bonadei <mbonadei@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#20617}
2017-11-09 11:56:32 +00:00
Mirko Bonadei
7120742701 Adding NOLINT for typedefs.h and common_types.h
Now that we have moved WebRTC from src/webrtc to src/, common_types.h
and typedefs.h are triggering a cpplint error.

The cpplint complaint is:
Include the directory when naming .h files  [build/include] [4]

This CL disables the error but we have to remove these two headers
from the root directory.

NOPRESUBMIT=true

Bug: webrtc:5876
Change-Id: I08e1b69aadcc4b28ab83bf25e3819d135d41d333
Reviewed-on: https://webrtc-review.googlesource.com/1577
Commit-Queue: Mirko Bonadei <mbonadei@webrtc.org>
Reviewed-by: Henrik Kjellander <kjellander@google.com>
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#19859}
2017-09-15 13:03:51 +00:00
Mirko Bonadei
92ea95e34a Fixing WebRTC after moving from src/webrtc to src/
In https://webrtc-review.googlesource.com/c/src/+/1560 we moved WebRTC
from src/webrtc to src/ (in order to preserve an healthy git history).
This CL takes care of fixing header guards, #include paths, etc...

NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
TBR=tommi@webrtc.org


Bug: chromium:611808
Change-Id: Iea91618212bee0af16aa3f05071eab8f93706578
Reviewed-on: https://webrtc-review.googlesource.com/1561
Reviewed-by: Mirko Bonadei <mbonadei@webrtc.org>
Reviewed-by: Henrik Kjellander <kjellander@webrtc.org>
Commit-Queue: Mirko Bonadei <mbonadei@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#19846}
2017-09-15 05:02:56 +00:00
Mirko Bonadei
bb547203bf Moving src/webrtc into src/.
In order to eliminate the WebRTC Subtree mirror in Chromium, 
WebRTC is moving the content of the src/webrtc directory up
to the src/ directory.

NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
TBR=tommi@webrtc.org

Bug: chromium:611808
Change-Id: Iac59c5b51b950f174119565bac87955a7994bc38
Reviewed-on: https://webrtc-review.googlesource.com/1560
Commit-Queue: Mirko Bonadei <mbonadei@webrtc.org>
Reviewed-by: Henrik Kjellander <kjellander@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#19845}
2017-09-15 04:25:06 +00:00
Renamed from webrtc/modules/video_coding/video_codec_initializer.cc (Browse further)