Index: /dsfilters/before-you-ask.txt
===================================================================
--- /dsfilters/before-you-ask.txt	(revision 368)
+++ /dsfilters/before-you-ask.txt	(revision 369)
@@ -9,5 +9,11 @@
 In time I'll try to get a VC++ 2003 and build.
 
-Right now the only working filter is the demux_mpc.
+
+Recently I've added basic stuff for decoder filter.
+Right now it can not even be created so don't even
+try to register it or you'll get errors.
+I'll update it soon.
+
+Demux MPC works quite fine.
 It parses input file, extracts decoder specific information
 and outputs AP packets with proper timestamps. 
Index: /dsfilters/dec_mpc/dec_mpc.def
===================================================================
--- /dsfilters/dec_mpc/dec_mpc.def	(revision 369)
+++ /dsfilters/dec_mpc/dec_mpc.def	(revision 369)
@@ -0,0 +1,6 @@
+LIBRARY         mmmpcdec.ax
+EXPORTS
+	DllGetClassObject		PRIVATE
+	DllCanUnloadNow			PRIVATE
+	DllRegisterServer		PRIVATE
+	DllUnregisterServer		PRIVATE
Index: /dsfilters/dec_mpc/dec_mpc.sln
===================================================================
--- /dsfilters/dec_mpc/dec_mpc.sln	(revision 369)
+++ /dsfilters/dec_mpc/dec_mpc.sln	(revision 369)
@@ -0,0 +1,20 @@
+﻿
+Microsoft Visual Studio Solution File, Format Version 9.00
+# Visual Studio 2005
+Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "dec_mpc", "dec_mpc.vcproj", "{D9BE0605-05BF-44FA-B17F-6C501DD7E770}"
+EndProject
+Global
+	GlobalSection(SolutionConfigurationPlatforms) = preSolution
+		Debug|Win32 = Debug|Win32
+		Release|Win32 = Release|Win32
+	EndGlobalSection
+	GlobalSection(ProjectConfigurationPlatforms) = postSolution
+		{D9BE0605-05BF-44FA-B17F-6C501DD7E770}.Debug|Win32.ActiveCfg = Debug|Win32
+		{D9BE0605-05BF-44FA-B17F-6C501DD7E770}.Debug|Win32.Build.0 = Debug|Win32
+		{D9BE0605-05BF-44FA-B17F-6C501DD7E770}.Release|Win32.ActiveCfg = Release|Win32
+		{D9BE0605-05BF-44FA-B17F-6C501DD7E770}.Release|Win32.Build.0 = Release|Win32
+	EndGlobalSection
+	GlobalSection(SolutionProperties) = preSolution
+		HideSolutionNode = FALSE
+	EndGlobalSection
+EndGlobal
Index: /dsfilters/dec_mpc/dec_mpc.vcproj
===================================================================
--- /dsfilters/dec_mpc/dec_mpc.vcproj	(revision 369)
+++ /dsfilters/dec_mpc/dec_mpc.vcproj	(revision 369)
@@ -0,0 +1,221 @@
+<?xml version="1.0" encoding="windows-1250"?>
+<VisualStudioProject
+	ProjectType="Visual C++"
+	Version="8,00"
+	Name="dec_mpc"
+	ProjectGUID="{D9BE0605-05BF-44FA-B17F-6C501DD7E770}"
+	RootNamespace="dec_mpc"
+	Keyword="Win32Proj"
+	>
+	<Platforms>
+		<Platform
+			Name="Win32"
+		/>
+	</Platforms>
+	<ToolFiles>
+	</ToolFiles>
+	<Configurations>
+		<Configuration
+			Name="Debug|Win32"
+			OutputDirectory="$(SolutionDir)$(ConfigurationName)"
+			IntermediateDirectory="$(ConfigurationName)"
+			ConfigurationType="2"
+			UseOfMFC="2"
+			CharacterSet="1"
+			>
+			<Tool
+				Name="VCPreBuildEventTool"
+			/>
+			<Tool
+				Name="VCCustomBuildTool"
+			/>
+			<Tool
+				Name="VCXMLDataGeneratorTool"
+			/>
+			<Tool
+				Name="VCWebServiceProxyGeneratorTool"
+			/>
+			<Tool
+				Name="VCMIDLTool"
+			/>
+			<Tool
+				Name="VCCLCompilerTool"
+				Optimization="0"
+				AdditionalIncludeDirectories=".\src"
+				PreprocessorDefinitions="WIN32;_DEBUG;_WINDOWS;_USRDLL;DEC_MPC_EXPORTS"
+				MinimalRebuild="true"
+				BasicRuntimeChecks="3"
+				RuntimeLibrary="3"
+				UsePrecompiledHeader="0"
+				WarningLevel="3"
+				Detect64BitPortabilityProblems="true"
+				DebugInformationFormat="4"
+			/>
+			<Tool
+				Name="VCManagedResourceCompilerTool"
+			/>
+			<Tool
+				Name="VCResourceCompilerTool"
+			/>
+			<Tool
+				Name="VCPreLinkEventTool"
+			/>
+			<Tool
+				Name="VCLinkerTool"
+				AdditionalDependencies="strmbasdu.lib strmiids.lib winmm.lib"
+				OutputFile=".\bin\mmmpcdecd.ax"
+				LinkIncremental="2"
+				ModuleDefinitionFile="dec_mpc.def"
+				GenerateDebugInformation="true"
+				SubSystem="2"
+				EntryPointSymbol="DllEntryPoint@12"
+				TargetMachine="1"
+			/>
+			<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"
+			OutputDirectory="$(SolutionDir)$(ConfigurationName)"
+			IntermediateDirectory="$(ConfigurationName)"
+			ConfigurationType="2"
+			UseOfMFC="2"
+			CharacterSet="1"
+			WholeProgramOptimization="1"
+			>
+			<Tool
+				Name="VCPreBuildEventTool"
+			/>
+			<Tool
+				Name="VCCustomBuildTool"
+			/>
+			<Tool
+				Name="VCXMLDataGeneratorTool"
+			/>
+			<Tool
+				Name="VCWebServiceProxyGeneratorTool"
+			/>
+			<Tool
+				Name="VCMIDLTool"
+			/>
+			<Tool
+				Name="VCCLCompilerTool"
+				AdditionalIncludeDirectories=".\src"
+				PreprocessorDefinitions="WIN32;NDEBUG;_WINDOWS;_USRDLL;DEC_MPC_EXPORTS"
+				RuntimeLibrary="2"
+				UsePrecompiledHeader="0"
+				WarningLevel="3"
+				Detect64BitPortabilityProblems="true"
+				DebugInformationFormat="0"
+			/>
+			<Tool
+				Name="VCManagedResourceCompilerTool"
+			/>
+			<Tool
+				Name="VCResourceCompilerTool"
+			/>
+			<Tool
+				Name="VCPreLinkEventTool"
+			/>
+			<Tool
+				Name="VCLinkerTool"
+				AdditionalDependencies="strmbaseu.lib strmiids.lib winmm.lib"
+				OutputFile=".\bin\mmmpcdec.ax"
+				LinkIncremental="1"
+				ModuleDefinitionFile="dec_mpc.def"
+				GenerateDebugInformation="false"
+				SubSystem="2"
+				OptimizeReferences="2"
+				EnableCOMDATFolding="2"
+				EntryPointSymbol="DllEntryPoint@12"
+				TargetMachine="1"
+			/>
+			<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="Source Files"
+			Filter="cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx"
+			UniqueIdentifier="{4FC737F1-C7A5-4376-A066-2A32D752A2FF}"
+			>
+			<File
+				RelativePath=".\dec_mpc.def"
+				>
+			</File>
+			<File
+				RelativePath=".\src\mpc_reg.cpp"
+				>
+			</File>
+		</Filter>
+		<Filter
+			Name="Header Files"
+			Filter="h;hpp;hxx;hm;inl;inc;xsd"
+			UniqueIdentifier="{93995380-89BD-4b04-88EB-625FBE52EBFB}"
+			>
+			<File
+				RelativePath=".\src\mpc_types.h"
+				>
+			</File>
+			<File
+				RelativePath=".\src\stdafx.h"
+				>
+			</File>
+		</Filter>
+		<Filter
+			Name="Resource Files"
+			Filter="rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx;tiff;tif;png;wav"
+			UniqueIdentifier="{67DA6AB6-F800-4c08-8B7A-83BB121AAD01}"
+			>
+		</Filter>
+	</Files>
+	<Globals>
+	</Globals>
+</VisualStudioProject>
Index: /dsfilters/dec_mpc/src/mpc_reg.cpp
===================================================================
--- /dsfilters/dec_mpc/src/mpc_reg.cpp	(revision 369)
+++ /dsfilters/dec_mpc/src/mpc_reg.cpp	(revision 369)
@@ -0,0 +1,102 @@
+//-----------------------------------------------------------------------------
+//
+//	Musepack Demuxer
+//
+//	Author : Igor Janos
+//
+//-----------------------------------------------------------------------------
+#include "stdafx.h"
+
+#pragma warning(disable: 4996)
+
+//-----------------------------------------------------------------------------
+//
+//	Registry Information
+//
+//-----------------------------------------------------------------------------
+
+
+const AMOVIESETUP_MEDIATYPE sudPinTypes[] =   
+		{ 
+			{
+				&MEDIATYPE_Audio,
+				&MEDIASUBTYPE_MusepackPacket
+			},
+			{
+				&MEDIATYPE_Audio,
+				&MEDIASUBTYPE_PCM
+			}
+		};
+
+const AMOVIESETUP_PIN psudPins[] = 
+		{ 
+			{ 
+				L"Input",
+				FALSE,              // bRendered
+                FALSE,              // bOutput
+                FALSE,              // bZero
+                FALSE,              // bMany
+                &CLSID_NULL,        // clsConnectsToFilter
+                NULL,               // strConnectsToPin
+                1,                  // nTypes
+                &sudPinTypes[0]		// lpTypes
+			}      
+             , 
+			{ 
+				L"Output",          // strName
+                FALSE,              // bRendered
+                TRUE,               // bOutput
+                FALSE,              // bZero
+                FALSE,	            // bMany
+                &CLSID_NULL,        // clsConnectsToFilter
+                NULL,	            // strConnectsToPin
+                1,                  // nTypes
+                &sudPinTypes[1]		// lpTypes
+			} 
+		};   
+
+
+const AMOVIESETUP_FILTER sudMPCDecoder = 
+		{ 
+			&CLSID_MusepackDecoder,			// clsID
+            L"MONOGRAM Musepack Decoder",	// strName
+            MERIT_NORMAL,					// dwMerit
+            2,								// nPins
+            psudPins						// lpPin 
+		};                     
+
+CFactoryTemplate g_Templates[]=
+		{
+			{
+				L"MONOGRAM Musepack Decoder",
+				&CLSID_MusepackDecoder,
+				NULL, //CMPCDemux::CreateInstance, 
+				NULL,
+				&sudMPCDecoder 
+			},
+			{
+				L"MONOGRAM Musepack Decoder",
+				&CLSID_MusepackDecoderPage,
+				NULL, //CMPCPropertyPage::CreateInstance
+			}
+		};
+
+int g_cTemplates = sizeof(g_Templates)/sizeof(g_Templates[0]);
+
+
+//-----------------------------------------------------------------------------
+//
+//	DLL Entry Points
+//
+//-----------------------------------------------------------------------------
+
+STDAPI DllRegisterServer() 
+{
+	return AMovieDllRegisterServer2(TRUE);
+}
+
+STDAPI DllUnregisterServer()
+{
+	return AMovieDllRegisterServer2(FALSE);
+}
+
Index: /dsfilters/dec_mpc/src/mpc_types.h
===================================================================
--- /dsfilters/dec_mpc/src/mpc_types.h	(revision 369)
+++ /dsfilters/dec_mpc/src/mpc_types.h	(revision 369)
@@ -0,0 +1,34 @@
+//-----------------------------------------------------------------------------
+//
+//	Musepack Decoder
+//
+//	Author : Igor Janos
+//
+//-----------------------------------------------------------------------------
+#pragma once
+
+// {555C4774-101E-49d7-8EEC-B9B87F8E1905}
+static const GUID CLSID_MusepackDecoder = 
+{ 0x555c4774, 0x101e, 0x49d7, { 0x8e, 0xec, 0xb9, 0xb8, 0x7f, 0x8e, 0x19, 0x5 } };
+
+// {9024FA6B-7751-4ea7-B575-393B472434EF}
+static const GUID CLSID_MusepackDecoderPage = 
+{ 0x9024fa6b, 0x7751, 0x4ea7, { 0xb5, 0x75, 0x39, 0x3b, 0x47, 0x24, 0x34, 0xef } };
+
+
+//-----------------------------------------------------------------------------
+//
+//	Custom Media Types
+//
+//-----------------------------------------------------------------------------
+
+// {0D2657B6-13B3-4c9b-AC9F-2EE055C51755}
+static const GUID MEDIASUBTYPE_MusepackPacket = 
+{ 0xd2657b6, 0x13b3, 0x4c9b, { 0xac, 0x9f, 0x2e, 0xe0, 0x55, 0xc5, 0x17, 0x55 } };
+
+
+
+
+
+
+
Index: /dsfilters/dec_mpc/src/stdafx.h
===================================================================
--- /dsfilters/dec_mpc/src/stdafx.h	(revision 369)
+++ /dsfilters/dec_mpc/src/stdafx.h	(revision 369)
@@ -0,0 +1,61 @@
+//-----------------------------------------------------------------------------
+//
+//	Musepack Decoder
+//
+//	Author : Igor Janos
+//
+//-----------------------------------------------------------------------------
+#pragma once
+
+#pragma warning(disable: 4996)
+
+// Modify the following defines if you have to target a platform prior to the ones specified below.
+// Refer to MSDN for the latest info on corresponding values for different platforms.
+#ifndef WINVER				// Allow use of features specific to Windows XP or later.
+#define WINVER 0x0501		// Change this to the appropriate value to target other versions of Windows.
+#endif
+
+#ifndef _WIN32_WINNT		// Allow use of features specific to Windows XP or later.                   
+#define _WIN32_WINNT 0x0501	// Change this to the appropriate value to target other versions of Windows.
+#endif						
+
+#ifndef _WIN32_WINDOWS		// Allow use of features specific to Windows 98 or later.
+#define _WIN32_WINDOWS 0x0410 // Change this to the appropriate value to target Windows Me or later.
+#endif
+
+#ifndef _WIN32_IE			// Allow use of features specific to IE 6.0 or later.
+#define _WIN32_IE 0x0600	// Change this to the appropriate value to target other versions of IE.
+#endif
+
+#define WIN32_LEAN_AND_MEAN		// Exclude rarely-used stuff from Windows headers
+#define _ATL_CSTRING_EXPLICIT_CONSTRUCTORS	// some CString constructors will be explicit
+
+#ifndef VC_EXTRALEAN
+#define VC_EXTRALEAN		// Exclude rarely-used stuff from Windows headers
+#endif
+
+#include <afx.h>
+#include <afxwin.h>         // MFC core and standard components
+#include <afxext.h>         // MFC extensions
+#ifndef _AFX_NO_OLE_SUPPORT
+#include <afxdtctl.h>		// MFC support for Internet Explorer 4 Common Controls
+#endif
+#ifndef _AFX_NO_AFXCMN_SUPPORT
+#include <afxcmn.h>			// MFC support for Windows Common Controls
+#endif // _AFX_NO_AFXCMN_SUPPORT
+
+#include <iostream>
+#include <windows.h>
+
+#include <afxtempl.h>
+#include <streams.h>
+#include <initguid.h>
+#include <dvdmedia.h>
+
+//#include "bits.h"
+#include "mpc_types.h"
+//#include "mpc_file.h"
+//#include "mpc_pin.h"
+//#include "mpc_filter.h"
+//#include "mpc_prop.h"
+
