Wayback Machinekoobas.hobune.stream
May JUN Jul
Previous capture 13 Next capture
2021 2022 2023
1 capture
13 Jun 22 - 13 Jun 22
sparklines
Close Help
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
  • Asset Store
  • Get Unity

UNITY ACCOUNT

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account
  • Blog
  • Forums
  • Answers
  • Evangelists
  • User Groups
  • Beta Program
  • Advisory Panel

Navigation

  • Home
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
    • Blog
    • Forums
    • Answers
    • Evangelists
    • User Groups
    • Beta Program
    • Advisory Panel

Unity account

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account

Language

  • Chinese
  • Spanish
  • Japanese
  • Korean
  • Portuguese
  • Ask a question
  • Spaces
    • Default
    • Help Room
    • META
    • Moderators
    • Topics
    • Questions
    • Users
    • Badges
  • Home /
avatar image
0
Question by Leon.S.Kennedy · Dec 12, 2012 at 04:21 PM · textureskyboxmovie

Skybox Movie Texture

In Unity 3.5, When i apply a movie texture to any object, i usually add a script with it to play the movie when the game is running. But now i added 6 movie textures to a skybox and I dont know how to access this texture from the script..
How do i access skybox from the script and play the movie?

Comment
Add comment
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users

1 Reply

· Add your reply
  • Sort: 
avatar image
0
Best Answer

Answer by JanTuts · Jan 03, 2013 at 01:25 AM

The MovieTexture.Play() function will tell the actual video itself to play, not just the MovieTexture you declared, so it doesn't matter where you tell it to play.

 // Add this script to any game object in your scene (preferably your Main Camera)
 
 // Attach the same 6 videos you used in your skybox to the 6 slots of this array
 var movies : MovieTexture[] = new MovieTexture[6];
 
 // As your scene starts, this script will then iterate through those videos
 // and set them to loop and make them start playing
 function Start(){
     for (var movie in movies) {
         movie.loop = true;
         movie.Play();
     }
 }
Comment
Add comment · Show 4 · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image Leon.S.Kennedy · Jan 03, 2013 at 01:05 PM 0
Share

It works man, thanks a lot... You are great!!! but However i dont have any good dynamic sky movie, is there anywhere i can download those?

avatar image JanTuts · Jan 03, 2013 at 09:39 PM 0
Share

Sorry, I have no idea where you could get one. :/ All I could find were live-rendered dynamic skyboxes, which might even be better suited for your needs: http://www.pixelstudio.nl/?p=190

To make a video skybox, I can think of 3 methods, all of which are long, hard work and which are not advised if you are new to any of those fields of design:

1/ Use 3D program like Cinema 4D (or $$anonymous$$aya / 3ds $$anonymous$$ax) to set up a looping animation of clouds, etc. using textured meshes (or in the case of Cinema 4D: live rendered particles!). Then you'd just set up 6 cameras in the scene in a cube formation, make sure their views overlap a bit and render the 6 videos. You can then crop them to size in a video editing program like Adobe Premiere of AfterEffects.

Probably the best option, as you could design any skybox you'd want and make it loop perfectly, but it requires 3D modeling/animation or particle FX skills to pull it off correctly.

2/ Hand-animate: draw each frame of each texture frame-by-frame

A viable option if you're already good at hand-animating. If you're not, steer away from this method, because it's the highest labour-intensive method

3/ Set up a whole bunch of video cameras outside and make sure their views overlap. Let them film for some time, then sync them up in your video editing program. Then export each video as a PNG or JPG sequence. Then you would use a skybox stitching program to make a skybox for each frame. Then use those 6 image sequences to make a movie again your video editing program.

Probably the least favourable option, given that you'd need a load of camera, it's a lot of work + render time and your skybox wouldn't even loop correctly...)

avatar image Leon.S.Kennedy · Jan 04, 2013 at 05:19 AM 0
Share

Of the three ways u mentioned, Cinema 4D and after effects seems to be the correct way to go, but unfortunately im new to both of them.. Well then i have to start learning 3D modelling from now on... Thank you very much for taking the time to explain it..

avatar image JanTuts · Jan 04, 2013 at 05:51 AM 0
Share

Like I said: if it's possible for your project in terms of render-intensity, you could always check out PixelStudio's live-rendered "skydome" http://www.pixelstudio.nl/?p=190

And yeah, looks like we're never done learning... Every time you think something's going to be easy, it turns out there's still a long wait to go. But at least Unity has the Wiki, Forms and Answers! :D The Community constantly helps me out, so I'm glad to return the favour for once, even if it didn't get you that much further this time... :/

Your answer

Hint: You can notify a user about this post by typing @username

Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.

Follow this Question

Answers Answers and Comments

10 People are following this question.

avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image

Related Questions

downloding movie texture 2 Answers

Texture compression Skybox seams 1 Answer

Creating a space skybox scene 1 Answer

Dynamically changing skybox texture 0 Answers

Play movie in full screen 1 Answer


Enterprise
Social Q&A

Social
Subscribe on YouTube social-youtube Follow on LinkedIn social-linkedin Follow on Twitter social-twitter Follow on Facebook social-facebook Follow on Instagram social-instagram

Footer

  • Purchase
    • Products
    • Subscription
    • Asset Store
    • Unity Gear
    • Resellers
  • Education
    • Students
    • Educators
    • Certification
    • Learn
    • Center of Excellence
  • Download
    • Unity
    • Beta Program
  • Unity Labs
    • Labs
    • Publications
  • Resources
    • Learn platform
    • Community
    • Documentation
    • Unity QA
    • FAQ
    • Services Status
    • Connect
  • About Unity
    • About Us
    • Blog
    • Events
    • Careers
    • Contact
    • Press
    • Partners
    • Affiliates
    • Security
Copyright © 2020 Unity Technologies
  • Legal
  • Privacy Policy
  • Cookies
  • Do Not Sell My Personal Information
  • Cookies Settings
"Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
  • Anonymous
  • Sign in
  • Create
  • Ask a question
  • Spaces
  • Default
  • Help Room
  • META
  • Moderators
  • Explore
  • Topics
  • Questions
  • Users
  • Badges