Skip to content

Instantly share code, notes, and snippets.

View veacks's full-sized avatar

Valentin Dubois veacks

  • Plan Net Pulse
  • Barcelona
View GitHub Profile
// code updates are now there:
// https://github.com/Bleuje/processing-animations-code/blob/main/code/radialcollapse/radialcollapse.pde
// Processing code by Etienne JACOB
// motion blur template by beesandbombs
// opensimplexnoise code in another tab is be necessary
// --> code here : https://gist.github.com/Bleuje/fce86ef35b66c4a2b6a469b27163591e
// See the license information at the end of this file.
// View the rendered result at: https://bleuje.com/gifanimationsite/single/radialcollapse/
@ayamflow
ayamflow / rotate-uv.glsl
Created January 16, 2018 23:24
Rotate UV in GLSL
vec2 rotateUV(vec2 uv, float rotation)
{
float mid = 0.5;
return vec2(
cos(rotation) * (uv.x - mid) + sin(rotation) * (uv.y - mid) + mid,
cos(rotation) * (uv.y - mid) - sin(rotation) * (uv.x - mid) + mid
);
}
vec2 rotateUV(vec2 uv, float rotation, vec2 mid)
@dolanor
dolanor / volumetric-clouds.glsl
Created September 30, 2016 11:09
Volumetric clouds GLSL webGL
// Created by inigo quilez - iq/2013
// License Creative Commons Attribution-NonCommercial-ShareAlike 3.0 Unported License.
// Volumetric clouds. It performs level of detail (LOD) for faster rendering
float noise( in vec3 x )
{
vec3 p = floor(x);
vec3 f = fract(x);
f = f*f*(3.0-2.0*f);
@bellbind
bellbind / fragment.glsl
Last active January 31, 2024 14:56
[webgl2]example for webgl2 (with glsl3)
#version 300 es
precision highp float;
//invariant gl_FragCoord;
uniform Screen {
vec2 wh;
} screen;
uniform Timer {
int count;
@cludden
cludden / howto-installing-vault-on-aws-linux.md
Created February 3, 2016 00:30
HOWTO: Installing Vault on AWS Linux

HOWTO: Installing Vault On AWS Linux

This is quick howto for installing vault on AWS Linux, mostly to remind myself. At the end of this tutorial, you'll have a working vault server, using s3 for the backend, self signed certificates for tls, and supervisord to ensure that the vault server is always running, and starts on reboot.

Setting up S3

First things first, let's set up an s3 bucket to use as the storage backend for our s3 instance.

  1. From the AWS Mangement Console, go to the S3 console.

  2. Click on the Create Bucket button

package net.atos.sparti.pub
import java.io.PrintStream
import java.net.Socket
import org.apache.commons.pool2.impl.{DefaultPooledObject, GenericObjectPool}
import org.apache.commons.pool2.{ObjectPool, PooledObject, BasePooledObjectFactory}
import org.apache.spark.streaming.dstream.DStream
class PooledSocketStreamPublisher[T](host: String, port: Int)
@jamiekurtz
jamiekurtz / mongo-enc-provision.sh
Created October 17, 2014 21:55
Shell script for installing and configuring MongoDB on Ubuntu to use a secondary LUKS (dm-crypt) encrypted disk for its database files.
#!/bin/bash
# !!! This script assumes that the device needing to be formatted and encrypted is /dev/sdb
# !!! Also... be sure to copy and store the generated encryption key file from /root
# Note that the secondary drive will be mounted at /var/lib/mongodb,
# ... which is the default location for MongoDB data files on Ubuntu and Mongo at least v2.6
# add PPA for mongodb
@codeinthehole
codeinthehole / docker-osx-shared-folders.rst
Last active November 11, 2023 01:22
How to share folders with docker containers on OSX

How to share a folder with a docker container on OSX

Mounting shared folders between OSX and the docker container is tricky due to the intermediate boot2docker VM. You can't use the usual docker -v option as the docker server knows nothing about the OSX filesystem - it can only mount folders from the boot2docker filesystem. Fortunately, you can work around this using SSHFS.

@mschoch
mschoch / elasticsearch-couchbase.Dockerfile
Last active January 2, 2016 20:59
Dockerfile for elasticsearch-couchbase-transport
FROM mschoch/elasticsearch:0.90.5
MAINTAINER Marty Schoch "marty.schoch@gmail.com"
# install elasticsearch-couchbase-transport
RUN /usr/share/elasticsearch/bin/plugin -install transport-couchbase -url http://packages.couchbase.com.s3.amazonaws.com/releases/elastic-search-adapter/1.2.0/elasticsearch-transport-couchbase-1.2.0.zip
# install the couchbase index template
RUN mkdir -p $CONF_DIR/templates
RUN echo '{"couchbase":' >> $CONF_DIR/templates/couchbase.json
RUN cat /usr/share/elasticsearch/plugins/transport-couchbase/couchbase_template.json >> $CONF_DIR/templates/couchbase.json
@yethee
yethee / app.foomodule.bar.js
Created September 15, 2012 19:47
Prototype of lazy-load a module of Marionette
App.module("FooModule.Bar", {
startWithApp: false,
define: function() {
// Code of submodule
}
});