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

Unified Diff: media/cast/sender/performance_metrics_overlay.cc

Issue 1534273002: Switch to standard integer types in media/. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: more 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 side-by-side diff with in-line comments
Download patch
Index: media/cast/sender/performance_metrics_overlay.cc
diff --git a/media/cast/sender/performance_metrics_overlay.cc b/media/cast/sender/performance_metrics_overlay.cc
index 842bdf1937e4dba185f3a9527bb42ea5b40b08b6..dfa2f213837866304fff808ea075e03e61134cd5 100644
--- a/media/cast/sender/performance_metrics_overlay.cc
+++ b/media/cast/sender/performance_metrics_overlay.cc
@@ -29,7 +29,7 @@ const int kPlane = 0; // Y-plane in YUV formats.
// different value than it did before. |p_ul| is a pointer to the pixel at
// coordinate (0,0) in a single-channel 8bpp bitmap. |stride| is the number of
// bytes per row in the output bitmap.
-void DivergePixels(const gfx::Rect& rect, uint8* p_ul, int stride) {
+void DivergePixels(const gfx::Rect& rect, uint8_t* p_ul, int stride) {
DCHECK(p_ul);
DCHECK_GT(stride, 0);
@@ -52,14 +52,14 @@ void DivergePixels(const gfx::Rect& rect, uint8* p_ul, int stride) {
const int left = rect.x() * kScale;
const int right = rect.right() * kScale;
for (int y = top; y < bottom; ++y) {
- uint8* const p_l = p_ul + y * stride;
+ uint8_t* const p_l = p_ul + y * stride;
for (int x = left; x < right; ++x) {
int intensity = p_l[x];
if (intensity >= kDivergeDownThreshold)
intensity = std::max(kMinIntensity, intensity - kDivergeDownAmount);
else
intensity += kDivergeUpAmount;
- p_l[x] = static_cast<uint8>(intensity);
+ p_l[x] = static_cast<uint8_t>(intensity);
}
}
}
@@ -84,7 +84,7 @@ void RenderLineOfText(const std::string& line, int top, VideoFrame* frame) {
// Compute the pointer to the pixel at the upper-left corner of the first
// character to be rendered.
const int stride = frame->stride(kPlane);
- uint8* p_ul =
+ uint8_t* p_ul =
// Start at the first pixel in the first row...
frame->visible_data(kPlane) + (stride * top)
// ...now move to the right edge of the visible part of the frame...

Powered by Google App Engine
This is Rietveld 408576698