# @setDataFrame onMetaData not working

**URL:** <https://community.wowza.com/t/setdataframe-onmetadata-not-working/34197>\
**Category:** Wowza Streaming Engine\
**Created:** [July 1, 2010, 2:21pm UTC](https://community.wowza.com/t/setdataframe-onmetadata-not-working/34197 "2010-07-01T14:21:53Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![Sander\_Kruger](https://avatars.discourse-cdn.com/v4/letter/s/5daacb/32.png) [@Sander\_Kruger](https://community.wowza.com/u/Sander_Kruger)\
**Post date:** [July 1, 2010, 2:21pm UTC](https://community.wowza.com/t/setdataframe-onmetadata-not-working/34197/1 "2010-07-01T14:21:53Z")

</div>

Hello,

I’m running Wowza Media Server 2.1.1 build24490 and I have an application that captures video from the camera and streams it to other clients. I’m now building the option to change the capture size.

Now, when you change the capture size of a camera that is streaming, Flash Player will just continue streaming, but in the new size. The receiving end doesn’t receive any event. Now, to be able to update the receiving end, I send a metaData event, like this:

```auto
cam.setMode( w, h, 15 );
if (_isPublishing)
{
	trace( "Send metadata" );
	var metaData :Object = new Object();
	metaData.event="changeSize";
	ns.send("@setDataFrame", "onMetaData", metaData );
}

```

When I use FMS, I receive the metadata correctly each time. But on Wowza, I do not always receive it. It seems that if I stop and play around the time I should get the metadata, I DO receive it. Otherwise, I do not.

Does anyone observe this behaviour?

---

<div class="post-metadata">

**Author:** ![Richard\_Lanham](https://avatars.discourse-cdn.com/v4/letter/r/c68b51/32.png) [@Richard\_Lanham](https://community.wowza.com/u/Richard_Lanham)\
**Post date:** [July 1, 2010, 1:31pm UTC](https://community.wowza.com/t/setdataframe-onmetadata-not-working/34197/2 "2010-07-01T13:31:17Z")

</div>

I think this will only be received when a new client subscribes. If you want to send data to clients that are currently streaming, you have to use netstream.send(“someOtherCallbackFunction”,newHeight,newWidth), and setup “someOtherCallbackFunction” on the Netstream in the client.

Richard

---

<div class="post-metadata">

**Author:** ![Sander\_Kruger](https://avatars.discourse-cdn.com/v4/letter/s/5daacb/32.png) [@Sander\_Kruger](https://community.wowza.com/u/Sander_Kruger)\
**Post date:** [July 1, 2010, 2:47pm UTC](https://community.wowza.com/t/setdataframe-onmetadata-not-working/34197/3 "2010-07-01T14:47:07Z")

</div>

Dear Richard,

Thank you for your quick reply. I modified my code by removing the “@setDataFrame” argument:

```auto
cam.setMode( w, h, 15 );
if (_isPublishing)
{
	trace( "Send metadata" );
	var metaData :Object = new Object();
	metaData.event="changeSize";
	ns.send("onMetaData", metaData );
}

```

and then the code works as it should.

Regards,

Sander

---

<div class="post-metadata">

**Author:** ![Richard\_Lanham](https://avatars.discourse-cdn.com/v4/letter/r/c68b51/32.png) [@Richard\_Lanham](https://community.wowza.com/u/Richard_Lanham)\
**Post date:** [July 1, 2010, 1:50pm UTC](https://community.wowza.com/t/setdataframe-onmetadata-not-working/34197/4 "2010-07-01T13:50:56Z")

</div>

Cool, right, that leverages the existing the onMetaData handler. Thanks for the update.

Richard
