Timeline for How to render a texture in a unique color using SDL2?
Current License: CC BY-SA 4.0
11 events
when toggle format | what | by | license | comment | |
---|---|---|---|---|---|
Jul 26 at 13:17 | vote | accept | Gkcrafting | ||
Jul 26 at 13:17 | answer | added | Gkcrafting | timeline score: 1 | |
Jul 24 at 17:20 | comment | added | DMGregory♦ | Want to write up your solution as an Answer post below? I bet it would be extremely helpful to the next developer who's trying to solve a similar problem. | |
Jul 24 at 17:13 | comment | added | Gkcrafting | Nevermind, I found out it's possible to have some kind of "color variable" in Illustrator, I'll just have to define a single color and apply it to all the icons and then change it to my liking. Thanks! | |
Jul 23 at 22:30 | comment | added | DMGregory♦ | I don't see why that would pose a problem. Want to edit your question to include a sample of 2-3 sets of SVG code you're having trouble adjusting automatically? | |
Jul 23 at 21:06 | comment | added | Gkcrafting | I considered doing just that. But the issue is that the SVGs are slightly different from one another. For some it's the stroke that's black, for others it's the fill. But I saw online that it is also possible to achieve the expected result by grayscaling the loaded SVG but unfortunately, I don't know how to do so :| | |
Jul 23 at 20:53 | comment | added | DMGregory♦ | That should be possible to automate. If they're in plaintext SVG, you could do it with a regex search & replace using tools like Notepad++. | |
Jul 23 at 20:48 | comment | added | Gkcrafting | I tried to do so with one of them and it worked perfectly. But since I designed the icons myself, I'll have to recolor every single one of them, and they're about 125 :( | |
Jul 22 at 1:59 | comment | added | DMGregory♦ | Have you considered making your SVG inputs white (changing the SVG markup directly if you need to) then modulating the colour when you draw the textures to the screen using SetTextureColorMod? | |
S Jul 21 at 21:06 | review | First questions | |||
Jul 22 at 14:15 | |||||
S Jul 21 at 21:06 | history | asked | Gkcrafting | CC BY-SA 4.0 |