This file contains hidden or 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
| /* | |
| Can load easier and more indepth with https://github.com/Hydroque/DDSLoader | |
| Because a lot of crappy, weird DDS file loader files were found online. The resources are actually VERY VERY limited. | |
| Written in C, can very easily port to C++ through casting mallocs (ensure your imports are correct), goto can be replaced. | |
| https://www.gamedev.net/forums/topic/637377-loading-dds-textures-in-opengl-black-texture-showing/ | |
| http://www.opengl-tutorial.org/beginners-tutorials/tutorial-5-a-textured-cube/ | |
| ^ Two examples of terrible code |
This file contains hidden or 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 <iostream> | |
| #include <ctime> | |
| class Timer | |
| { | |
| public: | |
| Timer() { clock_gettime(CLOCK_REALTIME, &beg_); } | |
| double elapsed() { | |
| clock_gettime(CLOCK_REALTIME, &end_); |
This file contains hidden or 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
| <!-- MIT License --> | |
| <html> | |
| <head> | |
| <script> | |
| function generateKey(alg, scope) { | |
| return new Promise(function(resolve) { | |
| var genkey = crypto.subtle.generateKey(alg, true, scope) | |
| genkey.then(function (pair) { | |
| resolve(pair) | |
| }) |
This file contains hidden or 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
| The MIT License (MIT) | |
| Copyright (c) <year> <copyright holders> | |
| 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: |
This file contains hidden or 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
| /* Read this comment first: https://gist.github.com/tonious/1377667#gistcomment-2277101 | |
| * 2017-12-05 | |
| * | |
| * -- T. | |
| */ | |
| #define _XOPEN_SOURCE 500 /* Enable certain library functions (strdup) on linux. See feature_test_macros(7) */ | |
| #include <stdlib.h> | |
| #include <stdio.h> |