Mailing Lists: Apple Mailing Lists

Image of Mac OS face in stamp
 
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

QTSPresNewStream parameters?



I'm trying to broadcast a real-time captured QuickTime movie over a
local network. I'm using the Sourcer and Presentation APIs to do it.
It works just fine if I use the default setup (use sequence grabber to
capture audio and video, use QTSPresSettingsDialog to configure audio
and video sources and formats) but this is too limited for my purposes
(it only allows 1 video track and 1 audio mono or stereo track, but I
need 1 video track and 24 mono audio tracks). So, I'm trying to either
create my own presentation or adapt the one I get by using the default
setup.
However, seeing as the documentation of the sourcer and presentation
APIs is still extremely limited, I need help getting this to work.
What I'm trying to do is to add an extra stream with its own sourcer
to my existing (working) presentation. This seems to work, until I get
to the QTSPresNewStream call, which needs a data parameter which is
typed as a void *. This is what I have so far:

	ComponentDescription cd;
	Component component;
	QTSSourcer sourcer;
	QTSStream stream;

	memset(&cd, 0, sizeof(cd));
	cd.componentType = kQTSSourcerType;
	cd.componentSubType = kQTSSGChannelSourcerType;
	component = FindNextComponent(0, &cd);
	if(component == 0)	return;
	if((myErr = OpenAComponent(component, &sourcer)) != noErr) return;
	if((myErr = QTSSourcerInitialize(sourcer, NULL)) != noErr) return;
	if((myErr = QTSPresNewStream(gPresentation, SoundMediaType, NULL, 0,
0, &stream)) != noErr) return;

This last call returns NULL in stream, which is expected since it
doesn't get the right data. Can anyone tell me what kind of structure
it requires?
Or can anyone confirm that what I'm trying to do is unsupported, and I
should just forget about it? I'm planning to do this 24 times and add
them all to my presentation with QTSPresAddSourcer() and then
hopefully stream all tracks.

Thanks,

Dirk
 _______________________________________________
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

This email sent to email@hidden



Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Contact Apple | Terms of Use | Privacy Policy

Copyright © 2007 Apple Inc. All rights reserved.