Defragments - a library of Defold shaders

It would be great if we could have a library of working shaders with examples in Defold, what do you think about such initiative?

@britzl started a great library: https://github.com/britzl/lumiere,

@Pkeod has a great library: https://github.com/subsoap/deffx

@Vincent introduced a blur shader: Blur shader example

@aglitchman shared awesome trails effects: Hyper Trails - customizable trail effect

I hope you’ll find time to develop further, guys :wink:


I’m not so advanced in shaders, but I have adopted few 2D shaders from Shadertoy for post-processing of a single image (I think they should work on 3D render too) based on Shadertoy examples (links in fragment programs).
I hope it would be great for new devs who would like to apply some cool effects! :slight_smile:

Because those are modified fragment programs I’m calling them:

Defragments:


(Logo made with designevo)

Defragments is just a library of simple examples with fragment programs from Shadertoy adopted to work in Defold. Fragment programs are modifying a sprite in post-processing.



It is available to download here and contributions are welcome :smiley: :

https://github.com/paweljarosz/defragments/tree/master


I’ve made examples in a form of game objects, so you can just replace the main go with other and build for instant result:

29 Likes

I have the latest Defold… I downloaded the top two Lumiere and deffx.

when I try to load the game.project… Defold closes.

Is it just me ?

Do you perhaps have any more info?

Versio 1.2.1.169 running on Windows 10

Click “open from disk”

Select lumiere-master\game.project

Defold closes…

New Log file below…

editor2.2020-06-12.zip (4.2 KB)

Something to do with the path length perhaps ? I have defold installed off of my desktop directory.

1 Like

I moved Defold… to a shorter path… seems to load the project now… perhaps this is an error that should be caught.:innocent:

Lumerie project when I run it comes up with an error missing
…local outline = require “lumiere.effects.outline.outline”

DefFx - When I run it I see a little sprite bobbing up and down… no matter what I click or press not much else happens.

1 Like

@Pawel

How did you add a property to a Game Object itself??

Can you explain to me how you achieved this:

Screenshot 2024-11-23 at 00.08.48

This is crazy… :grinning_face_with_smiling_eyes:

Isnt that the path to the game object itself? This means it is a game object stored as a file on disk.

1 Like

Actually, interestingly, none of these ‘properties’ are owned by the game object. If you double click the GO, so it opens in the outline, they all vanish. These are properties of the collection that relate to the GO; you can’t add a property to a GO. If you want to add a component to a GO: right click.

I don’t know, guys… :smile_cat:
I see the game object in the outline is cursive written… Has that any meaning?

@britzl Isnt that the path to the game object itself? This means it is a game object stored as a file on disk.

Maybe. And how should that work? Any other game objects have no path property.
This is the first time I’ve seen this. Where does this come from? :clown_face:

That shows up when the object was created outside the collection and then added to it (via Add Game Object File), rather than being created directly inside the collection (via Add Game Object).

1 Like

Yeah, that’s it. Thank you for pointing this out. I’ve tried it myself and it’s true.
Certainly, the ‘path’ thing is very helpful. Good to know. Thanks again. :wink: