1cedac228d2dd51db4b79ea1e72c7f249408ee061Torne (Richard Coles)// Copyright 2014 The Chromium Authors. All rights reserved. 2cedac228d2dd51db4b79ea1e72c7f249408ee061Torne (Richard Coles)// Use of this source code is governed by a BSD-style license that can be 3cedac228d2dd51db4b79ea1e72c7f249408ee061Torne (Richard Coles)// found in the LICENSE file. 4cedac228d2dd51db4b79ea1e72c7f249408ee061Torne (Richard Coles) 51320f92c476a1ad9d19dba2a48c72b75566198e9Primiano Tucci#ifndef COMPONENTS_METRICS_GPU_GPU_METRICS_PROVIDER_H_ 61320f92c476a1ad9d19dba2a48c72b75566198e9Primiano Tucci#define COMPONENTS_METRICS_GPU_GPU_METRICS_PROVIDER_H_ 7cedac228d2dd51db4b79ea1e72c7f249408ee061Torne (Richard Coles) 8cedac228d2dd51db4b79ea1e72c7f249408ee061Torne (Richard Coles)#include "base/basictypes.h" 9cedac228d2dd51db4b79ea1e72c7f249408ee061Torne (Richard Coles)#include "components/metrics/metrics_provider.h" 10cedac228d2dd51db4b79ea1e72c7f249408ee061Torne (Richard Coles)#include "ui/gfx/size.h" 11cedac228d2dd51db4b79ea1e72c7f249408ee061Torne (Richard Coles) 121320f92c476a1ad9d19dba2a48c72b75566198e9Primiano Tuccinamespace metrics { 131320f92c476a1ad9d19dba2a48c72b75566198e9Primiano Tucci 14cedac228d2dd51db4b79ea1e72c7f249408ee061Torne (Richard Coles)// GPUMetricsProvider provides GPU-related metrics. 151320f92c476a1ad9d19dba2a48c72b75566198e9Primiano Tucciclass GPUMetricsProvider : public MetricsProvider { 16cedac228d2dd51db4b79ea1e72c7f249408ee061Torne (Richard Coles) public: 17cedac228d2dd51db4b79ea1e72c7f249408ee061Torne (Richard Coles) GPUMetricsProvider(); 18cedac228d2dd51db4b79ea1e72c7f249408ee061Torne (Richard Coles) virtual ~GPUMetricsProvider(); 19cedac228d2dd51db4b79ea1e72c7f249408ee061Torne (Richard Coles) 201320f92c476a1ad9d19dba2a48c72b75566198e9Primiano Tucci // MetricsProvider: 21cedac228d2dd51db4b79ea1e72c7f249408ee061Torne (Richard Coles) virtual void ProvideSystemProfileMetrics( 221320f92c476a1ad9d19dba2a48c72b75566198e9Primiano Tucci SystemProfileProto* system_profile_proto) OVERRIDE; 23cedac228d2dd51db4b79ea1e72c7f249408ee061Torne (Richard Coles) 24cedac228d2dd51db4b79ea1e72c7f249408ee061Torne (Richard Coles) protected: 25cedac228d2dd51db4b79ea1e72c7f249408ee061Torne (Richard Coles) // Exposed for the sake of mocking in test code. 26cedac228d2dd51db4b79ea1e72c7f249408ee061Torne (Richard Coles) 27cedac228d2dd51db4b79ea1e72c7f249408ee061Torne (Richard Coles) // Returns the screen size for the primary monitor. 28cedac228d2dd51db4b79ea1e72c7f249408ee061Torne (Richard Coles) virtual gfx::Size GetScreenSize() const; 29cedac228d2dd51db4b79ea1e72c7f249408ee061Torne (Richard Coles) 30cedac228d2dd51db4b79ea1e72c7f249408ee061Torne (Richard Coles) // Returns the device scale factor for the primary monitor. 31cedac228d2dd51db4b79ea1e72c7f249408ee061Torne (Richard Coles) virtual float GetScreenDeviceScaleFactor() const; 32cedac228d2dd51db4b79ea1e72c7f249408ee061Torne (Richard Coles) 33cedac228d2dd51db4b79ea1e72c7f249408ee061Torne (Richard Coles) // Returns the number of monitors the user is using. 34cedac228d2dd51db4b79ea1e72c7f249408ee061Torne (Richard Coles) virtual int GetScreenCount() const; 35cedac228d2dd51db4b79ea1e72c7f249408ee061Torne (Richard Coles) 36cedac228d2dd51db4b79ea1e72c7f249408ee061Torne (Richard Coles) private: 37cedac228d2dd51db4b79ea1e72c7f249408ee061Torne (Richard Coles) DISALLOW_COPY_AND_ASSIGN(GPUMetricsProvider); 38cedac228d2dd51db4b79ea1e72c7f249408ee061Torne (Richard Coles)}; 39cedac228d2dd51db4b79ea1e72c7f249408ee061Torne (Richard Coles) 401320f92c476a1ad9d19dba2a48c72b75566198e9Primiano Tucci} // namespace metrics 411320f92c476a1ad9d19dba2a48c72b75566198e9Primiano Tucci 421320f92c476a1ad9d19dba2a48c72b75566198e9Primiano Tucci#endif // COMPONENTS_METRICS_GPU_GPU_METRICS_PROVIDER_H_ 43