Skip to content

Instantly share code, notes, and snippets.

View malkia's full-sized avatar

Dimiter 'malkia' Stanev malkia

View GitHub Profile
/* Stolen from luajit - http://repo.or.cz/w/luajit-2.0.git/blob/HEAD:/src/lj_obj.h */
/* Look for examples here - http://repo.or.cz/w/luajit-2.0.git/blob/HEAD:/src/lj_meta.c */
/* ANd http://repo.or.cz/w/luajit-2.0.git/blob/HEAD:/src/lj_obj.c */
#define MYDEFS(_) _(one) _(two) _(three) _(four) _(five)
/* Make an enum from 'one', 'two', etc. */
typedef enum my_enums{
#define MYENUM(name) my_##name,
MYDEFS(MYENUM)
First I've downloaded ode from here:
http://sourceforge.net/projects/opende/files/ODE/0.12/ and extracted it in my e:\p under e:\p\ode-0.12
Then I did (from cmd.exe)
bash --login -i
$ cd /cygdrive/e/p/ode-0.12
$ ./configure
checking build system type... x86_64-unknown-cygwin
checking host system type... x86_64-unknown-cygwin
cd /usr/local
tar jxf ~/opencv2.4.8-cygwin64-g++-4.8.2-shared-release-20131231.tar.bz2
cd ~
#define FAST // Comment this out this going 7 times slower
using System;
using System.Collections.Generic;
using System.Diagnostics;
namespace netBlah1
{
class Program
{
@malkia
malkia / gist:89c6a78405132bc30dcc
Created December 18, 2014 09:25
chrome://version
Google Inc.
Copyright 2014 Google Inc. All rights reserved.
Google Chrome 40.0.2214.43 (Official Build) beta
Revision 9d5cd14c677accab1e25f0ee3d58667ff5b41dac
Platform 6457.36.0 (Official Build) beta-channel parrot_ivb
Blink 537.36 (@62f90f76bfca59fa9dd2d73329019b2d841a9b5e)
JavaScript V8 3.30.33.8
Flash 16.0.0.235-r1
User Agent Mozilla/5.0 (X11; CrOS x86_64 6457.36.0) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/40.0.2214.43 Safari/537.36
/*
# Makefile for go.go
all: install
include $(GOROOT)/src/Make.$(GOARCH)
TARG = go
GOFILES = $(TARG).go
;; beer.lisp
;; simple opengl playground
;; Load this in Lispworks, or Lispworks Personal, and type Ctrl+Shift+B
;; malkia@gmail.com
(eval-when (:compile-toplevel :execute :load-toplevel)
(let ((lwdir (concatenate 'string (namestring *lispworks-directory*) "lib/6-0-0-0/")))
(load (concatenate 'string lwdir "examples/opengl/defsys"))
(load (concatenate 'string lwdir "examples/opengl/examples/defsys"))
(compile-system 'opengl :load t :force nil)
The NU project.
Two Applications:
- The Editor
- The Player
Command Line Tool:
- The Convertor - Builds assets continuously - should be able to parallelize with IncrediBuild, ElectricFence, ccache/distcc, SN-DBS, etc.
Editor:
; Under Lispworks 6.01 32-bit Windows Vista
;
; CL-USER 100 > (test-fun)
; (i & 0x80000000) == 0 time: 0.717
; (i & 0xFFFFFFFF) == 0 time: 0.671
; (i & 0x00000001) == 0 time: 0.718
; (i & 0x00000003) == 0 time: 0.795
; (i & 0x00000002) == 0 time: 0.827
; (i & 0x00000004) == 0 time: 0.78
; (i & 0x00000008) == 0 time: 0.811
Editor = {
"1. First Line",
"2. Second Line",
"3. Third Line",
"4. Fourth Line",
"5. Fifth Line",
}
function timeit(fun,info)
info = info or ""