incorrect audio track length returned from MCIWndGetLength for mp3

hi there

i am using the MCIWnd* (ie Video for Windows) apis to play mp3 and wave
files

the MCIWndGetLength() macro is meant to return the length of the audio
file, in milliseconds (to make sure this happens i call MCIWndUseTime()
first)

this works fine for WAV files, but the values returned for MP3 files
don't reflect their duration in millisecs - what does it return for mp3
files? can i translate that easily into millisecs?

tia
bhu

0
bhuvidya (34)
7/30/2006 11:44:35 PM
vc.mfc 33608 articles. 0 followers. Follow

2 Replies
680 Views

Similar Articles

[PageSpeed] 23

"bhu Boue vidya" <bhuvidya@yahoo.com.au> wrote in message 
news:1154303075.383266.204890@m79g2000cwm.googlegroups.com...
>
> the MCIWndGetLength() macro is meant to return the length of the audio
> file, in milliseconds (to make sure this happens i call MCIWndUseTime()
> first)
>
> this works fine for WAV files, but the values returned for MP3 files
> don't reflect their duration in millisecs - what does it return for mp3
> files? can i translate that easily into millisecs?
>

I've encountered the same problem on systems with Media Player 9 or 10 
installed.  Microsoft is no longer claiming to support MCIWnd (unfortunately 
continuing their trend of deprecating the simple API's and replacing them 
with hopelessly complex ones), and MP3 support varies.  Some of my MP3 files 
are fine, but I have trouble with MCIWnd playing LAME-encoded ones at 320 
kbps.

I guess the easiest thing for us to do is replace MCIWnd and use the WMP 
control.  But this requires redistributing Media Player, and that requires a 
written license with Microsoft (free, but still....).  All in all, a sad 
situation.  I've not gotten around to doing this but may have to sooner or 
later.

-- David


0
dc2983 (3206)
7/30/2006 11:59:48 PM
thanx - its all becoming clearer now! a broken API - damn! and MCIWnd
is so simple to use.......


David Ching wrote:
> "bhu Boue vidya" <bhuvidya@yahoo.com.au> wrote in message
> news:1154303075.383266.204890@m79g2000cwm.googlegroups.com...
> >
> > the MCIWndGetLength() macro is meant to return the length of the audio
> > file, in milliseconds (to make sure this happens i call MCIWndUseTime()
> > first)
> >
> > this works fine for WAV files, but the values returned for MP3 files
> > don't reflect their duration in millisecs - what does it return for mp3
> > files? can i translate that easily into millisecs?
> >
>
> I've encountered the same problem on systems with Media Player 9 or 10
> installed.  Microsoft is no longer claiming to support MCIWnd (unfortunately
> continuing their trend of deprecating the simple API's and replacing them
> with hopelessly complex ones), and MP3 support varies.  Some of my MP3 files
> are fine, but I have trouble with MCIWnd playing LAME-encoded ones at 320
> kbps.
>
> I guess the easiest thing for us to do is replace MCIWnd and use the WMP
> control.  But this requires redistributing Media Player, and that requires a
> written license with Microsoft (free, but still....).  All in all, a sad
> situation.  I've not gotten around to doing this but may have to sooner or
> later.
> 
> -- David

0
bhuvidya (34)
7/31/2006 1:56:09 AM
Reply:

Similar Artilces:

Tax report incorrectly shows capital gains in tax deferred account
There does not seem to be a pattern to this. When I pull up a tax-related transactions report, activity for some tax deferred accounts (IRA, 401k, 403b) is shown as investment income while activity from other tax deferred accounts is not. By activity, I mean capital gains distributions and dividends on mutual funds. I would prefer that no activity from tax deferred accounts is shown in this report because that is what is correct, and it would be more beneficial for tax planning purposes. All retirement accounts are designated as retirement accounts in the account setup. Also, the r...

User e-mail showing incorrect return address
I have a small business server 2003 running exchange 2003. When a user sends an e-mail out the return address shows as user@domain.local which an external e-mail user cannot reply to. When I try to correct this by changing the user e-mail address to user@domain.com, external users get the correct reply address but exchange holds the return message in the categorizer and the user never receives the e-mail. I would appreciate input on how to resolve either of these issues. Vincent LaBonte Assistive Technologies Inc. ...

Case ID v/s Email tracking token
CRMers, When you create a case for a support email, by default the generated case id is of the form CAS-number-suffix. When a support person replies to the email, the CRM system automatically adds an email tracking token to the subject line. This email tracking token is not the same as the case id. Questions: 1. Why can't the email tracking token be the same as the case id? Won't it make sense to use case id to track emails for a given support case? 2. Even if they are different, how can I disable automatic placement of tracking token on the subject line? We do not wish to confuse th...

Returning to a Record on a form
Hi folks I have a situation where i am trying to return to a particular record on a form where i had been navigating thru a table. I have buttons on the form eg ADD, EDIT, SAVE, CANCEL, EXIT and the navigation controls enabled. I reach a record say record 44 and then decide to ADD a new record and press my ADD button which puts me into a new record and enables/disables my buttons appropriately. I then decide to CANCEL and not add the new record (me.undo etc) but I want to return to where I was previously. Normally I would be returned to the first record in the underlying table/query...

Is there a registry key to specify the idle time before tracking info is processed?
Hello, In Outlook, read receipts and delivery notifications are processed in idle time, which seems to be about 1-2 minutes. Anyone know if a registry key specifies the exact idle time? We're looking to reduce it, like to zero if feasible! Thanks, - Alan. How did you come to this conclusion? Receipts are processed immediately = when using Exchange. Perhaps you need to specify your environment. --=20 Milly Staples [MVP - Outlook] Post all replies to the group to keep the discussion intact. After furious head scratching, Alan asked: | Hello, |=20 | In Outlook, read receipts and de...

Facing problem in Shipment/Returns and Invoicing in Purchasing
Hi everybody, I have come across the following situation... 1. Created a PO for-non inventory item as follows Item Qty Rate xxxxx 50 50.00 2. Entered and posted a shipment for 20 quantities of xxxxx. Realized that there was an error in the quantity...it should have been 30. 3. Entered a return for the above mentioned shipment matched the receipt and posted. 4. Entered a shipment for 30 quantities of xxxxx and posted it. 5. When I used the auto-invoice feature to invoice the shipment, the system invoiced 50 quantities. It ha...

Incorrect Sum
I am having a problem summing a column of numbers. These numbers are both negative and positive numbers. When I sum the numbers it comes to zero. This is correct, but when I reformat and take out a 30 decimal places I suddenly start getting numbers starting at about the 12th decimal place. These numbers are dollar amounts. I know they don't go beyond 2 decimal places. I've hand entered them. When I take all of the numbers out 30 decimal places, nothing shows up. It only does it on the sum. I tried summing only the negative numbers and postive numbers separately it works ...

Question: OPEN return status
Excel-97 (SR-2) My Excel version 4 manual describes the obsolete form of Fopen, with this syntax I hoped to perform [G15:FileNonExistent] = <within a macro> isNA( Fopen( "C:\datafile.pdf", 2)) However the syntax in Excel-97 now means I have to use [G15:FileNonExistent] = <within a macro> open "C:\datafile.pdf" for input as #123 Trouble is this does not return a status, but generates an error if the file does not exist. How can the macro trap this error and convert it to a return status? When I actually tried this with a non-existent file, the cell inv...

Publisher 2003 Audio Upload
I have a audio track that is recorded as an mp3 and plays in windows media player. When I import it into publisher and transfer it to the audio track, the track sounds like it plays at a much higher speed and you hear really high pitched voices like you are fast forwarding a tape player. The audio is 36 minutes long and appears that long on the timeline. When I play the audio to preview it before pasting it on the timeline, the timing is normal and the voices sound fine. I am trying to create a audio background to a slide presentation and I can't get past this problem. Any idea...

Converting length from metres to millimetres
Using a formula I wish to be able to convert the following examples 6.4m, 7.65m, 7.875m, 11.875m, 12.5 & 13.72m to 6400, 7650, 7875, 11875, 12500 & 13720 respectively. As you can see the descriptions used can be between 1 & 3 decimal places & always trailed by an m. Any help would be greatly appreciated. With data like yours in A1, use: =1000*LEFT(A1,LEN(A1)-1) -- Gary''s Student - gsnu200909 "Rocko" wrote: > Using a formula I wish to be able to convert the following examples 6.4m, > 7.65m, 7.875m, 11.875m, 12.5 & 13.72m t...

Tracking dates in Excel
What would be the formula to do the following in Excel (2003)? Want to be able to enter a series of different start dates and then with a formula have Excel calculate a corresponding event date 3 months later, 6 months later, 9 months later, and 12 months later. It would be acceptable to have the system show 60 days later rather than 3 months. THANK YOU! -- Dee, new to Excel Try this: A2 = some date Enter this formula in B2 and copy across to E2: =DATE(YEAR($A2), MONTH($A2)+COLUMNS($B2:B2)*3,DAY($A2)) -- Biff Microsoft Excel MVP "Dee" <Dee@discussions.microsoft.com...

send and return value from storedprocedure
Hi i have to run a storedprocedure : CREATE PROCEDURE cins_ev @out as int OUTPUT, @in as int AS SELECT @out=@in+5 RETURN 10 that gets imput parameters and returns output parameters. I read the help apge about CRecordset and i wrote some code .... but it doesnt work. this is my code, can you explain me what have i to do to let it run??? thanks Carlo class my_event : public CRecordset { public: my_event(CDatabase* pDatabase = NULL); DECLARE_DYNAMIC(my_event) // Field/Param Data //{{AFX_FIELD(my_event, CRecordset) long m_in; long m_out; //}}AFX_FIELD // Overrides // ClassWizard ge...

DST and Message Tracking Logs
I applied patches to OS, Exchange and the Exchange tool and thought we were in good shape... until I used message tracking this morning. Message tracking log times are 1 hour ahead! Anybody else run into this? Does it represent bigger problems? I only patached the OS on our exchange servers so far. This week I will be doing exchange 2k3 ent sp1 DST patch. One of my admins told me that the message tracking times were 1 hr ahead. I confirmed what my admin saw, so it's happening to us too. Must have something to do with the DST patch and like I said so far I have only patched DST at t...

What are the formula for calculating ROI all dates (Total return all dates)
From http://money.mvps.org/articles/portfolio_columns.aspx, it says that dividends should be included in calculation of ROI all dates(Total return all dates) So the formula for ROI should be ((market price - purchase price)+ dividend) / purchase price. Is this correct? However, what I am seeing is that ROI all dates is calculated as (market price - purchase price)/purchase price. Is there any other parameter that includes dividends also In microsoft.public.money, rvsw@hotmail.com wrote: > From http://money.mvps.org/articles/portfolio_columns.aspx, it says >that dividends should be i...

PO Returns should pull from line item distributions
If there is a split of the distributions on a PO receipt then when we do a PO return against that receipt it should pull those split distributions from the lines. Currently it just brings in the default account from the receipt and not the distributions that were actually posted to ---------------- This post is a suggestion for Microsoft, and Microsoft responds to the suggestions with the most votes. To vote for this suggestion, click the "I Agree" button in the message pane. If you do not see the button, follow this link to open the suggestion in the Microsoft Web-based News...

Barcode printing and tracking
Greetings: I am looking for advice regarding bar code label printing with Access. My non-profit organization receives donated items that are sold in our store. I want to track this inventory by attaching a bar code label to the merchandise when it is received so the donor will receive proper credit when the item is sold. Ideally, the barcode will contain the donor's information as it is entered into the database. Then, it would be nice if scanning the barcode on the item would bring up the donor's record from the database (sort of a two-way operation). Can anyone give me a few tip...

Exchange Message Tracking Center Error
When I attempt to track a message using Exchange Tools Message Tracking Center. I recieve the following error message: The Message Tracking Center was unable to search a message tracking log file: File:\\Server1\Tracking.log\20040412.log Error: The network path was not found. I have checked the settings on the general tab of the server and find that message tracking is enabled, and all Exchange services including Exchange System attendant are Started. I have re-started all services and continue to recieve the error. Any Ideas... Check to make sure that the Message Tracking directory is s...

Pass Through Query
I've written some SQL, which when run on SQL Server 2005 returns rows. Plugged this SQL into an Access 2003 pass through query, but when run it reports an error saying pass through query with return records set to true did not return any records. I've got other pass through queries in this Access database that work fine. The SQL in this query is more complicated and creates a temp table - could this be causing the problem? hi Gary, On 08.03.2010 10:38, Gary Watson wrote: > The SQL in this query is more complicated and creates a temp table - could > this be cau...

prices incorrect when updated
In my 401K account, when I update online I get the wrong price. I know my ticker symbol is correct, but there is a huge difference in the prices when compared to my statement- which is a current one with up to date figures. I use the ticker my fund pprovided me. I have searched through all of the other possible symbols and nothing remotely compares to the prices I have from my statement. Thanks for any help! Sue, I suggest you check your fund at other sites such as finance.yahoo.com or www.smartmoney.com Your paper statement can only show one day's price. It is possible that Money&...

Automatic Indented Return
Hi, I want to be able to list the following: 1. describe $ but I want to be able to have "1" and "$" in the same spot each time but when i reach the "$" sign I would like word to automatically go to the next line and have it lined up with the start of the indentation at "describe".. and preferrably the "$" needs to be in line with the last sentence of the description.. Any help would be appreciated.. Use tab stops to set the positions, and tabs between words to go to those positions. See ht...

Retrieving a message incorrectly forwarded
Dear all Is it possible to retrieve an email that was sent in error to a person, without them receiving/opening it? Any assistance will be welcomed. Regards, AE Short answer, without knowing anything about your setup: no. Message Recall is available only if you use Exchange Server, sent to another Exchange mailbox, and a very specific set of circumstances was met... Andrew wrote: > Dear all > > Is it possible to retrieve an email that was sent in error to a > person, without them receiving/opening it? > > Any assistance will be welcomed. > > Regards, > > AE ...

Where does "Create Return" option on Extras come from?
What causes the "Create Return" option on the Extras>Additional menu of the Sales Transaction Entry screen to appear? I can see (and use) it on my workstation, but I have another user who can't, and I can't figure out what gives access to it. -- Bud Cool, Accounting System Manager HDA, Inc. Hazelwood, MO GP 9.0, SP2 Bud, That comes from the Field Service Module. -- Tim Foster "Bud" wrote: > What causes the "Create Return" option on the Extras>Additional menu of the > Sales Transaction Entry screen to appear? > > I can see ...

access 2007
I am new to Access 2007. In previous versions of Access, I was able to run an update query to place carriage returns in place of square box characters that were showing up after importing Excel spreadsheets into the database (Article ID 210372). Unfortunately this solution does not appear to work in Access 2007. Perhaps I am missing something? Has the code for the module changed or the string in the update query? Any help would be greately appreciated! A2007 uses the same CrLf for new lines. Are you sure the code is running? By default, no code runs in A2007 unless your database...

eConnect receivables DOCNUMBR length doesn't match table length
OK, all you wizards out there... How come the length of the DOCNUMBR field in the eConnect <taRMTransaction> is 17, but the length of the same field in the RM20101 table is 21?? -- Bud Cool, Accounting System Manager HDA, Inc. Hazelwood, MO GP 9.0, SP2 I believe the additional 4 characters in the OPEN file was to allow for a suffix if needed. Unposted Receivables transactions can only have 17 characters thus that is what is only allowed by eConnect. -- Lorren Consulting Technology Lead WennSoft Inc. The views or opinions expressed in this post are mine and not those of Wenn...

Can anyone help with these two problems of incorrect entries and reports?
Have not had a great deal of responses to my posted problems here and can not find anyone expert in Money to hire to help. It would be very nice to start this current year with these errors corrected and a clean starting point. Can anyone suggest ways to fix the following? Money 2004 Small Business 1. Under my customer list, I have an amount for unassigned credits which is not true. It says it is for a customer that is no longer a customer, but it actually lists a bank that one customer used to pay from and was never listed as a customer. The real customer's account is perfectly balanc...