Wayback Machinekoobas.hobune.stream
May JUN Jul
Previous capture 12 Next capture
2021 2022 2023
1 capture
12 Jun 22 - 12 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
1
Question by raggi · Apr 17, 2010 at 03:40 PM · transparencymovietexture

is there a good way to make a transparent video in unity ?

hey guys. im making a 2d plattformer game. the plan was to use sprite manager for most of the animation but now im running into trouble with size issues. I got the idea to just export them as video files and use them as textures on planes. the alpha layer dose not seem to be supported in the format that unity converts the video into, but I got a simular effect with some bending mode but then I also let the background trough all the dark spots in the animation. is there a better way to get the transparency on a video texture?

-raggi

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

4 Replies

· Add your reply
  • Sort: 
avatar image
2

Answer by Dreamora · Jun 13, 2010 at 12:46 AM

Alternatively, as recommended in other answers and on the board, you can use 2 movies and encode your alpha data as grayscale movie in the second one. Then you can use both movie in parallel and utilize the second one as alpha channel provider for the first one in a correspondingly created shader

Just as a sidenote (due to the genre): on the iphone, movie textures don't exist at all, there movie is automatically fullscreen.

Comment
Add comment · Show 1 · 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 $$anonymous$$ · Aug 09, 2012 at 04:10 PM 0
Share

I've tried doing this same approach. It works, as in the two videos work where one acts as the alpha input to the other. But they are out of synch. Which is a huge problem.

I'm currently trying an approach in where I have both the rgb and alpha videos both on the same video on top of each other. Ins$$anonymous$$d of playing two videos I'm just playing this one video and offsets the uvs in the shader. Hope it works. Otherwise I'm out of ideas. (the current idea that I'm working on is not $$anonymous$$e by the way. I borrowed it from someone in the forum.)

avatar image
0

Answer by Horsman · Apr 17, 2010 at 05:13 PM

Try using a shader that cuts out values that are some rediculous color like complete magenta instead of black.

Comment
Add comment · Show 1 · 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 DaveA · Dec 05, 2012 at 08:39 PM 0
Share

I have such a shader, about to put on Asset Store, but if you'd like to beta test it, I can set you up.

avatar image
0

Answer by 3dShark · Dec 05, 2012 at 08:15 PM

I use a GUI to display the movie.

 function OnGUI() {
     if (wasClicked) {  //object was clicked display movie.
     
     GUI.color.a = 0.75;
     if (GUI.Button (Rect (610,210,640,360), movie)) {
 }
 
 Making the GUI transparent, and also making the movie texture transparent.
Comment
Add comment · Show 1 · 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 Tanoshimi2000 · Apr 08, 2014 at 12:09 PM 0
Share

Using the GUI seems smart. I would have thought you could just put a $$anonymous$$ovieTexture on it, and also another texture that's just 50% alpha, and it would work, ins$$anonymous$$d of two full movies as people are suggesting.

3dShark: How can you post a GUI in a particular 3d space? I have a video of a checkered flag you drive through to end the race, and want it translucent. Right now it's a box with texture, but if I made it a GUI, how do I make it stay in one location 3d, not 2d?

avatar image
0

Answer by Afassolas · Dec 16, 2015 at 06:43 PM

Use Particles Additive and texture the video for transparent background, play a bit with the alpha

Comment
Add comment · 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

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

5 People are following this question.

avatar image avatar image avatar image avatar image avatar image

Related Questions

How do I use Movie Texture with alpha channel? 4 Answers

DrawProcedural() in OnPostRender() drawing over transparent objects 1 Answer

Alpha Transparent Shader hides NGUI fonts 0 Answers

Transparent shader with depth writes 3 Answers

Unity making existing shader partially transparent 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