diff options
Diffstat (limited to 'content/browser/gpu')
-rw-r--r-- | content/browser/gpu/gpu_blacklist_unittest.cc | 2 | ||||
-rw-r--r-- | content/browser/gpu/gpu_crash_browsertest.cc | 4 | ||||
-rw-r--r-- | content/browser/gpu/gpu_data_manager_impl.cc | 4 | ||||
-rw-r--r-- | content/browser/gpu/gpu_data_manager_impl.h | 4 | ||||
-rw-r--r-- | content/browser/gpu/gpu_data_manager_impl_unittest.cc | 6 | ||||
-rw-r--r-- | content/browser/gpu/gpu_memory_test.cc | 6 | ||||
-rw-r--r-- | content/browser/gpu/gpu_pixel_browsertest.cc | 40 | ||||
-rw-r--r-- | content/browser/gpu/gpu_process_host.cc | 4 | ||||
-rw-r--r-- | content/browser/gpu/webgl_conformance_test.cc | 4 |
9 files changed, 37 insertions, 37 deletions
diff --git a/content/browser/gpu/gpu_blacklist_unittest.cc b/content/browser/gpu/gpu_blacklist_unittest.cc index 25c3232..374b23b 100644 --- a/content/browser/gpu/gpu_blacklist_unittest.cc +++ b/content/browser/gpu/gpu_blacklist_unittest.cc @@ -59,7 +59,7 @@ class GpuBlacklistTest : public testing::Test { }; TEST_F(GpuBlacklistTest, CurrentBlacklistValidation) { - FilePath data_file; + base::FilePath data_file; ASSERT_TRUE(PathService::Get(base::DIR_SOURCE_ROOT, &data_file)); data_file = data_file.Append(FILE_PATH_LITERAL("content")) diff --git a/content/browser/gpu/gpu_crash_browsertest.cc b/content/browser/gpu/gpu_crash_browsertest.cc index 23a0cc7..90b1fb3 100644 --- a/content/browser/gpu/gpu_crash_browsertest.cc +++ b/content/browser/gpu/gpu_crash_browsertest.cc @@ -18,11 +18,11 @@ namespace content { class GpuCrashTest : public ContentBrowserTest { protected: virtual void SetUpInProcessBrowserTestFixture() { - FilePath test_dir; + base::FilePath test_dir; ASSERT_TRUE(PathService::Get(DIR_TEST_DATA, &test_dir)); gpu_test_dir_ = test_dir.AppendASCII("gpu"); } - FilePath gpu_test_dir_; + base::FilePath gpu_test_dir_; }; IN_PROC_BROWSER_TEST_F(GpuCrashTest, MANUAL_Kill) { diff --git a/content/browser/gpu/gpu_data_manager_impl.cc b/content/browser/gpu/gpu_data_manager_impl.cc index 7a83afb..a085bc4 100644 --- a/content/browser/gpu/gpu_data_manager_impl.cc +++ b/content/browser/gpu/gpu_data_manager_impl.cc @@ -192,7 +192,7 @@ bool GpuDataManagerImpl::ShouldUseSoftwareRendering() const { return software_rendering_; } -void GpuDataManagerImpl::RegisterSwiftShaderPath(const FilePath& path) { +void GpuDataManagerImpl::RegisterSwiftShaderPath(const base::FilePath& path) { swiftshader_path_ = path; EnableSoftwareRenderingIfNecessary(); } @@ -389,7 +389,7 @@ void GpuDataManagerImpl::AppendGpuCommandLine( std::string use_gl = CommandLine::ForCurrentProcess()->GetSwitchValueASCII(switches::kUseGL); - FilePath swiftshader_path = + base::FilePath swiftshader_path = CommandLine::ForCurrentProcess()->GetSwitchValuePath( switches::kSwiftShaderPath); uint32 flags = GetBlacklistedFeatures(); diff --git a/content/browser/gpu/gpu_data_manager_impl.h b/content/browser/gpu/gpu_data_manager_impl.h index e78eee4..a0853e5 100644 --- a/content/browser/gpu/gpu_data_manager_impl.h +++ b/content/browser/gpu/gpu_data_manager_impl.h @@ -65,7 +65,7 @@ class CONTENT_EXPORT GpuDataManagerImpl virtual bool IsCompleteGpuInfoAvailable() const OVERRIDE; virtual void RequestVideoMemoryUsageStatsUpdate() const OVERRIDE; virtual bool ShouldUseSoftwareRendering() const OVERRIDE; - virtual void RegisterSwiftShaderPath(const FilePath& path) OVERRIDE; + virtual void RegisterSwiftShaderPath(const base::FilePath& path) OVERRIDE; virtual void AddObserver(GpuDataManagerObserver* observer) OVERRIDE; virtual void RemoveObserver(GpuDataManagerObserver* observer) OVERRIDE; virtual void SetWindowCount(uint32 count) OVERRIDE; @@ -237,7 +237,7 @@ class CONTENT_EXPORT GpuDataManagerImpl bool software_rendering_; - FilePath swiftshader_path_; + base::FilePath swiftshader_path_; // Current card force-blacklisted due to GPU crashes, or disabled through // the --disable-gpu commandline switch. diff --git a/content/browser/gpu/gpu_data_manager_impl_unittest.cc b/content/browser/gpu/gpu_data_manager_impl_unittest.cc index ef92de24..678f43c 100644 --- a/content/browser/gpu/gpu_data_manager_impl_unittest.cc +++ b/content/browser/gpu/gpu_data_manager_impl_unittest.cc @@ -219,7 +219,7 @@ TEST_F(GpuDataManagerImplTest, SoftwareRendering) { // If software rendering is enabled, even if we blacklist GPU, // GPU process is still allowed. - const FilePath test_path(FILE_PATH_LITERAL("AnyPath")); + const base::FilePath test_path(FILE_PATH_LITERAL("AnyPath")); manager->RegisterSwiftShaderPath(test_path); EXPECT_TRUE(manager->ShouldUseSoftwareRendering()); EXPECT_TRUE(manager->GpuAccessAllowed()); @@ -235,7 +235,7 @@ TEST_F(GpuDataManagerImplTest, SoftwareRendering2) { EXPECT_TRUE(manager->GpuAccessAllowed()); EXPECT_FALSE(manager->ShouldUseSoftwareRendering()); - const FilePath test_path(FILE_PATH_LITERAL("AnyPath")); + const base::FilePath test_path(FILE_PATH_LITERAL("AnyPath")); manager->RegisterSwiftShaderPath(test_path); EXPECT_EQ(0, manager->GetBlacklistedFeatures()); EXPECT_TRUE(manager->GpuAccessAllowed()); @@ -275,7 +275,7 @@ TEST_F(GpuDataManagerImplTest, NoGpuInfoUpdateWithSoftwareRendering) { ASSERT_TRUE(manager.get()); manager->BlacklistCard(); - const FilePath test_path(FILE_PATH_LITERAL("AnyPath")); + const base::FilePath test_path(FILE_PATH_LITERAL("AnyPath")); manager->RegisterSwiftShaderPath(test_path); EXPECT_TRUE(manager->ShouldUseSoftwareRendering()); EXPECT_TRUE(manager->GpuAccessAllowed()); diff --git a/content/browser/gpu/gpu_memory_test.cc b/content/browser/gpu/gpu_memory_test.cc index fc62846..00f7331 100644 --- a/content/browser/gpu/gpu_memory_test.cc +++ b/content/browser/gpu/gpu_memory_test.cc @@ -74,7 +74,7 @@ class GpuMemoryTest : public content::ContentBrowserTest { } virtual void SetUpInProcessBrowserTestFixture() { - FilePath test_dir; + base::FilePath test_dir; ASSERT_TRUE(PathService::Get(content::DIR_TEST_DATA, &test_dir)); gpu_test_dir_ = test_dir.AppendASCII("gpu"); } @@ -105,7 +105,7 @@ class GpuMemoryTest : public content::ContentBrowserTest { void LoadPage(content::Shell* tab_to_load, PageType page_type, size_t mb_to_use) { - FilePath url; + base::FilePath url; switch (page_type) { case PAGE_CSS3D: url = gpu_test_dir_.AppendASCII("mem_css3d.html"); @@ -226,7 +226,7 @@ class GpuMemoryTest : public content::ContentBrowserTest { std::set<content::Shell*> tabs_; std::set<content::Shell*> visible_tabs_; bool has_used_first_shell_; - FilePath gpu_test_dir_; + base::FilePath gpu_test_dir_; }; // When trying to load something that doesn't fit into our total GPU memory diff --git a/content/browser/gpu/gpu_pixel_browsertest.cc b/content/browser/gpu/gpu_pixel_browsertest.cc index 9dd36d5..49aa9a8 100644 --- a/content/browser/gpu/gpu_pixel_browsertest.cc +++ b/content/browser/gpu/gpu_pixel_browsertest.cc @@ -52,9 +52,9 @@ const char kBuildRevision[] = "build-revision"; // Reads and decodes a PNG image to a bitmap. Returns true on success. The PNG // should have been encoded using |gfx::PNGCodec::Encode|. -bool ReadPNGFile(const FilePath& file_path, SkBitmap* bitmap) { +bool ReadPNGFile(const base::FilePath& file_path, SkBitmap* bitmap) { DCHECK(bitmap); - FilePath abs_path(file_path); + base::FilePath abs_path(file_path); if (!file_util::AbsolutePath(&abs_path)) return false; @@ -67,7 +67,7 @@ bool ReadPNGFile(const FilePath& file_path, SkBitmap* bitmap) { // Encodes a bitmap into a PNG and write to disk. Returns true on success. The // parent directory does not have to exist. -bool WritePNGFile(const SkBitmap& bitmap, const FilePath& file_path) { +bool WritePNGFile(const SkBitmap& bitmap, const base::FilePath& file_path) { std::vector<unsigned char> png_data; if (gfx::PNGCodec::EncodeBGRASkBitmap(bitmap, true, &png_data) && file_util::CreateDirectory(file_path.DirName())) { @@ -81,7 +81,7 @@ bool WritePNGFile(const SkBitmap& bitmap, const FilePath& file_path) { // Write an empty file, whose name indicates the chrome revision when the ref // image was generated. -bool WriteREVFile(const FilePath& file_path) { +bool WriteREVFile(const base::FilePath& file_path) { if (file_util::CreateDirectory(file_path.DirName())) { char one_byte = 0; int bytes_written = file_util::WriteFile(file_path, &one_byte, 1); @@ -156,7 +156,7 @@ class GpuPixelBrowserTest : public ContentBrowserTest { // If the existing ref image was saved from an revision older than the // ref_img_update_revision, refresh the ref image. void RunPixelTest(const gfx::Size& tab_container_size, - const FilePath& url, + const base::FilePath& url, int64 ref_img_update_revision, const ReferencePixel* ref_pixels, size_t ref_pixel_count) { @@ -183,14 +183,14 @@ class GpuPixelBrowserTest : public ContentBrowserTest { EXPECT_TRUE(same_pixels); } - const FilePath& test_data_dir() const { + const base::FilePath& test_data_dir() const { return test_data_dir_; } private: - FilePath test_data_dir_; - FilePath generated_img_dir_; - FilePath ref_img_dir_; + base::FilePath test_data_dir_; + base::FilePath generated_img_dir_; + base::FilePath ref_img_dir_; int64 ref_img_revision_; std::string build_revision_; // The name of the test, with any special prefixes dropped. @@ -221,7 +221,7 @@ class GpuPixelBrowserTest : public ContentBrowserTest { bool CompareImages(const SkBitmap& gen_bmp) { SkBitmap ref_bmp_on_disk; - FilePath img_path = ref_img_dir_.AppendASCII(test_name_ + ".png"); + base::FilePath img_path = ref_img_dir_.AppendASCII(test_name_ + ".png"); bool found_ref_img = ReadPNGFile(img_path, &ref_bmp_on_disk); if (!found_ref_img && ref_img_option_ == kReferenceImageCheckedIn) { @@ -238,7 +238,7 @@ class GpuPixelBrowserTest : public ContentBrowserTest { if ((ref_img_revision_ <= 0 && ref_img_option_ == kReferenceImageLocal) || !found_ref_img) { - FilePath rev_path = ref_img_dir_.AppendASCII( + base::FilePath rev_path = ref_img_dir_.AppendASCII( test_name_ + "_" + build_revision_ + ".rev"); if (!WritePNGFile(gen_bmp, img_path)) { LOG(ERROR) << "Can't save generated image to: " @@ -321,7 +321,7 @@ class GpuPixelBrowserTest : public ContentBrowserTest { std::string ref_img_filename = img_path.BaseName().MaybeAsASCII(); if (save_gen) { - FilePath img_fail_path = generated_img_dir_.AppendASCII( + base::FilePath img_fail_path = generated_img_dir_.AppendASCII( "FAIL_" + ref_img_filename); if (!WritePNGFile(gen_bmp, img_fail_path)) { LOG(ERROR) << "Can't save generated image to: " @@ -332,7 +332,7 @@ class GpuPixelBrowserTest : public ContentBrowserTest { } } if (save_diff) { - FilePath img_diff_path = generated_img_dir_.AppendASCII( + base::FilePath img_diff_path = generated_img_dir_.AppendASCII( "DIFF_" + ref_img_filename); if (!WritePNGFile(diff_bmp, img_diff_path)) { LOG(ERROR) << "Can't save generated diff image to: " @@ -396,15 +396,15 @@ class GpuPixelBrowserTest : public ContentBrowserTest { // If no valid local revision file is located, the ref_img_revision_ is 0. void ObtainLocalRefImageRevision() { - FilePath filter; + base::FilePath filter; filter = filter.AppendASCII(test_name_ + "_*.rev"); file_util::FileEnumerator locator(ref_img_dir_, false, // non recursive file_util::FileEnumerator::FILES, filter.value()); int64 max_revision = 0; - std::vector<FilePath> outdated_revs; - for (FilePath full_path = locator.Next(); + std::vector<base::FilePath> outdated_revs; + for (base::FilePath full_path = locator.Next(); !full_path.empty(); full_path = locator.Next()) { std::string filename = @@ -447,7 +447,7 @@ IN_PROC_BROWSER_TEST_F(GpuPixelBrowserTest, MANUAL_WebGLGreenTriangle) { const size_t ref_pixel_count = sizeof(ref_pixels) / sizeof(ReferencePixel); gfx::Size container_size(400, 300); - FilePath url = + base::FilePath url = test_data_dir().AppendASCII("pixel_webgl.html"); RunPixelTest(container_size, url, ref_img_revision_update, ref_pixels, ref_pixel_count); @@ -470,7 +470,7 @@ IN_PROC_BROWSER_TEST_F(GpuPixelBrowserTest, MANUAL_CSS3DBlueBox) { const size_t ref_pixel_count = sizeof(ref_pixels) / sizeof(ReferencePixel); gfx::Size container_size(400, 300); - FilePath url = + base::FilePath url = test_data_dir().AppendASCII("pixel_css3d.html"); RunPixelTest(container_size, url, ref_img_revision_update, ref_pixels, ref_pixel_count); @@ -491,7 +491,7 @@ IN_PROC_BROWSER_TEST_F(GpuPixelBrowserTest, MANUAL_Canvas2DRedBoxHD) { const size_t ref_pixel_count = sizeof(ref_pixels) / sizeof(ReferencePixel); gfx::Size container_size(400, 300); - FilePath url = + base::FilePath url = test_data_dir().AppendASCII("pixel_canvas2d.html"); RunPixelTest(container_size, url, ref_img_revision_update, ref_pixels, ref_pixel_count); @@ -520,7 +520,7 @@ IN_PROC_BROWSER_TEST_F(GpuPixelTestCanvas2DSD, MANUAL_Canvas2DRedBoxSD) { const size_t ref_pixel_count = sizeof(ref_pixels) / sizeof(ReferencePixel); gfx::Size container_size(400, 300); - FilePath url = + base::FilePath url = test_data_dir().AppendASCII("pixel_canvas2d.html"); RunPixelTest(container_size, url, ref_img_revision_update, ref_pixels, ref_pixel_count); diff --git a/content/browser/gpu/gpu_process_host.cc b/content/browser/gpu/gpu_process_host.cc index 5a6969a..4b6e5dd 100644 --- a/content/browser/gpu/gpu_process_host.cc +++ b/content/browser/gpu/gpu_process_host.cc @@ -959,7 +959,7 @@ bool GpuProcessHost::LaunchGpuProcess(const std::string& channel_id) { int child_flags = ChildProcessHost::CHILD_NORMAL; #endif - FilePath exe_path = ChildProcessHost::GetChildPath(child_flags); + base::FilePath exe_path = ChildProcessHost::GetChildPath(child_flags); if (exe_path.empty()) return false; @@ -1032,7 +1032,7 @@ bool GpuProcessHost::LaunchGpuProcess(const std::string& channel_id) { process_->Launch( #if defined(OS_WIN) - FilePath(), + base::FilePath(), #elif defined(OS_POSIX) false, base::EnvironmentVector(), diff --git a/content/browser/gpu/webgl_conformance_test.cc b/content/browser/gpu/webgl_conformance_test.cc index 1e54f14..bf69f1f 100644 --- a/content/browser/gpu/webgl_conformance_test.cc +++ b/content/browser/gpu/webgl_conformance_test.cc @@ -29,7 +29,7 @@ class WebGLConformanceTest : public ContentBrowserTest { } virtual void SetUpInProcessBrowserTestFixture() { - FilePath webgl_conformance_path; + base::FilePath webgl_conformance_path; PathService::Get(base::DIR_SOURCE_ROOT, &webgl_conformance_path); webgl_conformance_path = webgl_conformance_path.Append( FILE_PATH_LITERAL("third_party")); @@ -74,7 +74,7 @@ class WebGLConformanceTest : public ContentBrowserTest { } private: - FilePath test_path_; + base::FilePath test_path_; GPUTestBotConfig bot_config_; GPUTestExpectationsParser test_expectations_; }; |