Re: Is the Live Video SWF Documentation still working as it should?

62 views
Skip to first unread message

Gray Sadler

unread,
Jun 12, 2013, 6:20:08 PM6/12/13
to justintv-ap...@googlegroups.com
What errors are you getting?

Gray

Sent from my iPhone

On Jun 12, 2013, at 5:29 PM, theor...@gmail.com wrote:

> I am following the step bellows but the flash file wont return anything:
>
> // You must allow justin.tv; for simplicity of developing against localhost as well I've allowed *
> flash.system.Security.allowDomain("*");
>
> // You must use these settings; otherwise our player will go crazy. You should be using these settings anyway because they're better.
> stage.scaleMode = flash.display.StageScaleMode.NO_SCALE;
> stage.align = flash.display.StageAlign.TOP_LEFT;
>
> // Create the loader!
> var loader = new flash.display.Loader();
>
> // Handler for when you've loaded the swf
> function loaded(e){
> // Add the loader to the stage
> addChild(loader);
> // Access the API!
> loader.content.api.play_live("apidemo");
> }
>
> // When we're done loading, trigger the callback
> loader.contentLoaderInfo.addEventListener(flash.events.Event.COMPLETE, loaded);
> // Load the player at 640x480 size (video will be automatically letterboxed properly)
> loader.load(new flash.net.URLRequest("http://www.justin.tv/widgets/live_api_player.swf?video_height=480&video_width=640&consumer_key=YOUR_API_KEY"));
>
> I am using the proper API key, am I missing some type of setup aside from the flash file in order for my player to work?
>
> Will it work offline when I test it or must I have it uploaded to a domain and have that registered here:
> Go to http://www.twitch.tv/oauth_clients/create to set up your application
>
> Thanks in advance for the help.
>
> --
> You received this message because you are subscribed to the Google Groups "Justin.tv API Developers" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to justintv-api-deve...@googlegroups.com.
> To post to this group, send email to justintv-ap...@googlegroups.com.
> To view this discussion on the web visit https://groups.google.com/d/msgid/justintv-api-developers/a4ecadec-7de9-47bb-b0f4-910feaef521e%40googlegroups.com?hl=en-US.
> For more options, visit https://groups.google.com/groups/opt_out.
>
>

design...@gmail.com

unread,
Jun 27, 2013, 12:44:57 PM6/27/13
to justintv-ap...@googlegroups.com, mmo...@theoreminc.net, rmo...@theoreminc.net, theor...@gmail.com
On Wednesday, June 12, 2013 11:29:16 PM UTC+2, theor...@gmail.com wrote:
> I am following the step bellows but the flash file wont return anything:
>
> // You must allow justin.tv; for simplicity of developing against localhost as well I've allowed *
> flash.system.Security.allowDomain("*");
>
> // You must use these settings; otherwise our player will go crazy. You should be using these settings anyway because they're better.
> stage.scaleMode = flash.display.StageScaleMode.NO_SCALE;
> stage.align = flash.display.StageAlign.TOP_LEFT;
>
> // Create the loader!
> var loader = new flash.display.Loader();
>
> // Handler for when you've loaded the swf
> function loaded(e){
> // Add the loader to the stage
> addChild(loader);
> // Access the API!
> loader.content.api.play_live("apidemo");
> }
>
> // When we're done loading, trigger the callback
> loader.contentLoaderInfo.addEventListener(flash.events.Event.COMPLETE, loaded);
> // Load the player at 640x480 size (video will be automatically letterboxed properly)
> loader.load(new flash.net.URLRequest("http://www.justin.tv/widgets/live_api_player.swf?video_height=480&video_width=640&consumer_key=YOUR_API_KEY"));
>
> I am using the proper API key, am I missing some type of setup aside from the flash file in order for my player to work?
>
> Will it work offline when I test it or must I have it uploaded to a domain and have that registered here:
> Go to http://www.twitch.tv/oauth_clients/create to set up your application
>
> Thanks in advance for the help.

I'm using almost the same code except if i just use live_api_player.swf I get the error
Error #2044: Unhandled IOErrorEvent:. text=Error #2036: Load Never Completed.
So i tried the link to the player in a browser and it changed to
live_api_player.r077cea8aaec2c2af5ef7af8d6fefbb4b8c492439.swf so I put this into my url and it works, but I get in my output window an error
TypeError: Error #1009: Cannot access a property or method of a null object reference.
at Browser$/topLevelHost()[../stdlib/Browser.hx:520]
at Browser$/pageUrlDomain()[../stdlib/Browser.hx:498]
at MixpanelBeacon/track_mixpanel_event()[../mixpanel_beacon/lib/MixpanelBeacon.hx:40]
at MixpanelBeacon/track()[../mixpanel_beacon/lib/MixpanelBeacon.hx:206]
at skins::BareSkin/log_mixpanel_stat()[skins/BareSkin.hx:281]
at skins::BareSkin/log_client_play()[skins/BareSkin.hx:1622]
at skins::BareSkin/on_buffer_full()[skins/BareSkin.hx:1607]
at flash.events::EventDispatcher/dispatchEventFunction()
at flash.events::EventDispatcher/dispatchEvent()
at JtvVideoPlayer/dispatch()[../stdlib/JtvVideoPlayer.hx:1050]
at JtvVideoPlayer/net_status_handler()[../stdlib/JtvVideoPlayer.hx:1869]

Reply all
Reply to author
Forward
0 new messages