Pixel level operations

For questions about using Classic.

Post » Fri Jan 23, 2009 7:04 pm

I would like play with custom 2d effects and small filters apps, not for games. Is it possible in construct? Things like: for each pixel do, get color, do calculations, set a color.
How can I get an RGB color from a specific pixel?
Any advice is wellcome :roll:
B
30
S
15
G
10
Posts: 285
Reputation: 7,144

Post » Fri Jan 23, 2009 7:30 pm

The best way to do this is by writing a custom pixel shader effect, because these run really quickly on the graphics card. See Pixel Shaders.
Scirra Founder
B
359
S
214
G
72
Posts: 22,952
Reputation: 178,600

Post » Fri Jan 23, 2009 7:37 pm

So there's no way to get the color of a pixel otherwise? I'm making a paint program, and it would be handy.
Moderator
B
88
S
32
G
33
Posts: 3,005
Reputation: 27,432

Post » Sat Jan 24, 2009 8:26 pm

Any recommended site to learn about pixel shader?
B
30
S
15
G
10
Posts: 285
Reputation: 7,144

Post » Sun Jan 25, 2009 2:14 pm

[quote="Aritz":2qfm0e3u]Any recommended site to learn about pixel shader?[/quote:2qfm0e3u]

I learnt the basics from this site [url:2qfm0e3u]http://www.facewound.com/tutorials/shader1/[/url:2qfm0e3u]

But you'll want to take a look at some of the existing .FX files in the construct/effects folder to get an idea of how they're laid out for Construct's specific use. :)
B
2
S
1
G
5
Posts: 59
Reputation: 1,518

Post » Sun Jan 25, 2009 6:06 pm

Aye, anything intensive (what size images are these?) should be offloaded off processors. Graphics cards are more efficient at these sort of things. Although, I have no clue as to how fast it will perform on integrated VS a modern processor; especialy if you're on vista, which LOVES to throttle the hell out of integrated GPU's unless you know how to set it up.
B
1
G
3
Posts: 7
Reputation: 839

Post » Mon Jan 26, 2009 10:31 am

Thanks for the responses. BenH, thanks for the link. I have been searching at Google but i have founded only very technical stuff. This seams to be more "readable" :D. I'm learning from Construct's fx files too.
B
30
S
15
G
10
Posts: 285
Reputation: 7,144


Return to Help & Support using Construct Classic

Who is online

Users browsing this forum: No registered users and 7 guests