Skip to content

Instantly share code, notes, and snippets.

View doppioslash's full-sized avatar

Claudia Doppioslash doppioslash

View GitHub Profile
@runevision
runevision / Unity versions not affected by Unity Runtime Fee.md
Created September 14, 2023 09:45
Unity versions not affected by Unity Runtime Fee

Unity versions not affected by Unity Runtime Fee

This is information that has been dug up by me and others in the Unity community. It's not official information from Unity (but most of the linked resources are). It is also not legal advise. I am not a lawyer.

TLDR:

Contrary to what Unity themselves are saying, for games made with these Unity versions, developers can elect not to be affected by a newer version of the Terms of Service that introduces the Unity Runtime Fee:

  • Unity 2022.x or earlier
  • Unity 2021.x LTS or earlier
@h3r2tic
h3r2tic / raymarch.hlsl
Last active March 7, 2024 18:56
Depth buffer raymarching for contact shadows, SSGI, SSR, etc.
// Copyright (c) 2023 Tomasz Stachowiak
//
// This contribution is dual licensed under EITHER OF
//
// Apache License, Version 2.0, (http://www.apache.org/licenses/LICENSE-2.0)
// MIT license (http://opensource.org/licenses/MIT)
//
// at your option.
#include "/inc/frame_constants.hlsl"
@sleepyfox
sleepyfox / 2022-06-22-the-problem-with-AI-coders.md
Created January 9, 2023 13:12
The problem with AI coders
author: @sleepyfox
title: The problem with AI coders
date: 22-Jun-2022

The problem with AI coders

The problem with 'solutions' like GitHub's Copilot, and similar tech, is that it frames the problem as a problem of search. The programmer is searching for some code that does a thing (produce a HTML table with alternating coloured background rows of green and red), and that they just need to find that thing. Machine Learning has had success in this area, just look at Google's page-rank 'algorithm'.

@repi
repi / crate-health.md
Last active February 22, 2024 01:17
Guidelines on evaluating health & quality of third-party crates at Embark

What to evaluate and consider before adding usage of new third-party crates.

These are not exact requirements but questions to investigate and discuss to help reason around the health, safety, maintainability, and more around crates.

This can also be read as an opinionated guide for crate authors of what our (Embark's) guidelines and recommendations are, though should not be taken too literally.

Legend: 🔒 Must have, ⭐️ Should have, 👍 Nice to have, ℹ️ Info

@chase-lambert
chase-lambert / three_core.cljs
Last active October 18, 2022 01:53
three.js -> cljs demo
(ns three.core
(:require ["three" :as three]))
(defn make-animation-fn [renderer mesh scene camera]
(fn animation [time]
(set! (.. mesh -rotation -x) (/ time 2000))
(set! (.. mesh -rotation -y) (/ time 2000))
(.render renderer scene camera)))
(defn cube []
@karpathy
karpathy / stablediffusionwalk.py
Last active March 29, 2024 09:33
hacky stablediffusion code for generating videos
"""
stable diffusion dreaming
creates hypnotic moving videos by smoothly walking randomly through the sample space
example way to run this script:
$ python stablediffusionwalk.py --prompt "blueberry spaghetti" --name blueberry
to stitch together the images, e.g.:
$ ffmpeg -r 10 -f image2 -s 512x512 -i blueberry/frame%06d.jpg -vcodec libx264 -crf 10 -pix_fmt yuv420p blueberry.mp4
@h3r2tic
h3r2tic / kajiya-all-the-jiggarays.md
Last active May 22, 2022 00:22
kajiya ray count breakdown

There are two types of rays being traced: shadow and "gbuffer". The latter return gbuffer-style information from hit points, and don't recursively launch more rays. Lighting is done in a deferred way. There is just one light: the sun.

  • irradiance cache: usually fewer than 16k cache entries:

    • main trace: 4/entry * (1 gbuffer ray + 1 shadow ray for the sun)
    • restir validation trace: 4/entry * (1 gbuffer ray + 1 shadow ray for the sun)
    • accessibility check: 16/entry short shadow rays
  • sun shadow pass: 1/pixel shadow ray

  • final gather done at half-res; every third frame is a ReSTIR validation frame, and instead of tracing new candidates, it checks the old ones, and updates their radiance. in addition to that, the validation frame also traces very short contact rays; on paper it seems like it would be doing more work, but it's actually slightly cheaper, so I'm counting conservatively here:

@rupsis
rupsis / osx_blender_debug.md
Last active November 26, 2022 23:00
OSX VS code Blender Setup

Building / Debugging Blender

Building blender for OSX

At the moment, I use VS code to build / debug blender. This video is great to get started on the internals of blender.

VS code task.json:

@dwilliamson
dwilliamson / ModifiedMarchingCubes.js
Created February 8, 2022 16:20
Transvoxel's Modified Marching Cubes Lookup Tables
//
// Lookup Tables for Transvoxel's Modified Marching Cubes
//
// Unlike the original paper (Marching Cubes: A High Resolution 3D Surface Construction Algorithm), these tables guarantee
// a closed mesh "whose connected components are continuous and free of holes."
//
// Rotations are prioritised over inversions so that 3 of the 6 cases containing ambiguous faces are never added. 3 extra
// cases are added as a post-process, overriding inverses through custom-build rotations to eliminate the rest.
//
// Uses the exact same co-ordinate system as https://gist.github.com/dwilliamson/c041e3454a713e58baf6e4f8e5fffecd
@cannibalox
cannibalox / ls-twitter-embed.user.js
Last active February 16, 2024 05:46
[userscript] logseq twitter embed
// ==UserScript==
// @name ls-twitter-embed
// @namespace https://gist.github.com/cannibalox/e75fe2f2ecc0de08a13025a559e166cd
// @version 0.1
// @description fetch tweets from url
// @author ported to logseq from louis kirsch's dynalist userscript
// @match https://logseq.com/*
// @grant GM.xmlHttpRequest
// @run-at document-end
// @require http://code.jquery.com/jquery-3.4.1.min.js