Skip to content

Instantly share code, notes, and snippets.

View frytaz's full-sized avatar
😁
if true

Marcin frytaz

😁
if true
View GitHub Profile
@frytaz
frytaz / PS1Material.ts
Created June 8, 2025 21:30 — forked from bandinopla/PS1Material.ts
ThreeJs Shader to create a Playstation 1 Type effect
/**
"by/composed by": https://x.com/bandinopla
Based on article by Roman Liutikov: https://romanliutikov.com/blog/ps1-style-graphics-in-threejs
Modifications done with DeepSeek: https://chat.deepseek.com/
*/
import * as THREE from 'three';
export class PS1Material extends THREE.ShaderMaterial {
constructor({ map, color }: { map: THREE.Texture, color:THREE.ColorRepresentation }) {
super({
@frytaz
frytaz / script-template.sh
Created December 15, 2020 14:58 — forked from m-radzikowski/script-template.sh
Minimal safe Bash script template - see the article with full description: https://betterdev.blog/minimal-safe-bash-script-template/
#!/usr/bin/env bash
set -Eeuo pipefail
cd "$(dirname "${BASH_SOURCE[0]}")" >/dev/null 2>&1
trap cleanup SIGINT SIGTERM ERR EXIT
usage() {
cat <<EOF