Hello,
I am working on CoreMediaIo sample avaliable on
https://developer.apple.com/library/mac/samplecode/CoreMediaIO/Introduction/Intro.html
This sample shows how to create a DAL PlugIn, assistant process, and kernel extension (kext) for video.
I want to feed this kext with frames (now it uses yuv frames bundled inside kext)
Documentation mentions how to do this, it says that a client application should call function
GetOutputBuffersRequiredForStartup(), and then CopyBufferQueue().
Well I am total newbie in plugin stuff, so what I investigated today is:
1) Install Sample.plugin and kext (respectively to /Library/CoreMedioaIo/PlugIns/DAL
(and FCP-DAL), /System/Library/Extensions/).
2) Client app should load Sample.plugin through CFPlugIn mechanism and get interface
which is exported by that bundle, which is: kCMIOHardwarePlugInInterfaceID.
So I managed how to load plugin, I have reference to exported interface:
CMIOHardwarePlugInInterface **pluginInterface;
...
(*iunknown) -> QueryInterface( iunknown,
CFUUIDGetUUIDBytes(kCMIOHardwarePlugInInterfaceID ),
(LPVOID *)( &pluginInterface ) );
And after adding logs in CoreMediaIO/DeviceAbstractionLayer/Devices/DP/Base/CMIO_DP_CMIO_DP_HardwarePlugInInterface.cpp
I know that I can call functions from the interface, for example:
OSStatus status = (*pluginInterface) -> Initialize(pluginInterface);
My problem is - I don't know how to call GetOutputBuffersRequiredForStartup function now,
it is not available through pluginInterface object. I missed something?
Also all that functions like ObjectHasProperty, ObjectGetPropertyData, etc. takes as an
argument objectID and/or streamID.
From where I should get that ID, for example if I want to call kCMIODevicePropertyDeviceUID?
Thanks for any help with that.
Sincerely, Szymon.