Shader implementation in LÖVE and resources to study (+ shockwave and swirl shader attached)

Questions about the LÖVE API, installing LÖVE and other support related questions go here.
Forum rules
Before you make a thread asking for help, read this.
Rigachupe
Party member
Posts: 100
Joined: Fri Jun 18, 2021 11:21 am

Re: Shader implementation in LÖVE and resources to study (+ shockwave and swirl shader attached)

Post by Rigachupe »

Neat shader. I like it. Where is the thumbsup?
tourgen
Citizen
Posts: 53
Joined: Sat Mar 18, 2023 12:45 am

Re: Shader implementation in LÖVE and resources to study (+ shockwave and swirl shader attached)

Post by tourgen »

pgimeno wrote: Wed Aug 02, 2023 2:24 pm I found this entry from the Löve blog quite useful to start learning the basics: http://blogs.love2d.org/content/beginners-guide-shaders
I agree. It's a good introduction to shaders in the context of Love2D. A great starting place.

I've been using #pragama language glsl3, but I'm about to start writing GLSL ES with Love2D for this Dragon tablet (android) I have laying around and I wonder how much I will have to change because, for example, I used Texture2D() instead of the Love2D shader function name.
User avatar
slime
Solid Snayke
Posts: 3172
Joined: Mon Aug 23, 2010 6:45 am
Location: Nova Scotia, Canada
Contact:

Re: Shader implementation in LÖVE and resources to study (+ shockwave and swirl shader attached)

Post by slime »

texture2D() is not a valid function in GLSL 3, on desktop or on phones. The equivalent would be texture() (which also supports many different sampler types as inputs instead of just 2D ones).

love's Texel() function always works no matter the version, since it picks whether to use texture() or texture2D() depending on the active version.

love's shader entry point functions (vec4 effect, etc.) are the same no matter the version. GLSL 3 allows you to use some shader entry point functions that aren't available in GLSL 1.
Post Reply

Who is online

Users browsing this forum: No registered users and 6 guests