Skip to content

Instantly share code, notes, and snippets.

View blockspacer's full-sized avatar
:octocat:

Devspace blockspacer

:octocat:
  • Google
  • USA
View GitHub Profile
@Neisoweli
Neisoweli / REPORT.md
Last active June 5, 2020 08:42
Lab07.Report

Laboratory work VII Build Status

Данная лабораторная работа посвещена изучению систем документирования исходного кода на примере Doxygen

$ open https://www.stack.nl/~dimitri/doxygen/manual/index.html
@ViteFalcon
ViteFalcon / godot-multithreaded-programming.md
Created February 11, 2018 18:59
Godot: Multithreaded Programming

Problem

I wanted to start building the GUI parts of the game, but create it in such a way that I will have a network interface that I can later replace with the actual implementation.

What I did

I created a LoginClient that provides an interface to the login server functions. This client works in an asynchronous manner. Login requests gets queued, which then gets processed by a thread. The fun part was in the details, which I will explain here.

Threads in Godot

I feel this is one of the things that has been least documented in Godot's documentation and few people in Godot's Discord channel have knowledge of how this works.

The general code to create and run a method in a thread looks like this:

Core Coding Standard

Coding practices are a source of a lot of arguments among programmers. Coding standards, to some degree, help us to put certain questions to bed and resolve stylistic debates. No coding standard makes everyone happy. (And even their existence is sure to make some unhappy.) What follows are the standards we put together on the Core team, which have become the general coding standard for all programming teams on new code development. We’ve tried to balance the need for creating a common, recognizable and readable code base with not unduly burdening the programmer with minor code formatting concerns.

Table Of Contents

@DusanMadar
DusanMadar / TorPrivoxyPython.md
Last active March 11, 2025 09:09
A step-by-step guide how to use Python with Tor and Privoxy

A step-by-step guide how to use Python with Tor and Privoxy

Latest revision: 2021-12-05.

Tested on Ubuntu 18.04 Docker container. The Dockerfile is a single line FROM ubuntu:18.04. Alternatively, you can simply run docker run -it ubuntu:18.04 bash.

NOTE: stopping services didn't work for me for some reason. That's why there is kill $(pidof <service name>) after each failed service <service name> stop to kill it.

References

@mbinna
mbinna / effective_modern_cmake.md
Last active April 25, 2025 22:01
Effective Modern CMake

Effective Modern CMake

Getting Started

For a brief user-level introduction to CMake, watch C++ Weekly, Episode 78, Intro to CMake by Jason Turner. LLVM’s CMake Primer provides a good high-level introduction to the CMake syntax. Go read it now.

After that, watch Mathieu Ropert’s CppCon 2017 talk Using Modern CMake Patterns to Enforce a Good Modular Design (slides). It provides a thorough explanation of what modern CMake is and why it is so much better than “old school” CMake. The modular design ideas in this talk are based on the book [Large-Scale C++ Software Design](https://www.amazon.de/Large-Scale-Soft

#define INPUTPLANE 1
precision highp float;
uniform sampler2D tex;
uniform mat3 weight[128];
uniform vec2 pixSize;
uniform float bias;
varying vec2 uv;
void main() {
vec4 inputOffset[1];
inputOffset[0] = vec4(0,0,0.062499,0.124999);
@bjin
bjin / .gitignore
Last active March 24, 2020 19:00
ravu-hlsl
*.spv
@williballenthin
williballenthin / .gdbinit
Last active March 14, 2024 19:20
yet another gdb cheatsheet
set disassembly-flavor intel
set disassemble-next-line on
set history save on
set print pretty on
set pagination off
set confirm off
define xxd
dump binary memory dump.bin $arg0 $arg0+$arg1
@ledil
ledil / extj
Created July 12, 2017 07:46
extjs grid store abort
Ext.define('Ext.enhance.data.Store', {
override: 'Ext.data.Store',
constructor: function(config) {
var me = this;
me.callParent([config]);
me.on({
'beforeload': function(store, operation) {
// keep the operation which has request object
store.lastOperation = operation;
}
@mortennobel
mortennobel / SingleFileOpenGLTex.cpp
Last active October 23, 2024 20:56
Single file OpenGL 3.3 / WebGL (using Emscripten) example with texture (SDL2 / SDL_Image 2)
//
// Compile for emscripten using
// emcc -Iinclude SingleFileOpenGLTex.cpp \
-O2 -std=c++14 -s TOTAL_MEMORY=33554432 -s USE_SDL_IMAGE=2 -s SDL2_IMAGE_FORMATS='["png"]' --preload-file examples/data -s USE_SDL=2 -o html/SingleFileOpenGLTex.html
// where the following images must be located in a subfolder
// - examples/data/test.png
// - examples/data/cartman.png
// - examples/data/cube-negx.png
// - examples/data/cube-negz.png
//