# Getting video resolution on LiveStreamTranscoderActionNotifyBase

**URL:** <https://community.wowza.com/t/getting-video-resolution-on-livestreamtranscoderactionnotifybase/47408>\
**Category:** Wowza Streaming Engine\
**Created:** [August 19, 2016, 9:11pm UTC](https://community.wowza.com/t/getting-video-resolution-on-livestreamtranscoderactionnotifybase/47408 "2016-08-19T21:11:59Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Gabriel\_Villoldo](https://avatars.discourse-cdn.com/v4/letter/g/b5e925/32.png) [@Gabriel\_Villoldo](https://community.wowza.com/u/Gabriel_Villoldo)\
**Post date:** [August 19, 2016, 9:11pm UTC](https://community.wowza.com/t/getting-video-resolution-on-livestreamtranscoderactionnotifybase/47408/1 "2016-08-19T21:11:59Z")

</div>

Hi! I want to ask you for the best way to get the video resolution on onInitBeforeLoadTemplate method. I need to get the height of the video to choose which template I need to use.

I’ve tried using stream.getRTPStream().getVideoTrack(), but “getRTPStream()” is always null.

Any ideas?

Thanks.-

---

<div class="post-metadata">

**Author:** ![Jason\_Hatchett](https://sea2.discourse-cdn.com/flex002/user_avatar/community.wowza.com/jason_hatchett/32/391_2.png) [@Jason\_Hatchett](https://community.wowza.com/u/Jason_Hatchett)\
**Post date:** [September 30, 2016, 2:52am UTC](https://community.wowza.com/t/getting-video-resolution-on-livestreamtranscoderactionnotifybase/47408/2 "2016-09-30T02:52:47Z")

</div>

Hello,

Since this scenario its rtsp our event handlers become limited, and after discussing with our developer support team,

this is not possible since the transcoder chooses a template well before getting this codec info.

You could try to programmatically use the [transcoder API](https://www.wowza.com/docs/how-to-control-which-streams-get-transcoded-moduletranscodercontrol%28ModuleTranscoderControl%29) to reject the initial stream from transcoding, wait for codec info to arrive, re-publish as a new stream and rebuild the template from the ground up based on the resolution information received.

Regards,

Jason Hatchett
