webrtc/api
Danil Chapovalov df2c601616 Move Offset constants from VideoSendTiming value to VideoTimingExtension class
These constants describes how value should be put on the wire and thus
belong to the extension builder/writer class rather than extension value class

Bug: None
Change-Id: I65ca3923eddcc2e48563ad69b98356c159ad86be
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/166461
Reviewed-by: Ilya Nikolaevskiy <ilnik@webrtc.org>
Commit-Queue: Danil Chapovalov <danilchap@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#30305}
2020-01-17 15:57:38 +00:00
..
audio AEC3: Ensure that the data size in the reverb computer is not fixed 2019-12-19 16:35:56 +00:00
audio_codecs Add Opus-only audio codec factories 2019-11-26 18:28:07 +00:00
call Add missing RTC_EXPORT for the component build. 2019-10-15 09:07:44 +00:00
crypto do not offer gcm as the preferred cipher suite 2019-10-31 20:59:42 +00:00
neteq Clean up the NetEqFactory API. 2019-11-29 14:04:44 +00:00
rtc_event_log Prefix ENABLE_RTC_EVENT_LOG with WEBRTC_. 2019-11-29 09:45:50 +00:00
stats Implement RTCOutboundRtpStreamStats::remoteId. 2020-01-07 17:26:01 +00:00
task_queue Reland "Force Chromium deps on the WebRTC component." 2019-11-18 12:16:43 +00:00
test Using EmulatedEndpoint in Scenario tests. 2020-01-17 12:50:20 +00:00
transport GOOG_PING: improve handshake 2020-01-15 16:09:38 +00:00
units Using unit types in TransportFeedbackAdapter. 2019-11-06 12:25:00 +00:00
video Move Offset constants from VideoSendTiming value to VideoTimingExtension class 2020-01-17 15:57:38 +00:00
video_codecs Replace RTC_FALLTHROUGH with ABSL_FALLTHROUGH_INTENTED 2020-01-16 15:20:35 +00:00
array_view.h Adding reinterpret to ArrayView to allow data manipulation. 2019-03-22 18:15:22 +00:00
array_view_unittest.cc Format almost everything. 2019-07-08 13:45:15 +00:00
async_resolver_factory.h (4) Rename files to snake_case: update BUILD.gn, include paths, header guards, and DEPS entries 2019-01-11 17:11:39 +00:00
audio_options.cc Remove deprecated code related to AEC2 2019-08-07 10:09:36 +00:00
audio_options.h Export more symbols to fix Chromecast component build 2019-12-03 17:41:04 +00:00
BUILD.gn Revert "Enable using a custom NetEqFactory in simulations" 2020-01-16 22:56:21 +00:00
candidate.cc (4) Rename files to snake_case: update BUILD.gn, include paths, header guards, and DEPS entries 2019-01-11 17:11:39 +00:00
candidate.h (4) Rename files to snake_case: update BUILD.gn, include paths, header guards, and DEPS entries 2019-01-11 17:11:39 +00:00
create_peerconnection_factory.cc Use std::make_unique instead of absl::make_unique. 2019-09-17 15:47:29 +00:00
create_peerconnection_factory.h Force DefaultTaskQueueFactory in legacy CreatePeerConnectionFactory 2019-06-19 17:11:04 +00:00
crypto_params.h (4) Rename files to snake_case: update BUILD.gn, include paths, header guards, and DEPS entries 2019-01-11 17:11:39 +00:00
data_channel_interface.cc Datachannel: Use absl::optional for maxRetransmits and maxRetransmitTime. 2019-04-09 08:32:43 +00:00
data_channel_interface.h Return an error when datachannel closes due to network error 2019-12-08 17:33:54 +00:00
DEPS Reland "Using simulated rtc::Thread for peer connection scenario tests." 2020-01-17 09:22:18 +00:00
DESIGN.md A threading explanation 2019-06-03 08:15:09 +00:00
dtls_transport_interface.cc Expose TLS version and SRTP cipher to API 2019-10-29 22:20:49 +00:00
dtls_transport_interface.h Expose TLS version and SRTP cipher to API 2019-10-29 22:20:49 +00:00
dtmf_sender_interface.h (4) Rename files to snake_case: update BUILD.gn, include paths, header guards, and DEPS entries 2019-01-11 17:11:39 +00:00
fec_controller.h Make VideoFrameType an enum class, and move to separate file and target 2019-03-22 12:44:51 +00:00
fec_controller_override.h Define FecControllerOverride and plumb it down to VideoEncoder 2019-06-28 15:57:22 +00:00
function_view.h Move rtc::FunctionView to the public API 2019-03-21 15:23:05 +00:00
function_view_unittest.cc Format almost everything. 2019-07-08 13:45:15 +00:00
ice_transport_factory.cc Use std::make_unique instead of absl::make_unique. 2019-09-17 15:47:29 +00:00
ice_transport_factory.h Make ICE transports injectable. 2019-11-15 21:31:19 +00:00
ice_transport_interface.h Make ICE transports injectable. 2019-11-15 21:31:19 +00:00
jsep.cc Reland "Implement rollback for setRemoteDescription" 2019-10-14 12:40:53 +00:00
jsep.h Add 3 missing RTC_EXPORT. 2019-11-05 09:40:03 +00:00
jsep_ice_candidate.cc Use unique_ptr in JsepCandidateCollection 2019-07-31 01:48:07 +00:00
jsep_ice_candidate.h Use unique_ptr in JsepCandidateCollection 2019-07-31 01:48:07 +00:00
jsep_session_description.h Remove deprecated JsepSession initializer 2019-06-11 17:35:30 +00:00
media_stream_interface.cc New target for api/rtp_parameters.h and api/media_types.h. 2019-08-29 09:04:32 +00:00
media_stream_interface.h MediaStreamInterface: introduce encoded sinks. 2019-11-21 12:03:35 +00:00
media_stream_proxy.h (4) Rename files to snake_case: update BUILD.gn, include paths, header guards, and DEPS entries 2019-01-11 17:11:39 +00:00
media_stream_track_proxy.h (4) Rename files to snake_case: update BUILD.gn, include paths, header guards, and DEPS entries 2019-01-11 17:11:39 +00:00
media_types.cc New target for api/rtp_parameters.h and api/media_types.h. 2019-08-29 09:04:32 +00:00
media_types.h New target for api/rtp_parameters.h and api/media_types.h. 2019-08-29 09:04:32 +00:00
network_state_predictor.h Add base class NetworkPredictor and NetworkPredictorFactory and wire up. 2019-04-10 12:38:58 +00:00
notifier.h (4) Rename files to snake_case: update BUILD.gn, include paths, header guards, and DEPS entries 2019-01-11 17:11:39 +00:00
OWNERS Remove myself from OWNERS in a few places. 2019-06-10 07:57:46 +00:00
packet_socket_factory.h Prepare to move packet_socket_factory to api/. 2019-09-06 09:09:02 +00:00
peer_connection_factory_proxy.h Delete deprecated version of PeerConnectionFactoryInterface::StartAecDump 2019-06-27 07:33:59 +00:00
peer_connection_interface.cc Delete almost all default methods on PeerConnectionInterface 2019-09-18 16:27:44 +00:00
peer_connection_interface.h Replace hostCandidate with address and port in RTCPeerConnectionIceErrorEvent 2019-12-04 13:18:22 +00:00
peer_connection_proxy.h [PeerConnection] Implement asynchronous version of AddIceCandidate(). 2019-11-06 12:16:00 +00:00
proxy.cc Revert "Replaces SynchronousMethodCall with rtc::Thread::Invoke." 2020-01-15 12:34:35 +00:00
proxy.h Revert "Replaces SynchronousMethodCall with rtc::Thread::Invoke." 2020-01-15 12:34:35 +00:00
README.md Add a small README file for api/ 2019-02-01 13:24:47 +00:00
ref_counted_base.h (4) Rename files to snake_case: update BUILD.gn, include paths, header guards, and DEPS entries 2019-01-11 17:11:39 +00:00
rtc_error.cc Return an error when datachannel closes due to network error 2019-12-08 17:33:54 +00:00
rtc_error.h Re-introduce the RTCError move constructor/assignment 2020-01-08 22:39:25 +00:00
rtc_error_unittest.cc Format almost everything. 2019-07-08 13:45:15 +00:00
rtc_event_log_output.h Adds functionality to write logs to memory. 2019-01-16 17:36:31 +00:00
rtc_event_log_output_file.cc Format almost everything. 2019-07-08 13:45:15 +00:00
rtc_event_log_output_file.h Format almost everything. 2019-07-08 13:45:15 +00:00
rtc_event_log_output_file_unittest.cc Use std::make_unique instead of absl::make_unique. 2019-09-17 15:47:29 +00:00
rtp_headers.cc Reland "[cleanup] Remove useless includes." 2018-10-08 07:44:19 +00:00
rtp_headers.h Make NetworkStateEstimator injectable in RemoteBitrateEstimator 2019-09-10 18:47:36 +00:00
rtp_packet_info.cc Add AbsoluteCaptureTime to RtpPacketInfo. 2019-08-07 10:12:56 +00:00
rtp_packet_info.h Add AbsoluteCaptureTime to RtpPacketInfo. 2019-08-07 10:12:56 +00:00
rtp_packet_info_unittest.cc Add AbsoluteCaptureTime to RtpPacketInfo. 2019-08-07 10:12:56 +00:00
rtp_packet_infos.h Avoid copying of vectors in RtpPacketInfos. 2019-08-14 15:46:02 +00:00
rtp_packet_infos_unittest.cc Add AbsoluteCaptureTime to RtpPacketInfo. 2019-08-07 10:12:56 +00:00
rtp_parameters.cc Allow AbsSendTime extension to be used for audio streams. 2019-07-24 10:58:37 +00:00
rtp_parameters.h Delete obsolete unused rtp header extension conversion 2020-01-09 09:28:07 +00:00
rtp_parameters_unittest.cc Format almost everything. 2019-07-08 13:45:15 +00:00
rtp_receiver_interface.cc Split out RtpSource from libjingle_peerconnection_api 2019-09-02 14:04:47 +00:00
rtp_receiver_interface.h Deprecate RtpReceiver's SetParameters method 2019-12-03 19:50:42 +00:00
rtp_sender_interface.cc Removing non-const RtpSenderInterface::GetParameters(). 2019-02-23 00:51:30 +00:00
rtp_sender_interface.h Add missing RTC_EXPORT for the component build. 2019-10-15 09:07:44 +00:00
rtp_transceiver_interface.cc Implement RTCRtpTransceiver.setCodecPreferences 2019-05-01 20:14:59 +00:00
rtp_transceiver_interface.h Add missing RTC_EXPORT for the component build. 2019-10-15 09:07:44 +00:00
scoped_refptr.h Mark scoped_refptr move and swap operations as noexcept 2019-11-12 10:17:22 +00:00
scoped_refptr_unittest.cc Mark scoped_refptr move and swap operations as noexcept 2019-11-12 10:17:22 +00:00
sctp_transport_interface.cc Format almost everything. 2019-07-08 13:45:15 +00:00
sctp_transport_interface.h Export symbols needed by the Chromium component build (part 8). 2019-04-02 10:13:36 +00:00
set_remote_description_observer_interface.h (4) Rename files to snake_case: update BUILD.gn, include paths, header guards, and DEPS entries 2019-01-11 17:11:39 +00:00
stats_types.cc Reporting audio device underrun counter 2019-08-16 11:49:55 +00:00
stats_types.h RTC_EXPORT IceServer, StatsReport::{IdBase,Value}. 2019-11-12 12:52:25 +00:00
turn_customizer.h (4) Rename files to snake_case: update BUILD.gn, include paths, header guards, and DEPS entries 2019-01-11 17:11:39 +00:00
uma_metrics.h Remove backwards compatibility names from api/uma_metrics.h. 2019-08-29 13:35:56 +00:00
video_track_source_proxy.h VideoRtpTrackSource: implement encoded source methods. 2019-11-26 09:17:52 +00:00

How to write code in the api/ directory

Mostly, just follow the regular style guide, but:

  • Note that api/ code is not exempt from the “.h and .cc files come in pairs” rule, so if you declare something in api/path/to/foo.h, it should be defined in api/path/to/foo.cc.
  • Headers in api/ should, if possible, not #include headers outside api/. Its not always possible to avoid this, but be aware that it adds to a small mountain of technical debt that were trying to shrink.
  • .cc files in api/, on the other hand, are free to #include headers outside api/.

That is, the preferred way for api/ code to access non-api/ code is to call it from a .cc file, so that users of our API headers wont transitively #include non-public headers.

For headers in api/ that need to refer to non-public types, forward declarations are often a lesser evil than including non-public header files. The usual rules still apply, though.

.cc files in api/ should preferably be kept reasonably small. If a substantial implementation is needed, consider putting it with our non-public code, and just call it from the api/ .cc file.