home *** CD-ROM | disk | FTP | other *** search
- VERSION 5.00
- Object = "{E69FD844-2783-11D2-A800-0000B45D21D3}#1.0#0"; "ACM.OCX"
- Begin VB.Form Form1
- Caption = "Form1"
- ClientHeight = 7170
- ClientLeft = 165
- ClientTop = 450
- ClientWidth = 10950
- LinkTopic = "Form1"
- ScaleHeight = 7170
- ScaleWidth = 10950
- StartUpPosition = 3 'Windows-Standard
- Begin VB.CommandButton Command2
- Caption = "Command2"
- Height = 855
- Left = 600
- TabIndex = 10
- Top = 1440
- Width = 1935
- End
- Begin ACM_XLib.ACM_X ACM
- Height = 495
- Left = 6000
- TabIndex = 9
- Top = 240
- Width = 495
- _Version = 65536
- _ExtentX = 873
- _ExtentY = 873
- _StockProps = 0
- End
- Begin VB.Frame Frame2
- Caption = "Compressed"
- Height = 735
- Left = 6720
- TabIndex = 7
- Top = 120
- Width = 2775
- Begin VB.TextBox Text1
- Height = 375
- Left = 120
- TabIndex = 8
- Text = "c:\2.wav"
- Top = 240
- Width = 2535
- End
- End
- Begin VB.Frame Frame1
- Caption = "Source"
- Height = 735
- Left = 120
- TabIndex = 5
- Top = 120
- Width = 3975
- Begin VB.TextBox Text2
- Height = 375
- Left = 120
- TabIndex = 6
- Text = "d:\brennen\alt_d\look.wav"
- Top = 240
- Width = 3735
- End
- End
- Begin VB.TextBox Text3
- Height = 375
- Left = 9720
- TabIndex = 4
- Top = 360
- Width = 975
- End
- Begin VB.CommandButton Command1
- Caption = "Stop"
- Height = 495
- Left = 4680
- TabIndex = 3
- Top = 240
- Width = 1215
- End
- Begin VB.ListBox List3
- Height = 5715
- Left = 6720
- TabIndex = 2
- Top = 1200
- Width = 3975
- End
- Begin VB.ListBox List2
- Height = 5715
- Left = 4320
- TabIndex = 1
- Top = 1200
- Width = 2175
- End
- Begin VB.ListBox List1
- Height = 3180
- Left = 120
- TabIndex = 0
- Top = 3720
- Width = 3975
- End
- Attribute VB_Name = "Form1"
- Attribute VB_GlobalNameSpace = False
- Attribute VB_Creatable = False
- Attribute VB_PredeclaredId = True
- Attribute VB_Exposed = False
- Private Sub ACM_ConvertPosition(ByVal ConvertPosition As Long)
- Form1.Caption = ConvertPosition
- End Sub
- Private Sub Command1_Click()
- ACM.Stop
- End Sub
- Private Sub Command2_Click()
- Dim err
- ACM.SetInputFile ("c:\PCM.wav") ' 44khz/16Bit/stereo
- ACM.SetOutputFile ("c:\ADPCM.wav")
- 'find ADPCM codec
- For i = 1 To ACM.GetNumACMs
- If ACM.GetNameACM(i) = "Microsoft IMA ADPCM CODEC" Then ACM.SelectACMDriver (i)
- Next i
- err = ACM.SetFormatTags(2) ' from Wave to ADPCM
- err = ACM.SetFormat(8) ' 44khz/4Bit/stereo
- err = ACM.Convert
- End Sub
- Private Sub Form_Load()
- Dim err
- End Sub
- Private Sub List1_DblClick()
- ACM.SetInputFile (Text2.Text)
- ACM.SetOutputFile (Text1.Text)
- ACM.SelectACMDriver (List1.ListIndex + 1)
- While List2.ListCount > 0
- List2.RemoveItem (0)
- DoEvents
- List2.Refresh
- For i = 1 To ACM.GetFormatTagsCount
- List2.AddItem (ACM.GetFormatTags(i))
- Next i
- While List3.ListCount > 0
- List3.RemoveItem (0)
- DoEvents
- List3.Refresh
- End Sub
- Private Sub List2_DblClick()
- ACM.SetFormatTags (List2.ListIndex + 1)
- While List3.ListCount > 0
- List3.RemoveItem (0)
- DoEvents
- List3.Refresh
- For i = 1 To ACM.GetFormatsCount
- List3.AddItem (ACM.GetFormat(i))
- Next i
- End Sub
- Private Sub List3_DblClick()
- Dim err
- err = ACM.SetFormat(List3.ListIndex + 1)
- Text3.Text = "Error: " & err
- err = ACM.Convert
- End Sub
-