Thanks Brian. That worked ! Couple of follow up questions though -
1. This works for English and also worked for French, German and
Spanish paths (I tried the special symbols associated with each).
Now, it doesn't work for languages like Chinese and Arabic for
example. I get the -37 error. Is there something unique about the
mapping of Unicode to CFStrings that it has trouble with some
languages ?
What version of QT are you currently running?
2. I'm using CreateMovieStorage() and AddMovieToStorage() to create
my file. When I call AddMovieToStorage(), it seems to create
a .#res file also. Previously, I used the CreateMovieFile() with
the createMovieFileDontCreateResFile flag and PutMovieIntoDataFork
() and this did not create a .res file. However, the
CreateMovieStorage() doesn't document use of this flag. What do I
do to not create a res file ?
createMovieFileDontCreateResFile should work fine with
CreateMovieStorage as well.
-Deepak
________________________________________
From: Brian Pietsch [mailto:email@hidden]
Sent: Friday, June 02, 2006 12:32 PM
To: Paul Deepak
Cc: email@hidden
Subject: Re: QTNewDataReferenceFromFullPathCFString returns -37
The problem is here... CFStrings are not null terminated
internally, so when you tell it you are giving it an array of
_MAX_PATH characters, it creates a string whose length is
_MAX_PATH. As a result, it QTNewDataReference... thinks the file
name is Clip_12.mov\0\0\0\0\0\0\0\0...\0, which exceeds the 63
character file limit. You should replace the line below with the
following:
// Create a CFStringRef with the Unicode string. UniChar is also an
unsigned // short so should be compatible with tmpPath
CFStringRef pathstr = CFStringCreateWithCharacters(0, (UniChar*)
tmpPath,
_MAX_PATH);
_______________________________________________
Do not post admin requests to the list. They will be ignored.
QuickTime-API mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/quicktime-api/email@hidden