Thanks, it works.
Back to my original problem. My application sends a lot of meta data to the net stream to do things like show an image. If a subscriber comes in after publishing starts, is there programmatic way to access the meta data so the window is sync with the publisher. What I'm doing now is sending an object with the state (custom keyFrame) to wowza from the publisher and when subscriber connects, I send that object to them. What I don't like about that is that I have to do a nc.call for every nc.send but maybe there's no other way. Richard suggested this could be done server-side using onMetaData method of IMediaStreamActionNotify2 to populate an AMFDataObj to send to new clients onConnect.
Is it possible?
I guess I made an incorrect assumption about onMetaData. Sorry about that
No problemo, besides, I learned a few things. I'll go ahead with my current method of doing as .send and .call. Although, I would of thought the actual metadata object would be available in the onMetaData call.
Actually, you can do it!
public void onMetaData(IMediaStream stream, AMFPacket metaDataPacket)
ByteBuffer packet = metaDataPacket.getDataBuffer();
AMFDataList myMetadata = new AMFDataList(packet);
AMFDataObj lastKeyFrame = (AMFDataObj)myMetadata.getObject(1);
Thus eliminating my need to the nc.call to set the keyframe!
Tags for this Thread