From 4ca3ebfee3d51f2921e170868c1fe3d8b6fe69b9 Mon Sep 17 00:00:00 2001
From: "bradnelson@google.com"
 <bradnelson@google.com@0039d316-1c4b-4281-b951-d872f2087c98>
Date: Mon, 30 Mar 2009 04:27:26 +0000
Subject: [PATCH] Switching media to gyp under windows.

Review URL: http://codereview.chromium.org/57002

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@12761 0039d316-1c4b-4281-b951-d872f2087c98
---
 build/all.gyp                      |   2 +-
 chrome/chrome.sln                  |   4 +-
 media/build/media.vcproj           | 331 -----------------------------
 media/build/media_player.vcproj    | 153 -------------
 media/build/media_unittests.vcproj | 231 --------------------
 media/media.gyp                    |  68 +++++-
 media/media.sln                    | 103 ---------
 7 files changed, 66 insertions(+), 826 deletions(-)
 delete mode 100644 media/build/media.vcproj
 delete mode 100644 media/build/media_player.vcproj
 delete mode 100644 media/build/media_unittests.vcproj
 delete mode 100644 media/media.sln

diff --git a/build/all.gyp b/build/all.gyp
index c50921f08bb63..7c3f54bc2af71 100644
--- a/build/all.gyp
+++ b/build/all.gyp
@@ -23,6 +23,7 @@
       'dependencies': [
         '../base/base.gyp:*',
         '../net/net.gyp:*',
+        '../media/media.gyp:*',
       ],
       'conditions': [
         ['OS=="linux"', {
@@ -38,7 +39,6 @@
         ['all_gyps', {
           'dependencies': [
             '../chrome/chrome.gyp:*',
-            '../media/media.gyp:*',
             '../printing/printing.gyp:*',
             '../sdch/sdch.gyp:*',
             '../skia/skia.gyp:*',
diff --git a/chrome/chrome.sln b/chrome/chrome.sln
index 7655009bfe636..e2838a4ed2b29 100644
--- a/chrome/chrome.sln
+++ b/chrome/chrome.sln
@@ -587,12 +587,12 @@ Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "net_perftests", "..\net\net
 		{F54ABC59-5C00-414A-A9BA-BAF26D1699F0} = {F54ABC59-5C00-414A-A9BA-BAF26D1699F0}
 	EndProjectSection
 EndProject
-Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "media", "..\media\build\media.vcproj", "{6AE76406-B03B-11DD-94B1-80B556D89593}"
+Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "media", "..\media\media.vcproj", "{6AE76406-B03B-11DD-94B1-80B556D89593}"
 	ProjectSection(ProjectDependencies) = postProject
 		{D7A94F58-576A-45D9-A45F-EB87C63ABBB0} = {D7A94F58-576A-45D9-A45F-EB87C63ABBB0}
 	EndProjectSection
 EndProject
-Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "media_unittests", "..\media\build\media_unittests.vcproj", "{C8C6183C-B03C-11DD-B471-DFD256D89593}"
+Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "media_unittests", "..\media\media_unittests.vcproj", "{C8C6183C-B03C-11DD-B471-DFD256D89593}"
 	ProjectSection(ProjectDependencies) = postProject
 		{1832A374-8A74-4F9E-B536-69A699B3E165} = {1832A374-8A74-4F9E-B536-69A699B3E165}
 		{6AE76406-B03B-11DD-94B1-80B556D89593} = {6AE76406-B03B-11DD-94B1-80B556D89593}
diff --git a/media/build/media.vcproj b/media/build/media.vcproj
deleted file mode 100644
index fb48e7d4fbf82..0000000000000
--- a/media/build/media.vcproj
+++ /dev/null
@@ -1,331 +0,0 @@
-<?xml version="1.0" encoding="Windows-1252"?>
-<VisualStudioProject
-	ProjectType="Visual C++"
-	Version="8.00"
-	Name="media"
-	ProjectGUID="{6AE76406-B03B-11DD-94B1-80B556D89593}"
-	RootNamespace="media"
-	Keyword="Win32Proj"
-	>
-	<Platforms>
-		<Platform
-			Name="Win32"
-		/>
-	</Platforms>
-	<ToolFiles>
-	</ToolFiles>
-	<Configurations>
-		<Configuration
-			Name="Debug|Win32"
-			ConfigurationType="4"
-			InheritedPropertySheets="$(SolutionDir)..\build\debug.vsprops;$(SolutionDir)..\third_party\ffmpeg\using_ffmpeg.vsprops"
-			>
-			<Tool
-				Name="VCPreBuildEventTool"
-			/>
-			<Tool
-				Name="VCCustomBuildTool"
-			/>
-			<Tool
-				Name="VCXMLDataGeneratorTool"
-			/>
-			<Tool
-				Name="VCWebServiceProxyGeneratorTool"
-			/>
-			<Tool
-				Name="VCMIDLTool"
-			/>
-			<Tool
-				Name="VCCLCompilerTool"
-			/>
-			<Tool
-				Name="VCManagedResourceCompilerTool"
-			/>
-			<Tool
-				Name="VCResourceCompilerTool"
-			/>
-			<Tool
-				Name="VCPreLinkEventTool"
-			/>
-			<Tool
-				Name="VCLibrarianTool"
-			/>
-			<Tool
-				Name="VCALinkTool"
-			/>
-			<Tool
-				Name="VCXDCMakeTool"
-			/>
-			<Tool
-				Name="VCBscMakeTool"
-			/>
-			<Tool
-				Name="VCFxCopTool"
-			/>
-			<Tool
-				Name="VCPostBuildEventTool"
-			/>
-		</Configuration>
-		<Configuration
-			Name="Release|Win32"
-			ConfigurationType="4"
-			InheritedPropertySheets="$(SolutionDir)..\build\release.vsprops;$(SolutionDir)..\third_party\ffmpeg\using_ffmpeg.vsprops"
-			>
-			<Tool
-				Name="VCPreBuildEventTool"
-			/>
-			<Tool
-				Name="VCCustomBuildTool"
-			/>
-			<Tool
-				Name="VCXMLDataGeneratorTool"
-			/>
-			<Tool
-				Name="VCWebServiceProxyGeneratorTool"
-			/>
-			<Tool
-				Name="VCMIDLTool"
-			/>
-			<Tool
-				Name="VCCLCompilerTool"
-			/>
-			<Tool
-				Name="VCManagedResourceCompilerTool"
-			/>
-			<Tool
-				Name="VCResourceCompilerTool"
-			/>
-			<Tool
-				Name="VCPreLinkEventTool"
-			/>
-			<Tool
-				Name="VCLibrarianTool"
-			/>
-			<Tool
-				Name="VCALinkTool"
-			/>
-			<Tool
-				Name="VCXDCMakeTool"
-			/>
-			<Tool
-				Name="VCBscMakeTool"
-			/>
-			<Tool
-				Name="VCFxCopTool"
-			/>
-			<Tool
-				Name="VCPostBuildEventTool"
-			/>
-		</Configuration>
-	</Configurations>
-	<References>
-	</References>
-	<Files>
-		<Filter
-			Name="base"
-			>
-			<File
-				RelativePath="..\base\buffers.h"
-				>
-			</File>
-			<File
-				RelativePath="..\base\data_buffer.cc"
-				>
-			</File>
-			<File
-				RelativePath="..\base\data_buffer.h"
-				>
-			</File>
-			<File
-				RelativePath="..\base\factory.h"
-				>
-			</File>
-			<File
-				RelativePath="..\base\filter_host.h"
-				>
-			</File>
-			<File
-				RelativePath="..\base\filter_host_impl.cc"
-				>
-			</File>
-			<File
-				RelativePath="..\base\filter_host_impl.h"
-				>
-			</File>
-			<File
-				RelativePath="..\base\filters.h"
-				>
-			</File>
-			<File
-				RelativePath="..\base\media_format.cc"
-				>
-			</File>
-			<File
-				RelativePath="..\base\media_format.h"
-				>
-			</File>
-			<File
-				RelativePath="..\base\pipeline.h"
-				>
-			</File>
-			<File
-				RelativePath="..\base\pipeline_impl.cc"
-				>
-			</File>
-			<File
-				RelativePath="..\base\pipeline_impl.h"
-				>
-			</File>
-			<File
-				RelativePath="..\base\synchronizer.cc"
-				>
-			</File>
-			<File
-				RelativePath="..\base\synchronizer.h"
-				>
-			</File>
-			<File
-				RelativePath="..\base\video_frame_impl.cc"
-				>
-			</File>
-			<File
-				RelativePath="..\base\video_frame_impl.h"
-				>
-			</File>
-			<File
-				RelativePath="..\base\yuv_convert.cc"
-				>
-			</File>
-			<File
-				RelativePath="..\base\yuv_convert.h"
-				>
-			</File>
-		</Filter>
-		<Filter
-			Name="filters"
-			>
-			<File
-				RelativePath="..\filters\audio_renderer_base.cc"
-				>
-			</File>
-			<File
-				RelativePath="..\filters\audio_renderer_base.h"
-				>
-			</File>
-			<File
-				RelativePath="..\filters\audio_renderer_impl.cc"
-				>
-			</File>
-			<File
-				RelativePath="..\filters\audio_renderer_impl.h"
-				>
-			</File>
-			<File
-				RelativePath="..\filters\decoder_base.h"
-				>
-			</File>
-			<File
-				RelativePath="..\filters\ffmpeg_audio_decoder.cc"
-				>
-			</File>
-			<File
-				RelativePath="..\filters\ffmpeg_audio_decoder.h"
-				>
-			</File>
-			<File
-				RelativePath="..\filters\ffmpeg_common.cc"
-				>
-			</File>
-			<File
-				RelativePath="..\filters\ffmpeg_common.h"
-				>
-			</File>
-			<File
-				RelativePath="..\filters\ffmpeg_demuxer.cc"
-				>
-			</File>
-			<File
-				RelativePath="..\filters\ffmpeg_demuxer.h"
-				>
-			</File>
-			<File
-				RelativePath="..\filters\ffmpeg_glue.cc"
-				>
-			</File>
-			<File
-				RelativePath="..\filters\ffmpeg_glue.h"
-				>
-			</File>
-			<File
-				RelativePath="..\filters\ffmpeg_video_decoder.cc"
-				>
-			</File>
-			<File
-				RelativePath="..\filters\ffmpeg_video_decoder.h"
-				>
-			</File>
-			<File
-				RelativePath="..\filters\file_data_source.cc"
-				>
-			</File>
-			<File
-				RelativePath="..\filters\file_data_source.h"
-				>
-			</File>
-			<File
-				RelativePath="..\filters\null_audio_renderer.cc"
-				>
-			</File>
-			<File
-				RelativePath="..\filters\null_audio_renderer.h"
-				>
-			</File>
-			<File
-				RelativePath="..\filters\test_video_decoder.h"
-				>
-			</File>
-			<File
-				RelativePath="..\filters\video_renderer_base.cc"
-				>
-			</File>
-			<File
-				RelativePath="..\filters\video_renderer_base.h"
-				>
-			</File>
-		</Filter>
-		<Filter
-			Name="audio"
-			>
-			<File
-				RelativePath="..\audio\win\audio_manager_win.h"
-				>
-			</File>
-			<File
-				RelativePath="..\audio\audio_output.h"
-				>
-			</File>
-			<File
-				RelativePath="..\audio\win\audio_output_win.cc"
-				>
-			</File>
-			<File
-				RelativePath="..\audio\simple_sources.h"
-				>
-			</File>
-			<File
-				RelativePath="..\audio\win\simple_sources_win.cc"
-				>
-			</File>
-			<File
-				RelativePath="..\audio\win\waveout_output_win.cc"
-				>
-			</File>
-			<File
-				RelativePath="..\audio\win\waveout_output_win.h"
-				>
-			</File>
-		</Filter>
-	</Files>
-	<Globals>
-	</Globals>
-</VisualStudioProject>
diff --git a/media/build/media_player.vcproj b/media/build/media_player.vcproj
deleted file mode 100644
index e0a19c62ac3d4..0000000000000
--- a/media/build/media_player.vcproj
+++ /dev/null
@@ -1,153 +0,0 @@
-<?xml version="1.0" encoding="Windows-1252"?>
-<VisualStudioProject
-	ProjectType="Visual C++"
-	Version="8.00"
-	Name="media_player"
-	ProjectGUID="{D4EB0EDC-DC4D-11DD-AE66-DC4F55D89593}"
-	RootNamespace="media_player"
-	Keyword="Win32Proj"
-	>
-	<Platforms>
-		<Platform
-			Name="Win32"
-		/>
-	</Platforms>
-	<ToolFiles>
-	</ToolFiles>
-	<Configurations>
-		<Configuration
-			Name="Debug|Win32"
-			ConfigurationType="1"
-			InheritedPropertySheets="$(SolutionDir)..\build\debug.vsprops"
-			>
-			<Tool
-				Name="VCPreBuildEventTool"
-			/>
-			<Tool
-				Name="VCCustomBuildTool"
-			/>
-			<Tool
-				Name="VCXMLDataGeneratorTool"
-			/>
-			<Tool
-				Name="VCWebServiceProxyGeneratorTool"
-			/>
-			<Tool
-				Name="VCMIDLTool"
-			/>
-			<Tool
-				Name="VCCLCompilerTool"
-			/>
-			<Tool
-				Name="VCManagedResourceCompilerTool"
-			/>
-			<Tool
-				Name="VCResourceCompilerTool"
-			/>
-			<Tool
-				Name="VCPreLinkEventTool"
-			/>
-			<Tool
-				Name="VCLinkerTool"
-			/>
-			<Tool
-				Name="VCALinkTool"
-			/>
-			<Tool
-				Name="VCManifestTool"
-			/>
-			<Tool
-				Name="VCXDCMakeTool"
-			/>
-			<Tool
-				Name="VCBscMakeTool"
-			/>
-			<Tool
-				Name="VCFxCopTool"
-			/>
-			<Tool
-				Name="VCAppVerifierTool"
-			/>
-			<Tool
-				Name="VCWebDeploymentTool"
-			/>
-			<Tool
-				Name="VCPostBuildEventTool"
-			/>
-		</Configuration>
-		<Configuration
-			Name="Release|Win32"
-			ConfigurationType="1"
-			InheritedPropertySheets="$(SolutionDir)..\build\release.vsprops"
-			>
-			<Tool
-				Name="VCPreBuildEventTool"
-			/>
-			<Tool
-				Name="VCCustomBuildTool"
-			/>
-			<Tool
-				Name="VCXMLDataGeneratorTool"
-			/>
-			<Tool
-				Name="VCWebServiceProxyGeneratorTool"
-			/>
-			<Tool
-				Name="VCMIDLTool"
-			/>
-			<Tool
-				Name="VCCLCompilerTool"
-			/>
-			<Tool
-				Name="VCManagedResourceCompilerTool"
-			/>
-			<Tool
-				Name="VCResourceCompilerTool"
-			/>
-			<Tool
-				Name="VCPreLinkEventTool"
-			/>
-			<Tool
-				Name="VCLinkerTool"
-			/>
-			<Tool
-				Name="VCALinkTool"
-			/>
-			<Tool
-				Name="VCManifestTool"
-			/>
-			<Tool
-				Name="VCXDCMakeTool"
-			/>
-			<Tool
-				Name="VCBscMakeTool"
-			/>
-			<Tool
-				Name="VCFxCopTool"
-			/>
-			<Tool
-				Name="VCAppVerifierTool"
-			/>
-			<Tool
-				Name="VCWebDeploymentTool"
-			/>
-			<Tool
-				Name="VCPostBuildEventTool"
-			/>
-		</Configuration>
-	</Configurations>
-	<References>
-	</References>
-	<Files>
-		<Filter
-			Name="player"
-			>
-			<File
-				RelativePath="..\player\player.cc"
-				>
-			</File>
-		</Filter>
-	</Files>
-	<Globals>
-	</Globals>
-</VisualStudioProject>
diff --git a/media/build/media_unittests.vcproj b/media/build/media_unittests.vcproj
deleted file mode 100644
index de4d01c752b8d..0000000000000
--- a/media/build/media_unittests.vcproj
+++ /dev/null
@@ -1,231 +0,0 @@
-<?xml version="1.0" encoding="Windows-1252"?>
-<VisualStudioProject
-	ProjectType="Visual C++"
-	Version="8.00"
-	Name="media_unittests"
-	ProjectGUID="{C8C6183C-B03C-11DD-B471-DFD256D89593}"
-	RootNamespace="media_unittests"
-	Keyword="Win32Proj"
-	>
-	<Platforms>
-		<Platform
-			Name="Win32"
-		/>
-	</Platforms>
-	<ToolFiles>
-	</ToolFiles>
-	<Configurations>
-		<Configuration
-			Name="Debug|Win32"
-			ConfigurationType="1"
-			InheritedPropertySheets="$(SolutionDir)..\build\debug.vsprops;$(SolutionDir)..\testing\using_gtest.vsprops;$(SolutionDir)..\third_party\ffmpeg\using_ffmpeg.vsprops"
-			>
-			<Tool
-				Name="VCPreBuildEventTool"
-			/>
-			<Tool
-				Name="VCCustomBuildTool"
-			/>
-			<Tool
-				Name="VCXMLDataGeneratorTool"
-			/>
-			<Tool
-				Name="VCWebServiceProxyGeneratorTool"
-			/>
-			<Tool
-				Name="VCMIDLTool"
-			/>
-			<Tool
-				Name="VCCLCompilerTool"
-				PreprocessorDefinitions="UNIT_TEST"
-			/>
-			<Tool
-				Name="VCManagedResourceCompilerTool"
-			/>
-			<Tool
-				Name="VCResourceCompilerTool"
-			/>
-			<Tool
-				Name="VCPreLinkEventTool"
-			/>
-			<Tool
-				Name="VCLinkerTool"
-			/>
-			<Tool
-				Name="VCALinkTool"
-			/>
-			<Tool
-				Name="VCManifestTool"
-			/>
-			<Tool
-				Name="VCXDCMakeTool"
-			/>
-			<Tool
-				Name="VCBscMakeTool"
-			/>
-			<Tool
-				Name="VCFxCopTool"
-			/>
-			<Tool
-				Name="VCAppVerifierTool"
-			/>
-			<Tool
-				Name="VCWebDeploymentTool"
-			/>
-			<Tool
-				Name="VCPostBuildEventTool"
-			/>
-		</Configuration>
-		<Configuration
-			Name="Release|Win32"
-			ConfigurationType="1"
-			InheritedPropertySheets="$(SolutionDir)..\build\release.vsprops;$(SolutionDir)..\testing\using_gtest.vsprops;$(SolutionDir)..\third_party\ffmpeg\using_ffmpeg.vsprops"
-			>
-			<Tool
-				Name="VCPreBuildEventTool"
-			/>
-			<Tool
-				Name="VCCustomBuildTool"
-			/>
-			<Tool
-				Name="VCXMLDataGeneratorTool"
-			/>
-			<Tool
-				Name="VCWebServiceProxyGeneratorTool"
-			/>
-			<Tool
-				Name="VCMIDLTool"
-			/>
-			<Tool
-				Name="VCCLCompilerTool"
-				PreprocessorDefinitions="UNIT_TEST"
-			/>
-			<Tool
-				Name="VCManagedResourceCompilerTool"
-			/>
-			<Tool
-				Name="VCResourceCompilerTool"
-			/>
-			<Tool
-				Name="VCPreLinkEventTool"
-			/>
-			<Tool
-				Name="VCLinkerTool"
-			/>
-			<Tool
-				Name="VCALinkTool"
-			/>
-			<Tool
-				Name="VCManifestTool"
-			/>
-			<Tool
-				Name="VCXDCMakeTool"
-			/>
-			<Tool
-				Name="VCBscMakeTool"
-			/>
-			<Tool
-				Name="VCFxCopTool"
-			/>
-			<Tool
-				Name="VCAppVerifierTool"
-			/>
-			<Tool
-				Name="VCWebDeploymentTool"
-			/>
-			<Tool
-				Name="VCPostBuildEventTool"
-			/>
-		</Configuration>
-	</Configurations>
-	<References>
-	</References>
-	<Files>
-		<Filter
-			Name="support"
-			>
-			<File
-				RelativePath="..\base\run_all_unittests.cc"
-				>
-			</File>
-		</Filter>
-		<Filter
-			Name="tests"
-			>
-			<Filter
-				Name="base"
-				>
-				<File
-					RelativePath="..\base\data_buffer_unittest.cc"
-					>
-				</File>
-				<File
-					RelativePath="..\base\mock_filter_host.h"
-					>
-				</File>
-				<File
-					RelativePath="..\base\mock_media_filters.h"
-					>
-				</File>
-				<File
-					RelativePath="..\base\mock_pipeline.h"
-					>
-				</File>
-				<File
-					RelativePath="..\base\pipeline_impl_unittest.cc"
-					>
-				</File>
-				<File
-					RelativePath="..\base\video_frame_impl_unittest.cc"
-					>
-				</File>
-				<File
-					RelativePath="..\base\yuv_convert_unittest.cc"
-					>
-				</File>
-			</Filter>
-			<Filter
-				Name="audio"
-				>
-				<File
-					RelativePath="..\audio\win\audio_output_win_unittest.cc"
-					>
-				</File>
-			</Filter>
-			<Filter
-				Name="filters"
-				>
-				<File
-					RelativePath="..\filters\ffmpeg_demuxer_unittest.cc"
-					>
-				</File>
-				<File
-					RelativePath="..\filters\ffmpeg_glue_unittest.cc"
-					>
-				</File>
-				<File
-					RelativePath="..\filters\file_data_source_unittest.cc"
-					>
-				</File>
-				<File
-					RelativePath="..\filters\test_video_decoder.h"
-					>
-				</File>
-				<File
-					RelativePath="..\filters\test_video_renderer.h"
-					>
-				</File>
-				<File
-					RelativePath="..\filters\video_decoder_unittest.cc"
-					>
-				</File>
-				<File
-					RelativePath="..\filters\video_renderer_unittest.cc"
-					>
-				</File>
-			</Filter>
-		</Filter>
-	</Files>
-	<Globals>
-	</Globals>
-</VisualStudioProject>
diff --git a/media/media.gyp b/media/media.gyp
index 66235685db4fa..2790f5bfd8478 100644
--- a/media/media.gyp
+++ b/media/media.gyp
@@ -28,17 +28,17 @@
       ],
       'msvs_guid': '6AE76406-B03B-11DD-94B1-80B556D89593',
       'sources': [
+        'audio/audio_output.h',
         'audio/linux/audio_manager_linux.cc',
         'audio/mac/audio_manager_mac.cc',
-	'audio/mac/audio_output_mac.h',
-	'audio/mac/audio_output_mac.cc',
+        'audio/mac/audio_output_mac.cc',
+        'audio/mac/audio_output_mac.h',
+        'audio/simple_sources.h',
         'audio/win/audio_manager_win.h',
         'audio/win/audio_output_win.cc',
         'audio/win/simple_sources_win.cc',
         'audio/win/waveout_output_win.cc',
         'audio/win/waveout_output_win.h',
-        'audio/audio_output.h',
-        'audio/simple_sources.h',
         'base/buffers.h',
         'base/data_buffer.cc',
         'base/data_buffer.h',
@@ -66,18 +66,35 @@
         'filters/audio_renderer_impl.cc',
         'filters/audio_renderer_impl.h',
         'filters/decoder_base.h',
+        'filters/ffmpeg_audio_decoder.cc',
+        'filters/ffmpeg_audio_decoder.h',
+        'filters/ffmpeg_common.cc',
+        'filters/ffmpeg_common.h',
+        'filters/ffmpeg_demuxer.cc',
+        'filters/ffmpeg_demuxer.h',
+        'filters/ffmpeg_glue.cc',
+        'filters/ffmpeg_glue.h',
+        'filters/ffmpeg_video_decoder.cc',
+        'filters/ffmpeg_video_decoder.h',
+        'filters/file_data_source.cc',
         'filters/file_data_source.cc',
         'filters/file_data_source.h',
-        'filters/test_video_decoder.h',
+        'filters/file_data_source.h',
         'filters/null_audio_renderer.cc',
         'filters/null_audio_renderer.h',
+        'filters/test_video_decoder.h',
+        'filters/test_video_renderer.h',
         'filters/video_renderer_base.cc',
         'filters/video_renderer_base.h',
         'player/player.cc',
       ],
+      'include_dirs': [
+        '../third_party/ffmpeg/include',
+      ],
       'direct_dependent_settings': {
         'include_dirs': [
           '..',
+          '../third_party/ffmpeg/include',
         ],
       },
       'conditions': [
@@ -88,12 +105,28 @@
               '$(SDKROOT)/System/Library/Frameworks/CoreAudio.framework',
             ],
           },
+          'sources!': [
+            'filters/ffmpeg_audio_decoder.cc',
+            'filters/ffmpeg_glue.cc',
+            'filters/ffmpeg_video_decoder.cc',
+          ],
+        }],
+        ['OS =="win"', {
+          'include_dirs': [
+            '../third_party/ffmpeg/include/win',
+          ],
+          'direct_dependent_settings': {
+            'include_dirs': [
+              '../third_party/ffmpeg/include/win',
+            ],
+          },
         }],
       ],
     },
     {
       'target_name': 'media_unittests',
       'type': 'executable',
+      'msvs_guid': 'C8C6183C-B03C-11DD-B471-DFD256D89593',
       'dependencies': [
         'media',
         '../base/base.gyp:base',
@@ -107,6 +140,8 @@
         'base/run_all_unittests.cc',
         'base/video_frame_impl_unittest.cc',
         'base/yuv_convert_unittest.cc',
+        'filters/ffmpeg_demuxer_unittest.cc',
+        'filters/ffmpeg_glue_unittest.cc',
         'filters/file_data_source_unittest.cc',
         'filters/video_decoder_unittest.cc',
         'filters/video_renderer_unittest.cc',
@@ -121,7 +156,30 @@
             '../build/linux/system.gyp:gtk',
           ],
         }],
+        ['OS=="mac"', {
+          'sources!': [
+            'filters/ffmpeg_demuxer_unittest.cc',
+            'filters/ffmpeg_glue_unittest.cc',
+          ],
+        }],
       ],
     },
   ],
+  'conditions': [
+    ['OS=="win"', {
+      'targets': [
+        {
+          'target_name': 'media_player',
+          'type': 'executable',
+          'dependencies': [
+            'media',
+            '../base/base.gyp:base',
+          ],
+          'sources': [
+            'player/player.cc',
+          ],
+        },
+      ],
+    }],
+  ],
 }
diff --git a/media/media.sln b/media/media.sln
deleted file mode 100644
index 14353f6e9bc90..0000000000000
--- a/media/media.sln
+++ /dev/null
@@ -1,103 +0,0 @@
-Microsoft Visual Studio Solution File, Format Version 9.00
-# Visual Studio 2005
-Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "dependencies", "dependencies", "{9D67D7CC-B03F-11DD-86F7-FD7F55D89593}"
-EndProject
-Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "media", "build\media.vcproj", "{6AE76406-B03B-11DD-94B1-80B556D89593}"
-	ProjectSection(ProjectDependencies) = postProject
-		{D7A94F58-576A-45D9-A45F-EB87C63ABBB0} = {D7A94F58-576A-45D9-A45F-EB87C63ABBB0}
-	EndProjectSection
-EndProject
-Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "media_player", "build\media_player.vcproj", "{D4EB0EDC-DC4D-11DD-AE66-DC4F55D89593}"
-	ProjectSection(ProjectDependencies) = postProject
-		{1832A374-8A74-4F9E-B536-69A699B3E165} = {1832A374-8A74-4F9E-B536-69A699B3E165}
-		{6AE76406-B03B-11DD-94B1-80B556D89593} = {6AE76406-B03B-11DD-94B1-80B556D89593}
-	EndProjectSection
-EndProject
-Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "media_unittests", "build\media_unittests.vcproj", "{C8C6183C-B03C-11DD-B471-DFD256D89593}"
-	ProjectSection(ProjectDependencies) = postProject
-		{1832A374-8A74-4F9E-B536-69A699B3E165} = {1832A374-8A74-4F9E-B536-69A699B3E165}
-		{6AE76406-B03B-11DD-94B1-80B556D89593} = {6AE76406-B03B-11DD-94B1-80B556D89593}
-		{BFE8E2A7-3B3B-43B0-A994-3058B852DB8B} = {BFE8E2A7-3B3B-43B0-A994-3058B852DB8B}
-	EndProjectSection
-EndProject
-Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "base", "..\base\base.vcproj", "{1832A374-8A74-4F9E-B536-69A699B3E165}"
-	ProjectSection(ProjectDependencies) = postProject
-		{8C27D792-2648-4F5E-9ED0-374276327308} = {8C27D792-2648-4F5E-9ED0-374276327308}
-	EndProjectSection
-EndProject
-Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "debug_message", "..\base\debug_message.vcproj", "{D6047981-23AE-4623-9373-514FDAFAE60F}"
-EndProject
-Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "gtest", "..\testing\gtest.vcproj", "{BFE8E2A7-3B3B-43B0-A994-3058B852DB8B}"
-EndProject
-Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "icui18n", "..\third_party\icu38\icui18n.vcproj", "{F22022F0-2D3B-5610-4E80-C674A8E01C5A}"
-EndProject
-Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "icuuc", "..\third_party\icu38\icuuc.vcproj", "{8C27D792-2648-4F5E-9ED0-374276327308}"
-	ProjectSection(ProjectDependencies) = postProject
-		{A0D94973-D355-47A5-A1E2-3456F321F010} = {A0D94973-D355-47A5-A1E2-3456F321F010}
-		{F22022F0-2D3B-5610-4E80-C674A8E01C5A} = {F22022F0-2D3B-5610-4E80-C674A8E01C5A}
-	EndProjectSection
-EndProject
-Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "icudata", "..\third_party\icu38\icudata.vcproj", "{A0D94973-D355-47A5-A1E2-3456F321F010}"
-EndProject
-Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "ffmpeg", "..\third_party\ffmpeg\ffmpeg.vcproj", "{D7A94F58-576A-45D9-A45F-EB87C63ABBB0}"
-EndProject
-Global
-	GlobalSection(SolutionConfigurationPlatforms) = preSolution
-		Debug|Win32 = Debug|Win32
-		Release|Win32 = Release|Win32
-	EndGlobalSection
-	GlobalSection(ProjectConfigurationPlatforms) = postSolution
-		{1832A374-8A74-4F9E-B536-69A699B3E165}.Debug|Win32.ActiveCfg = Debug|Win32
-		{1832A374-8A74-4F9E-B536-69A699B3E165}.Debug|Win32.Build.0 = Debug|Win32
-		{1832A374-8A74-4F9E-B536-69A699B3E165}.Release|Win32.ActiveCfg = Release|Win32
-		{1832A374-8A74-4F9E-B536-69A699B3E165}.Release|Win32.Build.0 = Release|Win32
-		{6AE76406-B03B-11DD-94B1-80B556D89593}.Debug|Win32.ActiveCfg = Debug|Win32
-		{6AE76406-B03B-11DD-94B1-80B556D89593}.Debug|Win32.Build.0 = Debug|Win32
-		{6AE76406-B03B-11DD-94B1-80B556D89593}.Release|Win32.ActiveCfg = Release|Win32
-		{6AE76406-B03B-11DD-94B1-80B556D89593}.Release|Win32.Build.0 = Release|Win32
-		{8C27D792-2648-4F5E-9ED0-374276327308}.Debug|Win32.ActiveCfg = Debug|Win32
-		{8C27D792-2648-4F5E-9ED0-374276327308}.Debug|Win32.Build.0 = Debug|Win32
-		{8C27D792-2648-4F5E-9ED0-374276327308}.Release|Win32.ActiveCfg = Release|Win32
-		{8C27D792-2648-4F5E-9ED0-374276327308}.Release|Win32.Build.0 = Release|Win32
-		{A0D94973-D355-47A5-A1E2-3456F321F010}.Debug|Win32.ActiveCfg = Debug|Win32
-		{A0D94973-D355-47A5-A1E2-3456F321F010}.Debug|Win32.Build.0 = Debug|Win32
-		{A0D94973-D355-47A5-A1E2-3456F321F010}.Release|Win32.ActiveCfg = Release|Win32
-		{A0D94973-D355-47A5-A1E2-3456F321F010}.Release|Win32.Build.0 = Release|Win32
-		{BFE8E2A7-3B3B-43B0-A994-3058B852DB8B}.Debug|Win32.ActiveCfg = Debug|Win32
-		{BFE8E2A7-3B3B-43B0-A994-3058B852DB8B}.Debug|Win32.Build.0 = Debug|Win32
-		{BFE8E2A7-3B3B-43B0-A994-3058B852DB8B}.Release|Win32.ActiveCfg = Release|Win32
-		{BFE8E2A7-3B3B-43B0-A994-3058B852DB8B}.Release|Win32.Build.0 = Release|Win32
-		{C8C6183C-B03C-11DD-B471-DFD256D89593}.Debug|Win32.ActiveCfg = Debug|Win32
-		{C8C6183C-B03C-11DD-B471-DFD256D89593}.Debug|Win32.Build.0 = Debug|Win32
-		{C8C6183C-B03C-11DD-B471-DFD256D89593}.Release|Win32.ActiveCfg = Release|Win32
-		{C8C6183C-B03C-11DD-B471-DFD256D89593}.Release|Win32.Build.0 = Release|Win32
-		{D4EB0EDC-DC4D-11DD-AE66-DC4F55D89593}.Debug|Win32.ActiveCfg = Debug|Win32
-		{D4EB0EDC-DC4D-11DD-AE66-DC4F55D89593}.Debug|Win32.Build.0 = Debug|Win32
-		{D4EB0EDC-DC4D-11DD-AE66-DC4F55D89593}.Release|Win32.ActiveCfg = Release|Win32
-		{D4EB0EDC-DC4D-11DD-AE66-DC4F55D89593}.Release|Win32.Build.0 = Release|Win32
-		{D6047981-23AE-4623-9373-514FDAFAE60F}.Debug|Win32.ActiveCfg = Debug|Win32
-		{D6047981-23AE-4623-9373-514FDAFAE60F}.Debug|Win32.Build.0 = Debug|Win32
-		{D6047981-23AE-4623-9373-514FDAFAE60F}.Release|Win32.ActiveCfg = Release|Win32
-		{D6047981-23AE-4623-9373-514FDAFAE60F}.Release|Win32.Build.0 = Release|Win32
-		{D7A94F58-576A-45D9-A45F-EB87C63ABBB0}.Debug|Win32.ActiveCfg = Debug|Win32
-		{D7A94F58-576A-45D9-A45F-EB87C63ABBB0}.Debug|Win32.Build.0 = Debug|Win32
-		{D7A94F58-576A-45D9-A45F-EB87C63ABBB0}.Release|Win32.ActiveCfg = Release|Win32
-		{D7A94F58-576A-45D9-A45F-EB87C63ABBB0}.Release|Win32.Build.0 = Release|Win32
-		{F22022F0-2D3B-5610-4E80-C674A8E01C5A}.Debug|Win32.ActiveCfg = Debug|Win32
-		{F22022F0-2D3B-5610-4E80-C674A8E01C5A}.Debug|Win32.Build.0 = Debug|Win32
-		{F22022F0-2D3B-5610-4E80-C674A8E01C5A}.Release|Win32.ActiveCfg = Release|Win32
-		{F22022F0-2D3B-5610-4E80-C674A8E01C5A}.Release|Win32.Build.0 = Release|Win32
-	EndGlobalSection
-	GlobalSection(SolutionProperties) = preSolution
-		HideSolutionNode = FALSE
-	EndGlobalSection
-	GlobalSection(NestedProjects) = preSolution
-		{1832A374-8A74-4F9E-B536-69A699B3E165} = {9D67D7CC-B03F-11DD-86F7-FD7F55D89593}
-		{8C27D792-2648-4F5E-9ED0-374276327308} = {9D67D7CC-B03F-11DD-86F7-FD7F55D89593}
-		{A0D94973-D355-47A5-A1E2-3456F321F010} = {9D67D7CC-B03F-11DD-86F7-FD7F55D89593}
-		{BFE8E2A7-3B3B-43B0-A994-3058B852DB8B} = {9D67D7CC-B03F-11DD-86F7-FD7F55D89593}
-		{D6047981-23AE-4623-9373-514FDAFAE60F} = {9D67D7CC-B03F-11DD-86F7-FD7F55D89593}
-		{D7A94F58-576A-45D9-A45F-EB87C63ABBB0} = {9D67D7CC-B03F-11DD-86F7-FD7F55D89593}
-		{F22022F0-2D3B-5610-4E80-C674A8E01C5A} = {9D67D7CC-B03F-11DD-86F7-FD7F55D89593}
-	EndGlobalSection
-EndGlobal
-- 
GitLab