Really awesome shader. Are you perhaps planning on making something similair for Unity? :-)
bktGlitch is a glitch shader for GameMaker: Studio 2 that's gonna mess your game up in a rather visually pleasing way.
Originally released in August 2017 on the GameMaker: Marketplace, now free.
If you like this asset and can pay for it, please consider doing so.
Please give credit if used (but you don't have to if you paid for it, also it'd be cool if you let me know about your project, just curious).
GAMES USING THIS SHADER (tell me about yours!)
- Effects such as tearing, noise, colour dispersion, glitch blocks, RGB splitting...
- Written in GLSL ES - not limited to desktop platforms
- Easy-to-use setup scripts and presets, no need to set up uniforms manually!
- A demo where you can adjust all effects manually and even generate the resulting configuration code!
1.3.2 (January 2021):
- Fixed bugs, switched to new GML syntax.
1.3 (July 2020):
- Overall improvements to compatibility (code cleanup, use of internal noise texture, etc.), minor bug fixes
- Simplification of the API (please see the demo code for details on how you can port your existing code to this version of the shader)
- Dropped 1.4. support because I don't want to end up in an institution.
While the shader has been pretty much entirely rewritten, it should still behave as close to the original as possible.
Developed by Jan Vorisek (@odditica).
Click download now to get access to the following files:
Log in with itch.io to leave a comment.
Really awesome shader. Are you perhaps planning on making something similair for Unity? :-)
Just bought this, but I still gave you a shout out in my vlog for an upcoming game.Great effect!
I cant open my images.
Hello, it works perfect for me on windows but it seems to look pixelated on android. I have tested it on a number of high end devices. Do you know any solution? (My game is in 3D)
If you have suggestions on what functionality you'd like to see supported by this, don't hesitate to type them here. I may implement custom sprite drawing functions, but the main reason I don't really want to update this is because of how imperfect the existing code is (but I can't change it for compatibility reasons, so...), plus I don't really use GM any more these days.
Hi! I was wondering if there is any way to use this for the background layer only, like a filter?
Hi there! Is there an easy way I can apply the glitch effects to multiple objects at once without having to add a Draw GUI event to each object?
Hi! You should be able to get somewhat decent results by using the shader w/ standard sprite drawing functions (though you might have to use the provided asset API to set the shader resolution to match the sprite size), provided the sprite resides on its own texture page (you'll get bleed-in from atlas contents otherwise).
Hi. I really love this. Many thanks for all of your work on it. A (hopefully) quick question for you. I have an electrical enemy in my game and what I would like is for the display to get more glitchy the closer you get to the enemy and less as you back off. If you could give me some pointers on how to achieve that I would be forever grateful.
If you check the "simple example" object in the project, there's a line:
bktglitch_set_intensity(0.025 + bounceIntensity);
If you switch bounceIntensity to a variable that calculates how close you are to the enemy, you should be able to get that effect! I haven't tested it, but that should work.
This is great, amazing work! Amps up the quality of my game by heaps (will share with you once finished). I've got two questions though.
So I have heatwave shaders up and running on my Moto G6 Plus yet your glitch shader does not seem to work when running on my phone. On Windows it does run flawlessly, even in conjunction with my heatwave shaders. Do you have any thoughts on this problem?
Secondly I was wondering where I could find the code to disable or minimize the RGB shuffle effect as I'd like to keep the game minimalistic without messing with the colors.
Thanks a bunch and if I'll keep using this I will give credit and donate where due!
EDIT: I do use V1.2 as I still need to port my project to GMS2. This could maybe play a role?
Yes, the legacy version is known not to run well on phones. The GMS2 one is basically a complete rewrite that should work better across the board.
So I've updated to version 1.3.2 (GMS2, 188.8.131.526) and I'm running your shader on 1080x1920 to get it to work fullscreen (on a Moto G6 phone). The game runs on a steady 60 fps, yet when your shader is enabled it drops to around 27 - 30 fps. Is there a way to improve the framerate? Maybe by reducing the render resolution or quality or something in those lines? On Windows the FPS rocks a steady 60 with your shader enabled.
May I ask if you can support Unity? I feel very sorry for that. Unity has a large number of users, and I will buy it even if it is paid
I don't use Unity, so I can't as of now. I also don't consider the product to be good enough to warrant a fresh release on a different platform.
Really like your work! I've been using it in my project. But when I switch the compiler from VM to YYC, the display effect is completely different from what I expected when compiling with VM.
I checked the code, but can't find any problem. Is this because bktglitch doesn't support YYC or because some functions have changed in GMS 2.3?
If so, could you please make a update to support YYC and GMS 2.3? I think YYC is very necessary to protect the code.
Thanks for this is really good!! When i compile with VM all is good, but when i compile with YYC the noise color is black. Any idea?
This thing is excellent and I've been using it in a project for a while, but it looks like 2.3.1 of GM2 causes the shader to get messed up if game_restart(); is used after the shader has been activated once anywhere in the game. At that point, it's as if the settings for the shaders are corrupted and the effects don't look right until the game is re-compiled or the executable is run again.
I tried testing it in the demo and it occurs there as well. Not a huge deal, but I'm assuming something's changed within GM to make this happen and I can't seem to figure out how to fix it.
Hey, Where did u get the ThickPix2 font from .?
I made it, and it's there only for the purposes of the demo.
It isn't a "usable" part of the package.
Hello there - I went ahead and bought this shader, super impressed with it.
One question - I'm getting it to apply to individual sprites but I notice that it is picking up sprites next to them on the texture sheet when it's doing anything involving shifting (channel, line, etc). Should I be creating more space between objects on the texture sheet or is there a quick way to get bound the shader to the sprite's location on the texture sheet? I have a workaround where I'm not letting gamemaker crop.
Second question - I notice my parameters are all acting a lot different when I put the shader into my existing project. My resolution is 960x540 and it's looking like the noise texture that everything is based off of is way larger, looks like small squares on the sprites instead of noise. Is there an easy way to get everything set up so it acts more like the demo?
Hi. The shader is not really meant to be used to render individual sprites (not counting the obvious texture page issue, it would also require a custom draw_sprite function that would provide a large enough rasterised area for the "offset" effects not to be cut off). It's a full-scale post-processing effect. AFAIK, people usually get around this by using a big surface instead.
As for the resolution problem, by default the size of the application surface is used. If you need a different one, pass it via the arguments of the BktGlitch_activate function.
Hello! I would like to use BktGlitch, but I have a severe problem!
BktGlitch is all screwed up, when I open the project itself and modify it to be a game, the sprites are all jumbled, and when I try to import it in a non-BktGlitch project, It will become all red and I can't make anything out.
And yes I do have DirectX installed.
If you're still interested in making the shader work, please try out the new update.
Hello! I really like this and I'm very interested in potentially implementing it in a future project. I am completely new to GMS2; last time I used any version of Game Maker was before GMS existed and I didn't know anything back then, either.
What I'm wondering is if it's possible to use this on select portions of the screen instead of the whole screen (or alternatively, if it's possible to apply this shader to a single background layer and build overtop of it with tiles unaffected by the glitching); what I want to do with this is something kinda similar (aesthetically) to the glitch rooms in Axiom Verge where parts of the screen appear to be corrupted. I may have use of this either way; it's awesome looking and may inspire me to do other things with it, but I'd just like to find out if this is even possible before I go ahead and get in over my head.
The shader can be used on anything rendered by the GPU. In this case, the usual approach would be to render everything you'd like to have the effect applied to into a new surface, which you would then draw with the shader active.
Thanks very much!
I know it's a big ask, but if you know how to do this for GM2, would you mind demonstrating? You're probably a busy man, so I understand if you'd rather not.
Hi! There's a simple GMS2 example included in the project that demonstrates the usage of the shader with little code.
I saw, it looks great! But I was wondering if I could apply it to only a single object. I'm new to coding and GM2, I managed to get it to draw onto a surface, but the surface seems to be acting as a sort of window looking into a glitch effect that is the size of an entire screen.
I asked on the Gamemaker 2 forums, but nobody seems to know how to apply it to a single object.
The goal was to have an enemy glitch when they're shot, and I really want to use your shader for it, since it has so many options!
So basically, the issue is that the edges are getting cut off, even though my surface that I created is bigger than the object I want to draw the shader over.
maybe a dumb question but, I can use it in my own game that I'm making?
Yes, and yes. :)
Thanks for this! Would be nice if there was a complete tutorial on how to implement it for total noobs like me :p
Please read the comments provided in the code of the controller object, it's all explained in there!
Does this work on Gamemaker Studio 2?
Holy shit man this looks so awesome!!!
Hey man! I'm using your shader for a game of mine, the problem is, the shader is not working for android; the shader does not appear or do anything for android. What could be wrong?
If the demo doesn't work, your device is probably too old.
Looks like you're using the shader in your object draw calls instead of only when you're rendering the application surface.
Does the demo work?
Dude, you are awesome releasing this for free. Always wanted a glitch shader like this.
This is the reason I'm going back to Gamemaker, now I can finally make what I always wanted to make. Thank you blokatt! <3
(And I will credit you, for sure)
does this only work in gamer maker studio only...?
cuz i am using godot and want to know if this works in it...