Showing posts with label manual. Show all posts
Showing posts with label manual. Show all posts

Monday, October 25, 2010

Internet Radio in surround.

RECOMMENDED FOR 5.1 or 7.1 speakers set!



First you would need to have 5.1 or 7.1 speakers. I recommend old good Creative Gigaworks S750 that are still working for me ;)

Next step is to download and install Media Player Classic with AC3 filter OR Winamp with AndrewLabs ATSurround Processor (it's payware but there is older, free version on the internet).



























Now you navigate to Shoutcast and find yourself an internet radiostation You want to listen to.

-> If you have winamp installed then it will open itself automatically when you click listen button. After it opens, click right mouse button on its interface and select properties, navigate to Plugins--Output and select AndrewLabs ATSurround Processor. Close settings and press stop and play buttons.


-> If you have MPC Home Cinema and AC3filter installed (better choice in my opionion). Copy radio url from winamp or by using notepad on .pls file downloaded from shoutcast. You may want to try playing pls file in MPC, if it doesn't fail.
In MPC, go to View->Options menu. Now select Internal Filters---Audio Switcher and UNCHECK Enable built-in audio switcher filter. Restart playing sound.


You shuold notice AC3filter icon appearing in taskbar. Double click it. In Main tab there are Output format settings. Select 3/2+SW 5.1 channels from list. Restart playing in MPC.


Vua la! You have now surround sound from your stereo MP3 or internet radio (MAY not work with AACp radio streams - some additional steps may be required).



MPC+AC3filter is better choice in my opinion, because it lets you manually edit Mixing matrix, Bass redirection (I'm using 90 cutoff frequency that works GREAT on my S750). You can as well redirect sound to your Digital output. Shoutcast through digital surround speakers! Hell yeah!

If you have any questions about setting it up, please comment them under this post.

HAVE FUN! ;D

Monday, July 19, 2010

ShellandWait VB6 used in KrzYoptimizer

Shell and wait used in KrzYoptimizer looks like this (v1.11):


Private Declare Function OpenProcess Lib "Kernel32" (ByVal dwDesiredAccess As Long, ByVal bInheritHandle As Long, ByVal dwProcessID As Long) As Long
Private Declare Function GetExitCodeProcess Lib "Kernel32" (ByVal hProcess As Long, lpExitCode As Long) As Long
Private Declare Function CloseHandle Lib "Kernel32" (ByVal hObject As Long) As Long
Private PROCESS_HANDLE As Long


Public Function shellAndWait(ByVal PROGRAM_NAME As String, Optional ByVal WINDOW_STYLE As VbAppWinStyle = vbNormalFocus, Optional ByVal MAX_WAIT_SECONDS As Long = 0, Optional ByVal DO_I_CHECK As Byte = 0) As Integer

Dim PROCESS_ID As Long
Dim ERRORLEVEL_CODE As Long
Dim TIME_STARTED As Date

Const PROCESS_QUERY_INFORMATION As Long = &H400
Const STILL_ACTIVE As Long = &H103
Const PROCESS_TERMINATE As Long = &H1

' Start the program.
On Error GoTo ShellError
PROCESS_ID = Shell(PROGRAM_NAME, WINDOW_STYLE)
On Error GoTo 0

DoEvents

' Wait for the program to finish.
' Get the process handle.
PROCESS_HANDLE = OpenProcess(PROCESS_QUERY_INFORMATION Or PROCESS_TERMINATE, 0, PROCESS_ID) ' Or PROCESS_TERMINATE
If PROCESS_HANDLE <> 0 Then
TIME_STARTED = Now

Do
GetExitCodeProcess PROCESS_HANDLE, ERRORLEVEL_CODE
DoEvents
Sleep DELAY_ERRORCODE_CHECK
Loop While ERRORLEVEL_CODE = STILL_ACTIVE

CloseHandle PROCESS_HANDLE
PROCESS_ID = 0
shellAndWait = ERRORLEVEL_CODE
ElseIf DO_I_CHECK = 1 Then
Sleep DELAY_ERRORCODE_CHECK
shellAndWait = shellAndWait(PROGRAM_NAME, WINDOW_STYLE, MAX_WAIT_SECONDS, 1)
End If
Exit Function

ShellError:
stbStatus.Panels(1).text = "ERROR: " + PROGRAM_NAME + " won't run!"
End Function

Private Sub Form_QueryUnload(cancel As Integer, unloadmode As Integer)

If PROCESS_HANDLE <> 0 Then
Dim cool As Integer
Do While TerminateProcess(PROCESS_HANDLE, 0&) <> 0
cool = cool + 1
DoEvents
stbStatus.Panels(1).text = "Terminating process... " + CStr(cool)
Loop
End If
End
End Sub




Please note that it's only a part of program code.
There is still MAX_WAIT_SECONDS variable in shellandwait function. It was used to prevent program from getting stuck but it seems like those programs don't get stuck. At least as far as i tested.

This shell and wait is based on GetExitCodeProcess to check if program is still running and just incase allow program to Terminate process if user closes program when BIIIG file is being recompressed. When user interacts with GUI too much (like menu or listview scrolling) and this function is in DO_I_CHECK mode (1) - means that WE NEED error code [variable or if in other sub] - then program will be restarted as long as proper error code is returned.

Thursday, June 24, 2010

Manually convert ZIP to GZ

Don't want to use programs that will convert ZIP to GZ by recompressing the whole archive? Doing this may result in file being larger than ZIP! Maybe you just want compresion data to stay intact? This guide is for you!

Pre:
1. Run deflopt on the archive before conversion to make sure it doesn't contain any comments in order to use guide below.

In Xvi32 do:
1. Make sure ZIP contains only one file that is NOT in directory.
2. Open it with Xvi32 and DEL till you reach filename
3. Now make sure that 'Overwrite' is OFF in 'Tools' menu.
4. Go to Address 0 and click on hex view [left window]
5. Do A or B
A1. Type: 1F 8B 08 08 00 00 00 00 02 00
A2. Now in hex view go to next character after filename and type 00
or
B1. Type: 1F 8B 08 00 00 00 00 00 02 00
B2. Delete filename with extension
6. Go to end of file [last address]
7. Look carefully, you should notice two "PK" strings.
8. Navigate to the one that is earlier [NOT THE ONE THAT IS ALMOST AT THE END]
9. Click on the P from "PK" and press DELETE key 16 times.
10. Press right arrow 4 times
11. Press delete 4 times
12. Press right arrow 4 times
13. Delete every character from this position to the end of file
14. Change extension to GZ and vua la. You have GZ file!

If you did everything right, you should be able to decompress it without any problems.