This is a short note about building cURL with SSL support on Windows
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// [src] https://github.com/ocornut/imgui/issues/123 | |
// [src] https://github.com/ocornut/imgui/issues/55 | |
// v1.22 - flip button; cosmetic fixes | |
// v1.21 - oops :) | |
// v1.20 - add iq's interpolation code | |
// v1.10 - easing and colors | |
// v1.00 - jari komppa's original | |
#pragma once |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <stdint.h> | |
// r-lyeh, public domain - quantize quaternions to 32-bits & numbers to 8/10-bits { | |
// | |
// [ref] http://zeuxcg.org/2010/12/14/quantizing-floats/ | |
// D3D10, GL2: for *_UNORM formats of n-bit length, the decode function is decode(x) = x / (2^n - 1) | |
// Unsigned quantization: input: [0..1] float; output: [0..255] integer | |
// D3D10: for *_SNORM formats of n-bit length the decode function is decode(x) = clamp(x / (2^(n-1) - 1), -1, 1) | |
// Signed quantization for D3D10 rules: input: [-1..1] float; output: [-127..127] integer | |
static inline uint8_t encode8_unorm(float x) { return uint8_t( int (x * 255.f + 0.5f) ); } | |
static inline float decode8_unorm(uint8_t x) { return x / 255.f; } |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/*/ | |
C++ Garbage Collection Library | |
============================== | |
This is a library to manage memory in C++ programs using a garbage | |
collector. It uses a mark and sweep algorithm. | |
All objects that are to be managed by the collector should be derived | |
from GCObject: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
P-code for PL/0 machine | |
[ref] https://en.wikipedia.org/wiki/P-code_machine | |
[ref] http://blackmesatech.com/2011/12/pl0/pl0.xhtml | |
The PL/0 virtual machine was originally specified by Nicklaus Wirth in his book | |
Algorithms + Data Structures = Programs; it's used as the target machine for a | |
PL/0 compiler. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#ifndef PORTABLE_MMAP_H | |
#define PORTABLE_MMAP_H | |
#ifdef _WIN32 | |
/* mmap() replacement for Windows | |
* | |
* Author: Mike Frysinger <vapier@gentoo.org> | |
* Placed into the public domain | |
*/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// [ref] http://stackoverflow.com/questions/15249465/c-dynamically-load-arbitrary-function-from-dll-into-stdfunction | |
template <typename T> | |
struct TypeParser {}; | |
template <typename Ret, typename... Args> | |
struct TypeParser<Ret(Args...)> { | |
static std::function<Ret(Args...)> createFunction(const FARPROC lpfnGetProcessID) { | |
return std::function<Ret(Args...)>(reinterpret_cast<Ret (__stdcall *)(Args...)>(lpfnGetProcessID)); | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Created by inigo quilez - iq/2013 | |
// License Creative Commons Attribution-NonCommercial-ShareAlike 3.0 Unported License. | |
// https://www.shadertoy.com/view/4dfGzn | |
void mainImage( out vec4 fragColor, in vec2 fragCoord ) | |
{ | |
vec2 q = fragCoord.xy / iResolution.xy; | |
vec2 uv = vec2(q.x,q.y); | |
// zooming |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// [src] https://github.com/ocornut/imgui/issues/351 | |
// [src] https://github.com/ocornut/imgui/issues/123 | |
// v1.0 | |
#define IMGUI_DOCK_ENABLE_SERIALIZATION 0 | |
// header | |
// #pragma once | |
namespace Lumix { namespace FS { class OsFile; } } |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <map> // Component-entity system in 16 lines of C++11. 2013 rlyeh, MIT licensed | |
#include <set> // Code fragment from kult engine - https://github.com/r-lyeh/kult | |
enum {JOIN,MERGE,EXCLUDE};using set=std::set<unsigned>;template<typename T> set&system(){ | |
static set entities;return entities;}template<typename T,int MODE>set subsystem(const set | |
&B){set newset;const set&A=system<T>();if(MODE==MERGE){newset=B;for(auto&id:A)newset.ins\ | |
ert(id);}else if(MODE==EXCLUDE){newset=B;for(auto&id:A)newset.erase(id);}else if(A.size() | |
<B.size()){for(auto&id:A)if(B.find(id)!=B.end())newset.insert(id);}else{for(auto&id:B)if( | |
A.find(id)!=A.end())newset.insert(id);}return newset;}template<typename T>std::map<unsig\ | |
ned,T>&components(){static std::map<unsigned,T>objects;return objects;}template<typename\ | |
T>bool has(unsigned id){return components<T>().find(id)!=components<T>().end();}templat\ |
NewerOlder