This list is an attempt to collect as many free resources about computer graphics- / rendering- techniques, game- / render-engine architecture and optimization techniques. This list doesn't contain every resource that is out there so it'll be expanded in time whenever I find another resource that may help one person or the other.
//Sample textures | |
vec4 albedo_tex = texture2D(texture, texcoord); | |
vec4 normal_tex = texture2D(normals, texcoord); | |
vec4 specular_tex = texture2D(specular, texcoord); | |
//Gamma correction - Optional if you're not doing gamma correct lighting | |
albedo_tex.xyz = pow(albedo_tex.xyz, vec3(2.2)); | |
//Normals | |
vec3 normal; |
/*============================================================================ | |
NVIDIA FXAA 3.11 by TIMOTHY LOTTES | |
------------------------------------------------------------------------------ | |
COPYRIGHT (C) 2010, 2011 NVIDIA CORPORATION. ALL RIGHTS RESERVED. | |
------------------------------------------------------------------------------ | |
TO THE MAXIMUM EXTENT PERMITTED BY APPLICABLE LAW, THIS SOFTWARE IS PROVIDED |
/* | |
Thanks to whomever wrote the shader at http://glslsandbox.com/e#36146.5. My code is based off of their's. | |
*/ | |
#define INCLUDED_ATMOSCATTERING | |
#define ATMOSPHERIC_SCATTERING // Swaps out the sky gradient for a proper atmospheric scattering model. Atmospheric scattering models how light would interact with an actual atmosphere, producing realistic colours as the sun nears the horizon. |
-
Find the Discord channel in which you would like to send commits and other updates
-
In the settings for that channel, find the Webhooks option and create a new webhook. Note: Do NOT give this URL out to the public. Anyone or service can post messages to this channel, without even needing to be in the server. Keep it safe!
// This is free and unencumbered software released into the public domain. | |
// | |
// Anyone is free to copy, modify, publish, use, compile, sell, or | |
// distribute this software, either in source code form or as a compiled | |
// binary, for any purpose, commercial or non-commercial, and by any | |
// means. | |
// | |
// In jurisdictions that recognize copyright laws, the author or authors | |
// of this software dedicate any and all copyright interest in the | |
// software to the public domain. We make this dedication for the benefit |
FROM HUE DESIGN DOCS
#Conversion between RGB and xy in the CIE 1931 colorspace for hue The conversion between RGB and xy in the CIE 1931 colorspace is not something Philips invented, but we have an optimized conversion for our different light types, like hue bulbs and LivingColors. It is important to differentiate between the various light types, because they do not all support the same color gamut. For example, the hue bulbs are very good at showing nice whites, while the LivingColors are generally a bit better at colors, like green and cyan.
#include "thread.h" | |
#include <stdio.h> | |
#ifdef __WIN32__ | |
#include <windows.h> | |
#else | |
#include <pthread.h> | |
#include <stdlib.h> | |
#endif // __WIN32__ |
#include <SDL2/SDL.h> | |
#define MUS_PATH "Roland-GR-1-Trumpet-C5.wav" | |
// prototype for our audio callback | |
// see the implementation for more information | |
void my_audio_callback(void *userdata, Uint8 *stream, int len); | |
// variable declarations | |
static Uint8 *audio_pos; // global pointer to the audio buffer to be played |
/* | |
* Copyright (c) 2009-2017, Farooq Mela | |
* All rights reserved. | |
* | |
* Redistribution and use in source and binary forms, with or without | |
* modification, are permitted provided that the following conditions are met: | |
* | |
* 1. Redistributions of source code must retain the above copyright | |
* notice, this list of conditions and the following disclaimer. | |
* 2. Redistributions in binary form must reproduce the above copyright |