Tag: C++

  • Raytracing Anyone?

    Raytracing Anyone?

    There’s not much cooler than Raytracing. Making photoeralistic (or a little too perfect-istic) images on you computer is definitely cool. A bagillion years ago, I dove into raytracing and made my own. It was AP Calculus in high school when I realized that gradients lead to surface normals. Shocker! Anyway, I dug out the old…

  • Java and C++, hmmm…

    Java and C++, hmmm…

    Java can’t do: An unfortunate, in my opinion, consequence of not being able to overload operators is the == operator function with objects. This operator only compares instances of objects as opposed to the content of those objects. Which is confusing in light of the primitive int and Java object Integer class, for example. So…

  • Memoization – Python and C++

    Dan Bader shows a neat way to implement a simple cache and speed up your Python programs here: https://dbader.org/blog/python-memoization He writes a generic decorator class that wraps any function with a lookup cache for each set of input arguments and uses it for an exponential complexity function — Fibonacci. While I will defer the generic…

  • Windows C++ — Simplest Desktop Program

    I’m much more of a Linux C++ developer, but here’s a quick start example of a CMake project that opens a window in Windows 10/11, gets keyboard input and is set up to draw something in the window: main.cpp: CMakeLists.txt

  • SFML C++ Quick Start

    SFML is a handy little library I’ve used mainly for graphics. I made an OpenGL and Vulkan graphics library myself cause what’s the fun in using some existing library? Suck the fun out of everything. It was interesting to see that SFML had a similar architecture to mine which made it kind of convenient to…