Skip to content

Instantly share code, notes, and snippets.

View tatarize's full-sized avatar

tatarize

View GitHub Profile
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width">
<title>JS Bin</title>
</head>
<body>
<ul id="myList">
</ul>
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width">
<title>JS Bin</title>
</head>
<body>
<ul id="myList">
</ul>
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width">
<title>JS Bin</title>
</head>
<body>
<ul id="myList">
</ul>
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width">
<title>JS Bin</title>
</head>
<body>
<ul id="myList">
</ul>
@tatarize
tatarize / gist:178f1d543716613a3acb135225c2b7af
Created June 18, 2019 19:56
Total Effect Timing BlackWhiteRaster.
import com.t_oster.liblasercut.BlackWhiteRaster;
import com.t_oster.liblasercut.ByteArrayList;
import com.t_oster.liblasercut.FloatPowerSpeedFocusFrequencyProperty;
import com.t_oster.liblasercut.RasterPart;
import com.t_oster.liblasercut.platform.Point;
import com.t_oster.liblasercut.utils.BufferedImageAdapter;
import java.awt.image.BufferedImage;
import java.io.File;
import java.io.FilenameFilter;
@tatarize
tatarize / BlackWhiteRaster.java
Created June 18, 2019 18:12
Sample BlackWhiteRaster with PixelWindow
/**
* This file is part of LibLaserCut.
* Copyright (C) 2011 - 2014 Thomas Oster <[email protected]>
*
* LibLaserCut is free software: you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* LibLaserCut is distributed in the hope that it will be useful,
import com.t_oster.liblasercut.BlackWhiteRaster;
import com.t_oster.liblasercut.utils.BufferedImageAdapter;
import java.awt.image.BufferedImage;
import java.io.File;
import java.io.FilenameFilter;
import java.io.IOException;
import javax.imageio.ImageIO;
public class TimeBWRaster {
import math
value = math.pi * 2
best = 1e-5
for i in range(1, 1000000):
fraction = float(i) / 12
numer = round(value * fraction)
v = numer / float(fraction)
err = v - value
/*
MIT LICENSE.
(feel free to drop this entire comments section, and use for any commercial or open projects).
Written by Tatarize.
Iterable fast csv stream parser.
You would typically process this quite helpfully like:
for (String[] csv : parseCSV(stream)) {
<deal with parsed csv data>
@tatarize
tatarize / serpfam.svg
Created August 29, 2018 09:51
Sierpinski Family
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.