Jump to content
You are about to reply to a thread that has been inactive for 1535 days.

Please take a moment to consider if this thread is worth bumping.

Recommended Posts

Posted

I set a Texture Media to a URL MP4 video on one face of a prim. I'm trying to find a way to activate the video without having the need of clicking on it. Is there anyone find a successful way to do that ? I would like to have this working for avatar came close to the video without having to tell them "click on the prim to start the video".

NOTE: It seem that the flag PRIM_MEDIA_AUTO_PLAY set to TRUE is not enough.

Here is the script I use in the prim:

string URL = "www.whatevervideo.com/video.mp4";
default
{
    state_entry()
    {
        llSetPrimMediaParams(0, 
        [PRIM_MEDIA_AUTO_PLAY,TRUE,    
        PRIM_MEDIA_CURRENT_URL,URL,    
        PRIM_MEDIA_HOME_URL,URL]);
    }
}
Note: I also attach an image of my Media setup in Firestorm viewer. 

So, what options (coding, config in firestorm or anything else) is there to do that ?

Thanks!

media.jpg

Posted

There is a choice in Firestorm and I think in likely ALL viewers to turn off you media and not auto play.  Some folks have this turned on as a security measure (mine is always off unless I am going somewhere to specifically watch something for example) so I don't think what you are trying to do will work for everyone. There may be a way to do it though an experience but not sure it that would work and the experience would override the personal settings even when agreed to. Not my area of expertise but that's what I know :D. Good luck.

 

Personally when I ran a sim that needed to show videos (either on a prim or via the land tab)  it never really worked all that well :D.  

Depending on the video and the computer the avatar was on it was pretty hit or miss over the years. 

Hopefully someone has some new great info to help you!

 

  • Like 1
Posted
14 hours ago, chrixbed said:

I set a Texture Media to a URL MP4 video on one face of a prim. I'm trying to find a way to activate the video without having the need of clicking on it. Is there anyone find a successful way to do that ? I would like to have this working for avatar came close to the video without having to tell them "click on the prim to start the video".

NOTE: It seem that the flag PRIM_MEDIA_AUTO_PLAY set to TRUE is not enough.

Here is the script I use in the prim:

string URL = "www.whatevervideo.com/video.mp4";
default
{
    state_entry()
    {
        llSetPrimMediaParams(0, 
        [PRIM_MEDIA_AUTO_PLAY,TRUE,    
        PRIM_MEDIA_CURRENT_URL,URL,    
        PRIM_MEDIA_HOME_URL,URL]);
    }
}
Note: I also attach an image of my Media setup in Firestorm viewer. 

So, what options (coding, config in firestorm or anything else) is there to do that ?

Thanks!

media.jpg

I would make an invisible prim and let it detect, when an avatar enters, let it send a command to the prim with the media player (PARCEL_MEDIA_COMMAND_PLAY), remember to enter some logic handling if playing.

If you make it a part of the prim handling the media player, inter object communication using llMessageLinked() - if you make it a stand alone prim use llRegionSay() and listen for the event in your. Making the hidden prim a part of the media prim is the most efficient way, avoiding a listen event and the listen handling impact of the region. Same by using a prim to detect, when a person enters, as you do not need to use llSensor(), which adds to the overhead of the region performance.

If ppl has disabled media playing in their viewer, they will not see and hear video though. We have no way to detect this form a script. A simple sign informing ppl about there is a video you want to show, is a good idea.

 

  • Like 1
Posted

Using a Prim to force the PARCEL_MEDIA_COMMAND_PLAY flag to force the media to start seem to be a good idea. But did I understand that you do not suggest to use llSensor() to detect an avatar. If not, how this prim can be trigged, by collision or something else ?

Thanks !

Posted
1 hour ago, chrixbed said:

Using a Prim to force the PARCEL_MEDIA_COMMAND_PLAY flag to force the media to start seem to be a good idea. But did I understand that you do not suggest to use llSensor() to detect an avatar. If not, how this prim can be trigged, by collision or something else ?

Thanks !

Yes, just use collision. Of course you can use llSensor, the alternative is just a suggestion from my side.

Posted
4 hours ago, Rachel1206 said:

Yes, just use collision. Of course you can use llSensor, the alternative is just a suggestion from my side.

I test it using a listen() state that call llParcelMediaCommandList([PARCEL_MEDIA_COMMAND_PLAY]); which is call from another prim and works like a charm; nobody seem to need to click on the prim anymore to start the video. I will do more test with more people but seem to be the solution.

Thanks!

  • Like 1
You are about to reply to a thread that has been inactive for 1535 days.

Please take a moment to consider if this thread is worth bumping.

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
×
×
  • Create New...