Skip to content

Instantly share code, notes, and snippets.

Avatar
🔨
Happy to Build

Brendon Smith seacloud9

🔨
Happy to Build
View GitHub Profile
@seacloud9
seacloud9 / gist:c4d95e1ee3baa8ae946741e1db7ad8b2
Created Apr 15, 2019
launch.json -> vs code ssr debugging babel 7
View gist:c4d95e1ee3baa8ae946741e1db7ad8b2
{
// Use IntelliSense to learn about possible attributes.
// Hover to view descriptions of existing attributes.
// For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
"version": "0.2.0",
"configurations": [
{
"type": "node",
"request": "launch",
"name": "Debug",
@seacloud9
seacloud9 / index.html
Created Sep 3, 2018
shadertoy in three.js
View index.html
<!-- THIS is OPENGL Shading language scripts -->
<script id="vertex-shader" type="no-js">
void main() {
gl_Position = vec4( position, 1.0 );
}
</script>
<!-- orinal from https://www.shadertoy.com/view/Ms2SD1 -->
<script id="fragment-shader" type="no-js">
#ifdef GL_ES
precision mediump float;
@seacloud9
seacloud9 / layers_to_sprite_sheet.js
Created Sep 30, 2017 — forked from jessefreeman/layers_to_sprite_sheet.js
This is a PS script to make Sprite Sheets out of layers. Modified from http://www.garagegames.com/community/blogs/view/11527
View layers_to_sprite_sheet.js
// Put this file in Program Files\Adobe\Photoshop\Presets\Scripts\
// In PhotoShop menu File > Automate > Scripts: layersToSprite.js
// Arrange layers into a sprite sheet.
if (documents.length > 0)
{
// --------------------------
docRef = activeDocument;
View avaJS question
function makeRequest(){
const auth0BaseURL = Config.AUTH_URL
const mock = { username: 'test03@222222.com', password: 'password!test', deviceTesting: true }
const data = {'client_id': Config.AUTH_CLIENT, 'username': mock.username, 'password': mock.password, 'connection': '', 'device': 'testdevice', 'scope': ''}
const api = apisauce.create({
baseURL: authBaseURL,
headers: {'content-type': 'application/json'},
timeout: 100000
})
debugger
View Blender3D parent script
import bpy
scene = bpy.context.scene
for ob in scene.objects:
if ob.name.startswith("Curve"):
ob.parent = bpy.data.objects['mossbeach']
View Blender3d Extrude
import bpy
import bmesh
scene = bpy.context.scene
for ob in scene.objects:
if ob.name.startswith("Curve"):
curve = ob.data
curve.dimensions = '2D'
curve.extrude = 0.04
@seacloud9
seacloud9 / framework-sizes.md
Created Sep 7, 2016 — forked from Restuta/framework-sizes.md
Sizes of JS frameworks, just minified + minified and gzipped
View framework-sizes.md

Below is the list of modern JS frameworks and almost frameworks – Angular, Ember and React.

All files were downloaded from https://cdnjs.com and named accordingly. Output from ls command is stripped out (irrelevant stuff)

As-is (minified)

$ ls -lhS
566K Jan  4 22:03 angular2.min.js
@seacloud9
seacloud9 / KafkaFeed.scala
Created Aug 31, 2016 — forked from stefanobaghino/KafkaFeed.scala
Pipe a Kafka consumer to a WebSocket on Play! Framework.
View KafkaFeed.scala
package controllers
import java.util.Properties
import com.typesafe.config.ConfigFactory
import kafka.consumer.{Consumer, ConsumerConfig, ConsumerConnector, Whitelist}
import kafka.serializer.StringDecoder
import play.api.libs.iteratee.{Enumerator, Iteratee}
import play.api.mvc.{Controller, WebSocket}
View Blender3D Group Select
import bpy
scene = bpy.context.scene
for ob in scene.objects:
if ob.name.startswith("BartTrainModel:pSphere"):
ob.select = True
@seacloud9
seacloud9 / gist:4d22db233c2bbb221e2830a98c30acb0
Last active May 4, 2016 — forked from dpeek/gist:6043433
Haxe, Neko and OpenFL on Raspberry Pi
View gist:4d22db233c2bbb221e2830a98c30acb0
mkdir ~/source
# dependencies
sudo apt-get update
sudo apt-get install libgc-dev bzip2 git-core make gcc g++ gnuplot glade imagemagick libusb-dev python-usb python-lxml python-wxgtk2.8 speech-dispatcher libgnomecanvas2-dev m4 libsdl1.2-dev
# neko
git clone https://github.com/HaxeFoundation/neko.git ~/source/neko
cd ~/source/neko
make