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

Unified Diff: talk/media/webrtc/simulcast.cc

Issue 1405023016: Convert usage of ARRAY_SIZE to arraysize. (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: static_cast<int> Created 5 years, 1 month 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « talk/media/sctp/sctpdataengine.cc ('k') | talk/media/webrtc/webrtcmediaengine.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: talk/media/webrtc/simulcast.cc
diff --git a/talk/media/webrtc/simulcast.cc b/talk/media/webrtc/simulcast.cc
index f55d9606a535ef31309534c51bd3d6b296012af8..b67a363a763eebc345dbd4237c8af988566c5627 100755
--- a/talk/media/webrtc/simulcast.cc
+++ b/talk/media/webrtc/simulcast.cc
@@ -29,9 +29,11 @@
#include "talk/media/base/streamparams.h"
#include "talk/media/webrtc/simulcast.h"
+#include "webrtc/base/arraysize.h"
#include "webrtc/base/common.h"
#include "webrtc/base/logging.h"
#include "webrtc/system_wrappers/include/field_trial.h"
+
namespace cricket {
struct SimulcastFormat {
@@ -93,7 +95,7 @@ void MaybeExchangeWidthHeight(int* width, int* height) {
int FindSimulcastFormatIndex(int width, int height) {
MaybeExchangeWidthHeight(&width, &height);
- for (int i = 0; i < ARRAY_SIZE(kSimulcastFormats); ++i) {
+ for (int i = 0; i < arraysize(kSimulcastFormats); ++i) {
if (width >= kSimulcastFormats[i].width &&
height >= kSimulcastFormats[i].height) {
return i;
@@ -105,7 +107,7 @@ int FindSimulcastFormatIndex(int width, int height) {
int FindSimulcastFormatIndex(int width, int height, size_t max_layers) {
MaybeExchangeWidthHeight(&width, &height);
- for (int i = 0; i < ARRAY_SIZE(kSimulcastFormats); ++i) {
+ for (int i = 0; i < arraysize(kSimulcastFormats); ++i) {
if (width >= kSimulcastFormats[i].width &&
height >= kSimulcastFormats[i].height &&
max_layers == kSimulcastFormats[i].max_layers) {
« no previous file with comments | « talk/media/sctp/sctpdataengine.cc ('k') | talk/media/webrtc/webrtcmediaengine.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698