playMaker

Author Topic: WWWObject [SOLVED]  (Read 1612 times)

ArctheLad

  • Playmaker Newbie
  • *
  • Posts: 24
    • View Profile
WWWObject [SOLVED]
« on: November 17, 2014, 09:02:17 AM »
Hi forum,

I am currently looking at using WWWObject. The issue I am having is after setting up the WWWObject with the URL and the Set Movie texture, then assigning the Movie texture, I am going into a final state that has the action of Play Movie Texture, the video is not playing however.

My set up is that everything is on a manager, specifying the game object as a plane with an audio component attached. The first state is an Idle that waits for 10seconds. The second state just has the WWWObject with the youtube URL and a Movie texture object variable. The third state is Set Material Movie Texture with a material called TV, the Video object variable and the specified plane and then the final state has Play movie texture with the video variable assigned to it. 
« Last Edit: November 17, 2014, 10:15:59 AM by Lane »

Lane

  • Administrator
  • Hero Member
  • *****
  • Posts: 2488
  • Yup.
    • View Profile
    • Cleverous
Re: WWWObject
« Reply #1 on: November 17, 2014, 09:08:23 AM »
Are you using Unity Pro?

ArctheLad

  • Playmaker Newbie
  • *
  • Posts: 24
    • View Profile
Re: WWWObject
« Reply #2 on: November 17, 2014, 09:13:33 AM »
I am yeah.

Lane

  • Administrator
  • Hero Member
  • *****
  • Posts: 2488
  • Yup.
    • View Profile
    • Cleverous
Re: WWWObject
« Reply #3 on: November 17, 2014, 09:54:53 AM »
Are you sure the WWW is retrieving the movietexture from the URL successfully? (As in, you can see it apply the video onto the plane).. Seems like this could be a likely hangup since the direct browser URL won't retrieve the embedded page video.

I tested with an ogg file link online and it seems to work.

ArctheLad

  • Playmaker Newbie
  • *
  • Posts: 24
    • View Profile
Re: WWWObject
« Reply #4 on: November 17, 2014, 09:59:23 AM »
When I run the FSM the plane with the material goes black. I am just using a standard Youtube URL.

Lane

  • Administrator
  • Hero Member
  • *****
  • Posts: 2488
  • Yup.
    • View Profile
    • Cleverous
Re: WWWObject
« Reply #5 on: November 17, 2014, 10:07:42 AM »
I don't think this works currently...
http://docs.unity3d.com/ScriptReference/WWW-movie.html

The docs say that the content must be in ogg theora format so a direct stream download from youtube would not work. Maybe there is something on the asset store to enable this.

ArctheLad

  • Playmaker Newbie
  • *
  • Posts: 24
    • View Profile
Re: WWWObject
« Reply #6 on: November 17, 2014, 10:11:14 AM »
Alright, thanks anyway! =]