Wayback Machinekoobas.hobune.stream
May JUN Jul
Previous capture 11 Next capture
2021 2022 2023
1 capture
11 Jun 22 - 11 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
3
Question by Linck · Jul 15, 2015 at 07:20 PM · uibuttonoutline

How to do big white outlines on unity UI?

I want to make an outline on some buttons, and these buttons have different shapes. I was doing a test with the Outline component (Add Component > UI > Effects > Outline), and turns out its actually copying the button image four times behind my button and multiplying a color on it. So I can't change this color to white because that would leave these four images as is. Also if I set the effect distance too high (like more than 4), It'll start to become weird.

Here's an image to illustrate outline

Is there any other solution that I can make an outline the way I want? Something more like the photoshop stroke effect. Something that actually work with the pixels.

outline.png (187.3 kB)
Comment
Add comment · Show 3
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 Rad-Coders · Jul 16, 2015 at 09:17 PM 1
Share

Why not just make a second image with an outline. Tell us what you are intending on doing. Is it for changing when mouse is over the ui element or what? Tell us a bit more.

avatar image Linck · Jul 17, 2015 at 12:22 PM 1
Share

I just want to make a button. The up state is just an image, and the over is the image outlined in white with a little panel with text under. Second image with outline would work good enough I guess, thanks for the idea.

avatar image joaobsneto · Jan 05, 2016 at 05:41 AM 0
Share

I'm having the same issue. I think outline was intended to work properly with Text not Image. I have not found any good solution so far, but there is this topic on the forum that might help: http://forum.unity3d.com/threads/outline-glow-effect-for-2d-sprite.274188/

1 Reply

· Add your reply
  • Sort: 
avatar image
2

Answer by drakmail · Oct 27, 2017 at 07:41 PM

Hackish way - create a clone of the sprite with larger scale (for ex. 1.1) and custom material with GUI / Text Shader shader.

Custom material: custom material


снимок-экрана-2017-10-27-в-223812.png (49.7 kB)
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

Pls. Help how can I convert this script to be press using UI buttons. I want the vertical to be pressed and the for the horizontal I will make 2 arrows left and right. Thank you in advance 0 Answers

Scripting button functionality inside class with created object's method 1 Answer

How to draw GUI texture under UI elements? 0 Answers

My function is called twice on single click 2 Answers

UI drag and drop 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