- Emil Persson @Humus
- Matt Pettineo @mynameismjp
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#ifdef PSXDTH | |
#else | |
#define PSXDTH | |
//PS1 Hardware Dithering & Color Precision Truncation Function | |
//by ompu co | Sam Blye (c) 2020 | |
//PS1 dither table from PSYDEV SDK documentation |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//============================================================================================================================== | |
// An optimized AMD FSR's EASU implementation for Mobiles | |
// Based on https://github.com/GPUOpen-Effects/FidelityFX-FSR/blob/master/ffx-fsr/ffx_fsr1.h | |
// -- FsrEasuSampleH should be implemented by calling shader, like following: | |
// half3 FsrEasuSampleH(float2 p) { return MyTex.SampleLevel(LinearSampler, p, 0).xyz; } | |
//============================================================================================================================== | |
void FsrEasuL( | |
out AH3 pix, | |
AF2 ip, | |
AF4 con0, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#define STB_IMAGE_IMPLEMENTATION | |
#define STB_IMAGE_WRITE_IMPLEMENTATION | |
#define STBI_ONLY_PNG | |
#define STBI_ONLY_JPEG | |
#define STBI_ONLY_BMP | |
#define STBI_ONLY_GIF | |
#include "stb_image.h" | |
#include "stb_image_write.h" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Context: https://answers.unrealengine.com/questions/887556/view.html | |
// This post references a key commit here: https://github.com/EpicGames/UnrealEngine/commit/c4ea32533ee98508ab68038488a09b3a12d54cd4#diff-73715a20583ca5ead5c94c9183679d47 | |
// This change forces evaluation to complete, before updating the animation class. | |
// This happens during ClearAnimScriptInstance - BUT - the code path to this change, is not special. | |
// That means it should be valid to do this BEFORE calling clear, i.e before even calling SetAnimInstanceClass itself! | |
// So that's what we do. We simply wrap SetAnimInstanceClass in a function we can call, | |
// and inside that function we ensure evaluation is complete. This fixes it for me in all my use cases! | |
// Requires: | |
// - C++ in your project. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//A simple example of a github webhook using node.js | |
//To correctly set up: | |
// Inside a file named `.env`, in the same directory the app runs, | |
// place a line with WEBHOOK_SECRET='...' | |
// The secret value must match the secret you give github on their UI. | |
//That's it. run with `node app.js` and point github at <url>/mywebhook. | |
//(Prbably put it behind nginx if you do make it public facing) | |
'use strict'; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@-moz-document url("https://tweetdeck.twitter.com/"), url("https://tweetdeck.twitter.com/#") { | |
body { background-color:#000 } | |
html.dark .stream-item { background-color:#161619; border-bottom: solid 1px #000; } | |
html.dark .column { background-color:#161619; } | |
html.dark, html.dark body { background-color:#161619; } | |
html.dark .column-header, html.dark .column-header-temp { background-color:#000; } | |
html.dark .app-columns-container { background-color:#000 } | |
html.dark .column-message { background-color:#000 } | |
html.dark .column-title-edit-box { background-color:#212124 } | |
html.dark .column-nav-item { background:transparent; } |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
THIS_FOLDER="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" | |
# basically ./actual_binary but using a proper path | |
"${THIS_FOLDER}/actual_binary" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class Main extends luxe.Game { | |
override function config(config:luxe.GameConfig) { | |
config.preload = PreloadAssets.parcel; | |
return config; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
float r = sample.r; | |
float g = sample.g; | |
float b = sample.b; | |
float median = max(min(r, g), min(max(r, g), b)); | |
float signed_dist = median - 0.5; | |
float d = fwidth(signed_dist); | |
float opacity = smoothstep(-d, d, signed_dist); | |
//apply opacity to final alpha | |
color.a *= opacity; |
NewerOlder