Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(252)

Side by Side Diff: chrome/renderer/media/cast_rtp_stream.h

Issue 1484403002: cast: Support for low-latency interactive mode (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebased Created 5 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef CHROME_RENDERER_MEDIA_CAST_RTP_STREAM_H_ 5 #ifndef CHROME_RENDERER_MEDIA_CAST_RTP_STREAM_H_
6 #define CHROME_RENDERER_MEDIA_CAST_RTP_STREAM_H_ 6 #define CHROME_RENDERER_MEDIA_CAST_RTP_STREAM_H_
7 7
8 #include <string> 8 #include <string>
9 #include <vector> 9 #include <vector>
10 10
11 #include "base/basictypes.h" 11 #include "base/basictypes.h"
12 #include "base/callback.h" 12 #include "base/callback.h"
13 #include "base/memory/ref_counted.h" 13 #include "base/memory/ref_counted.h"
14 #include "base/memory/scoped_ptr.h" 14 #include "base/memory/scoped_ptr.h"
15 #include "base/memory/weak_ptr.h" 15 #include "base/memory/weak_ptr.h"
16 #include "media/cast/cast_config.h"
17 #include "media/cast/constants.h"
16 #include "third_party/WebKit/public/platform/WebMediaStreamTrack.h" 18 #include "third_party/WebKit/public/platform/WebMediaStreamTrack.h"
17 19
18 namespace base { 20 namespace base {
19 class BinaryValue; 21 class BinaryValue;
20 class DictionaryValue; 22 class DictionaryValue;
21 } 23 }
22 24
23 class CastAudioSink; 25 class CastAudioSink;
24 class CastSession; 26 class CastSession;
25 class CastVideoSink; 27 class CastVideoSink;
26 28
27 // A key value pair structure for codec specific parameters. 29 // A key value pair structure for codec specific parameters.
28 struct CastCodecSpecificParams { 30 struct CastCodecSpecificParams {
29 std::string key; 31 std::string key;
30 std::string value; 32 std::string value;
31 33
32 CastCodecSpecificParams(); 34 CastCodecSpecificParams();
33 ~CastCodecSpecificParams(); 35 ~CastCodecSpecificParams();
34 }; 36 };
35 37
36 // Defines the basic properties of a payload supported by cast transport. 38 // Defines the basic properties of a payload supported by cast transport.
37 struct CastRtpPayloadParams { 39 struct CastRtpPayloadParams {
38 // RTP specific field that identifies the content type. 40 // RTP specific field that identifies the content type.
39 int payload_type; 41 int payload_type = media::cast::kDefaultRtpVideoPayloadType;
40 42
41 // Maximum latency in milliseconds. Implemetation tries to keep latency 43 // Maximum latency in milliseconds. Implemetation tries to keep latency
42 // under this threshold. 44 // under this threshold.
43 int max_latency_ms; 45 int max_latency_ms = media::cast::kDefaultRtpMaxDelayMs;
44 46
45 // Minimum latency. 47 // Minimum latency.
46 // Default value (0) means use max_latency_ms. 48 // Default value (0) means use max_latency_ms.
47 int min_latency_ms; 49 int min_latency_ms = 0;
50
51 // Starting latency on animated content.
52 // Default value (0) means use max_latency_ms.
53 int animated_latency_ms = 0;
48 54
49 // RTP specific field to identify a stream. 55 // RTP specific field to identify a stream.
50 int ssrc; 56 int ssrc = 1;
51 57
52 // RTP specific field to idenfity the feedback stream. 58 // RTP specific field to idenfity the feedback stream.
53 int feedback_ssrc; 59 int feedback_ssrc = 2;
54 60
55 // Update frequency of payload sample. 61 // Update frequency of payload sample.
56 int clock_rate; 62 int clock_rate = media::cast::kVideoFrequency;
57 63
58 // Maximum bitrate in kilobits per second. 64 // Maximum bitrate in kilobits per second.
59 int max_bitrate; 65 int max_bitrate = media::cast::kDefaultMaxVideoKbps;
60 66
61 // Minimum bitrate in kilobits per second. 67 // Minimum bitrate in kilobits per second.
62 int min_bitrate; 68 int min_bitrate = media::cast::kDefaultMinVideoKbps;
63 69
64 // Number of audio channels. 70 // Number of audio channels.
65 int channels; 71 int channels = 1;
66 72
67 // The maximum frame rate. 73 // The maximum frame rate.
68 double max_frame_rate; 74 double max_frame_rate = media::cast::kDefaultMaxFrameRate;
69 75
70 // Name of the codec used. 76 // Name of the codec used.
71 std::string codec_name; 77 std::string codec_name;
72 78
73 // AES encryption key. 79 // AES encryption key.
74 std::string aes_key; 80 std::string aes_key;
75 81
76 // AES encryption IV mask. 82 // AES encryption IV mask.
77 std::string aes_iv_mask; 83 std::string aes_iv_mask;
78 84
(...skipping 78 matching lines...) Expand 10 before | Expand all | Expand 10 after
157 CastRtpParams params_; 163 CastRtpParams params_;
158 base::Closure stop_callback_; 164 base::Closure stop_callback_;
159 ErrorCallback error_callback_; 165 ErrorCallback error_callback_;
160 166
161 base::WeakPtrFactory<CastRtpStream> weak_factory_; 167 base::WeakPtrFactory<CastRtpStream> weak_factory_;
162 168
163 DISALLOW_COPY_AND_ASSIGN(CastRtpStream); 169 DISALLOW_COPY_AND_ASSIGN(CastRtpStream);
164 }; 170 };
165 171
166 #endif // CHROME_RENDERER_MEDIA_CAST_RTP_STREAM_H_ 172 #endif // CHROME_RENDERER_MEDIA_CAST_RTP_STREAM_H_
OLDNEW
« no previous file with comments | « chrome/renderer/extensions/cast_streaming_native_handler.cc ('k') | chrome/renderer/media/cast_rtp_stream.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698