x

Search in
Sort by:

Question Status:

Search help

  • Simple searches use one or more words. Separate the words with spaces (cat dog) to search cat,dog or both. Separate the words with plus signs (cat +dog) to search for items that may contain cat but must contain dog.
  • You can further refine your search on the search results page, where you can search by keywords, author, topic. These can be combined with each other. Examples
    • cat dog --matches anything with cat,dog or both
    • cat +dog --searches for cat +dog where dog is a mandatory term
    • cat -dog -- searches for cat excluding any result containing dog
    • [cats] —will restrict your search to results with topic named "cats"
    • [cats] [dogs] —will restrict your search to results with both topics, "cats", and "dogs"

Crosshair Draw Texture - White instead of Transparent

Here is the very simple crosshair I created in illustrator/photoshop: alt text

I exported it as TGA (which I've read is the best format?) and imported it into UE4. Here is the imported texture: alt text

Here is my HUD blueprint that draws the crosshair: alt text

Here is a screenshot of the game in play. Notice that the transparent pixels are white :s alt text

I have tried playing around with the Blend Mode of the Draw Texture Node. When selecting "Modulate" I am able to make the white pixels transparent but the whole crosshair disappears when I look at anything dark.

I need 100% opacity on the green pixels and (obviously) 0% opacity on the transparent pixels. Why isn't UE4 handling the transparent pixels properly?

Thank you very much in advance!

Product Version: UE 4.7
Tags:
crosshairss.png (7.0 kB)
crosshairue41.png (144.3 kB)
crosshairue42.png (107.5 kB)
crosshairrue43.png (67.2 kB)
more ▼

asked May 22 '15 at 11:42 PM in Blueprint Scripting

avatar image

tehhax
199 31 29 51

(comments are locked)
10|2000 characters needed characters left
Viewable by all users

1 answer: sort voted first

I feel like it took unnecessarily long to figure out how to do this. I am going to answer my own question in hopes that it will help someone else later. This may not be the best solution but it works perfectly for me. I just used "Draw Texture Simple" node instead and it can take a png file no problem. alt text

If you want to use the Draw Texture node instead of the "simple" version, you will need to deal with Alphas to create transparency.

Hope this saves someone time in the future!

more ▼

answered May 23 '15 at 04:46 AM

avatar image

tehhax
199 31 29 51

avatar image Bluntmaster Sep 25 '15 at 05:46 PM

Thank You this helped me alot.

(comments are locked)
10|2000 characters needed characters left
Viewable by all users
Your answer
toggle preview:

Up to 5 attachments (including images) can be used with a maximum of 5.2 MB each and 5.2 MB total.

Follow this question

Once you sign in you will be able to subscribe for any updates here

Answers to this question