DirectShow Filter (Codec) Reset

Post » Tue Feb 01, 2011 11:24 pm

I created this utility to help others solved codec related issues. It resets the DirectShow Filter's (Codec) back to "Factory Default"

http://www.newvegasnexus.com/downloads/file.php?id=35868

This is based on http://nightmare2013.brashendeavors.net/

I added support for Vista and windows 7 and automated the backup, OS and Architecture detection. And repackaged it to a SFX that auto runs it's setup.

Using this I was able to get rid of the sound stutters, delays, skipping and most of the poping on the radio. I hope it can help others.

It is a first release and it does mess with the registry and can adversely effect other media players (broke Creative MediaSource Player, but not PowerDVD 8 on my system). So it's not intended for the faint of heart at this point.

UPDATE. uploaded v0.2 fixed the issues with XP.
User avatar
Reven Lord
 
Posts: 3452
Joined: Mon May 21, 2007 9:56 pm

Post » Tue Feb 01, 2011 10:20 pm

or just let ffdshow not use fallout new vegas in the audio decoder configuration (directshow control)
User avatar
Undisclosed Desires
 
Posts: 3388
Joined: Fri Mar 02, 2007 4:10 pm

Post » Tue Feb 01, 2011 10:57 am

or just let ffdshow not use fallout new vegas in the audio decoder configuration (directshow control)

That's not enough in some cases.

It is a first release and it does mess with the registry and can adversely effect other media players (broke Creative MediaSource Player, but not PowerDVD 8 on my system). So it's not intended for the faint of heart at this point.

I had some problems with the batch file in XP. Paths were missing quotation marks and there was a missing label (xpm). Also the Munge stuff didn't really work with the munge.ini. Fixed it for myself, but you might want to look into that, when you have time.
User avatar
Nadia Nad
 
Posts: 3391
Joined: Thu Aug 31, 2006 3:17 pm

Post » Tue Feb 01, 2011 3:48 pm

When the batch file is run there are a bunch of error messages "too many command line parameters", "choice is not recognized as an internal or external command", and then it closes without any option to reset or restore.
User avatar
TWITTER.COM
 
Posts: 3355
Joined: Tue Nov 27, 2007 3:15 pm

Post » Tue Feb 01, 2011 9:48 pm

I used this batchfile which is hardcoded to XP 32-bit after doing a few fixes (no guarantees - XP 32-bit only - remember to make a Restore Point):

Spoiler

@Echo off
REM ################################################
REM ### DirectShow Filter (Codec) Reset ###
REM ### By Blade FireLight ###
REM ### This is an advanced troubleshooting tool ###
REM ### Use at your own risk ###
REM ################################################

set version=XP

REM Detect Architecture
set arch=x86
if %PROCESSOR_ARCHITECTURE%. == AMD64. set arch=x64

REM Check for Backup, DO NOT overwrite (cant risk looseing)
set bk=%userprofile%\documents\codecbackup
if exist "%bk%\backup1.reg" goto backOk
if NOT exist "%bk%" mkdir "%bk%"

reg export HKCR\CLSID\{083863F1-70DE-11d0-BD40-00A0C911CE86} "%bk%\backup1.reg"
reg export HKCR\CLSID\{33D9A761-90C8-11d0-BD43-00A0C911CE86} "%bk%\backup2.reg"
reg export HKCR\CLSID\{da4e3da0-d07d-11d0-bd50-00a0c911ce86} "%bk%\backup3.reg"
reg export HKCR\DirectShow\MediaObjects "%bk%\backup4.reg"
reg export HKCR\Filter "%bk%\backup5.reg"
reg export "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Drivers32" "%bk%\backup6.reg"
if NOT exist "%bk%\backup1.reg" goto bkER
if NOT exist "%bk%\backup2.reg" goto bkER
if NOT exist "%bk%\backup3.reg" goto bkER
if NOT exist "%bk%\backup4.reg" goto bkER
REM if NOT exist "%bk%\backup5.reg" goto bkER
if NOT exist "%bk%\backup6.reg" goto bkER
if %arch%. == x86. goto backOK
reg export HKCR\Wow6432Node\CLSID\{083863F1-70DE-11d0-BD40-00A0C911CE86} "%bk%\backup7.reg"
reg export HKCR\Wow6432Node\CLSID\{33D9A761-90C8-11d0-BD43-00A0C911CE86} "%bk%\backup8.reg"
reg export HKCR\Wow6432Node\CLSID\{da4e3da0-d07d-11d0-bd50-00a0c911ce86} "%bk%\backup9.reg"
reg export HKCR\Wow6432Node\DirectShow\MediaObjects "%bk%\backup10.reg"
reg export HKCR\Wow6432Node\Filter "%bk%\backup11.reg"
reg export "HKLM\SOFTWARE\Wow6432Node\Microsoft\Windows NT\CurrentVersion\Drivers32" "%bk%\backup12.reg"
if NOT exist "%bk%\backup7.reg" goto bkER
if NOT exist "%bk%\backup8.reg" goto bkER
if NOT exist "%bk%\backup9.reg" goto bkER
if NOT exist "%bk%\backup10.reg" goto bkER
REM if NOT exist "%bk%\backup11.reg" goto bkER
if NOT exist "%bk%\backup12.reg" goto bkER

:bkER
echo ERROR: Failed Creating Backup
pause
goto EOF
:backOK

:menu
REM Menu
CLS
echo.
echo -=DirectShow Filter (Codec) Reset v0.1=-
echo.
echo Direct Show Filters are frequently the source of many sound issues
echo in games. This will attempt to reset the filters back to how they
echo were on a fresh install of windows. This may require any audio and
echo vido players to be re-installed. A Backup of your settings the first
echo this is ran are saved in your documents folder under "codecbackup"
echo.
echo WARNING: This program is for advanced troubleshooting, and is
echo provided as-is. Use at your own risk!
echo.
echo 1. Reset DirectShow Filters (Codec) to Default
echo 2. Restore Backup
echo 3. Exit
if %version%. == XP. goto xpmenu
choice /C 123
if ERRORLEVEL 3 goto EOF
if ERRORLEVEL 2 goto restore
if ERRORLEVEL 1 goto reset
goto mErr
:xpmenu
echo.
set /P op=press 1,2,3 and enter
if %op%. == 1. goto reset
if %op%. == 2. goto restore
goto EOF

:restore
if exist "%bk%\backup1.reg" reg import "%bk%\backup1.reg" >nul 2>&1
if exist "%bk%\backup1.reg" reg import "%bk%\backup2.reg" >nul 2>&1
if exist "%bk%\backup1.reg" reg import "%bk%\backup3.reg" >nul 2>&1
if exist "%bk%\backup1.reg" reg import "%bk%\backup4.reg" >nul 2>&1
if exist "%bk%\backup1.reg" reg import "%bk%\backup5.reg" >nul 2>&1
if exist "%bk%\backup1.reg" reg import "%bk%\backup6.reg" >nul 2>&1
if exist "%bk%\backup1.reg" reg import "%bk%\backup7.reg" >nul 2>&1
if exist "%bk%\backup1.reg" reg import "%bk%\backup8.reg" >nul 2>&1
if exist "%bk%\backup1.reg" reg import "%bk%\backup9.reg" >nul 2>&1
if exist "%bk%\backup1.reg" reg import "%bk%\backup10.reg" >nul 2>&1
if exist "%bk%\backup1.reg" reg import "%bk%\backup11.reg" >nul 2>&1
if exist "%bk%\backup1.reg" reg import "%bk%\backup12.reg" >nul 2>&1
echo Restore complete
pause
goto EOF

:reset
echo.
echo WARNING: This process will disable any non standard codec you
echo have installed. They will need to be re-installed or
echo restored from the backup using this program.
echo.
echo Do you want to continue
if %version%. == XP. goto xpm
choice
if ERRORLEVEL 2 goto menu
if ERRORLEVEL 1 goto res
goto mErr
echo.
:xpm
set /P op=press 'y' or 'n' and enter
if %op%. == y. goto res
if %op%. == n. goto menu
echo Invalid option
echo.
goto reset

:res
if %version%. == XP. goto xp
if %version%. == Win7. goto win7
if %version%. == Vista. goto vista
echo ERROR!!
goto EOF
:xp
set src=http://forums.bethsoft.com/index.php?/topic/1133488-directshow-filter-codec-reset/XPx86.reg
if %arch%. == x64. set src=http://forums.bethsoft.com/index.php?/topic/1133488-directshow-filter-codec-reset/XPx64.reg
if %windir%. == C:\Windows. goto exec
goto munge
:win7
set src=http://forums.bethsoft.com/index.php?/topic/1133488-directshow-filter-codec-reset/Win7x86.reg
if %arch%. == x64. set src=http://forums.bethsoft.com/index.php?/topic/1133488-directshow-filter-codec-reset/Win7x64.reg
if %windir%. == C:\Windows. goto exec
goto munge

:vista
set src=http://forums.bethsoft.com/index.php?/topic/1133488-directshow-filter-codec-reset/Vistax86.reg
if %arch%. == x64. set src=http://forums.bethsoft.com/index.php?/topic/1133488-directshow-filter-codec-reset/Vistax64.reg
if %windir%. == C:\Windows. goto exec
goto munge

:munge
munge -F .reg C:\\windows %windir% "%src%"
munge -F .reg ":\" ":\\" "%src%"
munge -F .reg ":\\\" ":\\" "%src%"


echo %windir%>tmp.txt
echo "\" "\\\\\\\\">tmp.ini
munge tmp.ini tmp.txt
for /F "delims=" %%i IN (tmp.txt) DO echo "C:\\Windows" "%%i">munge.ini
del tmp.txt
del tmp.ini
munge munge.ini -L "%src%"
del munge.ini
goto exec

:exec
reg import "%src%" >>"%bk%\log.txt" >nul
cls
echo.
echo Restore complete. If you need to undo thease changes run this program
echo again and use the restore function.
echo.
pause
goto EOF


:eErr
echo ERROR with choice command
echo.
pause
goto EOF

:Unsup
echo Unable to detect your version of windows. Sorry
echo.
pause
goto EOF

:EOF
set arch=
set bk=
set src=http://forums.bethsoft.com/index.php?/topic/1133488-directshow-filter-codec-reset/
set version=


Use it to troubleshoot and then use http://www.nirsoft.net/utils/installed_codec.html to disable DirectShow filters.
User avatar
Elizabeth Falvey
 
Posts: 3347
Joined: Fri Oct 26, 2007 1:37 am

Post » Tue Feb 01, 2011 10:10 pm

Use it to troubleshoot and then use http://www.nirsoft.net/utils/installed_codec.html to disable DirectShow filters.

Thanks, much appreciated! :tops:

Unfortunately, it didn't fix my sound lag though. I guess this was intended as more of a radio fix anyway.
:brokencomputer:
User avatar
Soraya Davy
 
Posts: 3377
Joined: Sat Aug 05, 2006 10:53 pm

Post » Tue Feb 01, 2011 6:28 pm

Thank you for this. As you can see by this thread, Codecs can be an issue for this game.

http://www.gamesas.com/index.php?/topic/897990-codec-investigation-project/

There was not a utility for Vista/7 that I could find. I hope this one works.

Do set a System Restore point as this utility can break some media players as it removes their codecs. Now, why you would want a Media Player that can't use stock codecs is another matter, but just make sure you can go back to pre codec mix if you want to.
User avatar
Roberto Gaeta
 
Posts: 3451
Joined: Tue Nov 06, 2007 2:23 am

Post » Tue Feb 01, 2011 8:35 pm

I have fixed the issues with backup, OS detection, and the menu's in XP.

Thank you for this. As you can see by this thread, Codecs can be an issue for this game.


Your welcome. All this install this, or uninstall that codec pack is like putting a puzzle together blindfolded. This will at least level the playing field so we can see if the issue is a DirectShow filter related.

There was not a utility for Vista/7 that I could find. I hope this one works.


I have now tested on XP SP3 and Win7. works as advertised. I dont have access to Vista.

Do set a System Restore point as this utility can break some media players as it removes their codecs. Now, why you would want a Media Player that can't use stock codecs is another matter, but just make sure you can go back to pre codec mix if you want to.


The readme has some basics to get setup a system restore on XP and how to check when the last was made on Win7.
This site has instructions to http://www.howtogeek.com/howto/3195/create-a-system-restore-point-in-windows-7/ (maybe vista?)
It should not be needed for most people because windows Vista and 7 create a restore point of the boot drive once a day. Plus the backup option of the DirectShow Reset will restore the changes.

Thanks, much appreciated! :tops:

Unfortunately, it didn't fix my sound lag though. I guess this was intended as more of a radio fix anyway.
:brokencomputer:


Sorry it didn't help. This only resets the registry settings for the DirectShow filters if any of the files have been renamed or are truly corrupt it will not help.
This is intended for more then just the radio. any of the sounds that let windows pick the filters should be effected by this. According to the thread CCNA referenced that is everything but speech. It's unfortunate they dont use a similar method for processing all sound files. If they created the Filter Graph using filters they proved for all sounds I doubt there would be any sound issues outside of hardware or drivers.
User avatar
Noraima Vega
 
Posts: 3467
Joined: Wed Jun 06, 2007 7:28 am


Return to Fallout: New Vegas