Attention: the list was moved to
https://github.com/dypsilon/frontend-dev-bookmarks
This page is not maintained anymore, please update your bookmarks.
// float->half variants. | |
// by Fabian "ryg" Giesen. | |
// | |
// I hereby place this code in the public domain, as per the terms of the | |
// CC0 license: | |
// | |
// https://creativecommons.org/publicdomain/zero/1.0/ | |
// | |
// float_to_half_full: This is basically the ISPC stdlib code, except | |
// I preserve the sign of NaNs (any good reason not to?) |
#!/bin/sh | |
#copy directly into /usr/bin | |
if [ -s /tmp/__pserver ]; then | |
kill `cat /tmp/__pserver` | |
fi | |
python -m SimpleHTTPServer 1>>/dev/null 2>>/tmp/log.pserver & | |
echo -n $! > /tmp/__pserver |
Attention: the list was moved to
https://github.com/dypsilon/frontend-dev-bookmarks
This page is not maintained anymore, please update your bookmarks.
// Creating a node graph editor for Dear ImGui | |
// Quick sample, not production code! | |
// This is quick demo I crafted in a few hours in 2015 showcasing how to use Dear ImGui to create custom stuff, | |
// which ended up feeding a thread full of better experiments. | |
// See https://github.com/ocornut/imgui/issues/306 for details | |
// Fast forward to 2023, see e.g. https://github.com/ocornut/imgui/wiki/Useful-Extensions#node-editors | |
// Changelog | |
// - v0.05 (2023-03): fixed for renamed api: AddBezierCurve()->AddBezierCubic(). |
Orthodox C++ (sometimes referred as C+) is minimal subset of C++ that improves C, but avoids all unnecessary things from so called Modern C++. It's exactly opposite of what Modern C++ suppose to be.
/* | |
* Coroutines. | |
* | |
* To make a (fake) coroutine we use these macros. A coroutine method must be static, | |
* return bool and needs a parameter (Generator & generator). | |
* | |
* Generator must follow this schema: | |
* struct Generator { | |
* int line; | |
* float time; |
Before you continue, if you don't know what IMGUI is don't bother reading this post, just ignore it, don't write anything in comments section, etc. If you're curious about IMGUI see bottom of this post, otherwise continue whatever you were doing, this post it's not for you. Thanks!
If you know what IMGUI is, for context read following presentations and blog posts:
/* | |
MIT License | |
Copyright (c) 2018 Jonas Balsfulland | |
Permission is hereby granted, free of charge, to any person obtaining a copy | |
of this software and associated documentation files (the "Software"), to deal | |
in the Software without restriction, including without limitation the rights | |
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell | |
copies of the Software, and to permit persons to whom the Software is | |
furnished to do so, subject to the following conditions: | |
The above copyright notice and this permission notice shall be included in all |
# When run (in PowerShell), this script prompts for a directory containing a git project. | |
# It then jumps into that directory and uses Gource + FFmpeg to generate an mp4 animation of the history of the current branch. | |
# Additionally, it has support for embedding background music files. Click "Cancel" on the prompt to not add audio. | |
# If the video is shorter than the selected audio, the audio will fade out. If longer, the video will be sped up to fit the audio. | |
# | |
# Note: If the complementary script "handle_avatars.ps1" is present, this script will use it to download user avatars from GitHub. | |
# This may hit rate limiting, so ClientID and ClientSecret oAuth params are accepted, which will bypass GitHub's limits. | |
# You can cut down on the required queries by properly using a ".mailmap" file to combine user's emails. | |
# Pass "SkipGithubAvatars" to ignore this entirely, if your project is not hosted on GitHub. | |
# |