Skip to content

Instantly share code, notes, and snippets.

@Xynonners
Xynonners / AHAA.gdshader
Last active April 4, 2025 16:28
new godot antialiasing (Absurd Hybrid Anti-Aliasing)
shader_type spatial;
render_mode unshaded, depth_prepass_alpha;
void vertex() {
POSITION = vec4(VERTEX, 1.0);
}
uniform sampler2D BackBufferTex : hint_screen_texture, repeat_disable, filter_nearest;
uniform sampler2D DepthBufferTex : hint_depth_texture, repeat_disable, filter_nearest;
@Xynonners
Xynonners / HHAA-D.gdshader
Last active April 4, 2025 15:59
gdshader HHAA implementation (spatial/depth AA)
shader_type spatial;
render_mode unshaded;
void vertex() {
POSITION = vec4(VERTEX, 1.0);
}
uniform sampler2D BackBufferTex : hint_screen_texture, repeat_disable, filter_nearest;
uniform sampler2D DepthBufferTex : source_color, hint_depth_texture, filter_nearest;
@Xynonners
Xynonners / LXAA.gdshader
Last active April 4, 2025 15:59
gdshader LXAA implementation, put in full rect ColorRect across entire screen
/* Fast antialiasing shader by G.Rebord (mod by Xynon for Godot)
Based on FXAA3 CONSOLE version by TIMOTHY LOTTES
------------------------------------------------------------------------------
THIS SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHOR OR CONTRIBUTORS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR
IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
============================================================================*/
@slok
slok / pprof.md
Last active March 29, 2025 10:36
Go pprof cheat sheet

Enable profiling

Default http server

import (
    _ "net/http/pprof"
    "net/http"
)
@wsgzao
wsgzao / rps.sh
Last active August 5, 2024 06:12
rps.sh
#!/bin/bash
# chkconfig: 2345 90 60
### BEGIN INIT INFO
# Provides: rps
# Required-Start: $local_fs $remote_fs $network $syslog
# Required-Stop: $local_fs $remote_fs $network $syslog
# Default-Start: 2 3 4 5
# Default-Stop: 0 1 6
# Short-Description: enable rps config for ubuntu
# Description: enabele rps which is a kernel tweak for network performance

Enable bbr on Ubuntu 16.04

  1. Make sure kernel version is 4.9 or newer:

    uname -r

    Install Hardware Enablement Stack (HWE) to update kernel automaticly:

@echo off
if not "%1"=="am_admin" (powershell start -verb runas '%0' am_admin & exit /b)
@rem *** Disable Some Service ***
sc stop DiagTrack
sc stop diagnosticshub.standardcollector.service
sc stop dmwappushservice
sc stop WMPNetworkSvc
sc stop WSearch

WannaCry|WannaDecrypt0r NSA-Cyberweapon-Powered Ransomware Worm

  • Virus Name: WannaCrypt, WannaCry, WanaCrypt0r, WCrypt, WCRY
  • Vector: All Windows versions before Windows 10 are vulnerable if not patched for MS-17-010. It uses EternalBlue MS17-010 to propagate.
  • Ransom: between $300 to $600. There is code to 'rm' (delete) files in the virus. Seems to reset if the virus crashes.
  • Backdooring: The worm loops through every RDP session on a system to run the ransomware as that user. It also installs the DOUBLEPULSAR backdoor. It corrupts shadow volumes to make recovery harder. (source: malwarebytes)
  • Kill switch: If the website www.iuqerfsodp9ifjaposdfjhgosurijfaewrwergwea.com is up the virus exits instead of infecting the host. (source: malwarebytes). This domain has been sinkholed, stopping the spread of the worm. Will not work if proxied (source).

update: A minor variant of the viru

@dmnsgn
dmnsgn / WebGL-WebGPU-frameworks-libraries.md
Last active April 20, 2025 19:36
A collection of WebGL and WebGPU frameworks and libraries

A non-exhaustive list of WebGL and WebGPU frameworks and libraries. It is mostly for learning purposes as some of the libraries listed are wip/outdated/not maintained anymore.

Engines and libraries ⚙️

Name Stars Last Commit Description
three.js ![GitHub
@gaoyifan
gaoyifan / uml-on-debian.md
Created November 21, 2016 14:37
User Mode Linux on Debian Jessie

User Mode Linux on Debian Jessie

host kernel version: 3.16.36-1+deb8u2

target kernel version: 4.9-rc5

Build UML kernel

Preparation