Welcome,
Guest
. Please
login
or
register
. Did you miss your
activation email?
French forum
Home
Help
Search
Login
Register
SFML community forums
»
Help
»
Graphics
»
Creating a partially see-through sprite
Print
Pages: [
1
]
Author
Topic: Creating a partially see-through sprite (Read 2372 times)
0 Members and 1 Guest are viewing this topic.
TheGoldenFyre
Newbie
Posts: 18
Creating a partially see-through sprite
«
on:
November 07, 2015, 04:31:04 pm »
Hi!
I'm trying to create a sprite where certain areas in the sprite are see-through. Is this possible? I can't find any other forum posts about it...
(Sorry if it's really obvious... Newbie to SFML
)
Please help!
Logged
zsbzsb
Hero Member
Posts: 1409
Active Maintainer of CSFML/SFML.NET
Re: Creating a partially see-through sprite
«
Reply #1 on:
November 07, 2015, 04:57:32 pm »
You need to utilize the alpha channel in whatever program you are using to create your textures and save your texture with the png format.
Logged
Motion / MotionNET
- Complete video / audio playback for SFML / SFML.NET
NetEXT
- An SFML.NET Extension Library based on
Thor
Resethel
Newbie
Posts: 22
Re: Creating a partially see-through sprite
«
Reply #2 on:
November 08, 2015, 12:57:45 am »
You can also load an image, set a mask from a color then load a texture from this image and apply it to your sprite.
But it's definitely easier to do as zsbzsb said
Logged
TheGoldenFyre
Newbie
Posts: 18
Re: Creating a partially see-through sprite
«
Reply #3 on:
November 08, 2015, 09:20:24 am »
Thanks for the help! I created a mask and that worked out fine.
Logged
Print
Pages: [
1
]
SFML community forums
»
Help
»
Graphics
»
Creating a partially see-through sprite
anything