Thursday, April 28, 2016

Detecting Markov Bots on Reddit, my lazy way

I've been getting annoyed at the number of comment bots on Reddit that are clearly just a program running a Markov chain. If you're not familiar with Markov chains, the basic explanation is that it looks at all the comments and makes a list of what words came directly after what other words, and then goes through the list to find a string of words where each pair was found in that order in the real comments. There are other ones that use larger portions of the text and ones that could use more than just the comments on one post, but the Reddit bots don't seem to be those (Wikipedia has an article with a far better explaination about Markov chains). Sometimes this makes a decent looking comment, but other times it just makes gibberish. There's a whole subreddit, /r/subredditsimulator, where the only posters allowed are Markov chain bots trained on other subreddits. That's the only place I'd like to see them.

Wednesday, April 27, 2016

Update on Next Tutorial

I wanted to give everyone an update on the next tutorial, since it's been a while.

As you can see in the pictures, there's multiple lights at once, specular maps (look at the difference between the land and ocean), and spot lights. This code also includes directional lighting, but I think it didn't make the pictures.

I'm sorry to let this take so long. Life has been busy, but it should be less busy relatively soon.


The other problem has been trying to break this tutorial up into manageable chunks. I may have to switch to making it into an annotated example project instead of a tutorial (which might be better overall, and would let me make more content). Feel free to leave comments if you have any feelings about this (and I know some people have asked for that sort of change in the past).

Wednesday, December 16, 2015

OpenTK Tutorial 8 Part 2: Adding Textures and Specular Lighting

In the first part of this tutorial, we added normals. In this tutorial, we'll use them to do something interesting, adding specular lighting and diffuse maps.


Sunday, August 9, 2015

OpenTK Tutorial 8 Part 1: Normals, Materials, and Loading More From Files

In the previous tutorial, we loaded a simple object in from a file. Right now, it's hard to see the detail in the models because they're all one color (or have a texture applied wrong). By the end of this tutorial (that is, after the second part), we'll have diffuse lighting with specular highlights on our models, making them look much nicer.

This part will cover loading texture coordinates and normals from a file, calculating normals for geometry that doesn't come with them (such as shapes we're generating through code) and loading basic materials from a file.

(UPDATED 2015-11-24 to fix some issues with loading normals from a file)

(UPDATED 2015-12-16 to make the MTL file have materials that look nicer under lighting)

Sunday, July 5, 2015

Progress Update

It's been a while, and I want to fill everyone in on what/when the next tutorial will be. This weekend is the first time I haven't had a million other projects I should be doing, so I was able to make some real progress.


The next tutorial is going to be broken into two parts (for length's sake, but Part 1 will be useful on its own). 

The first part will handle loading more complex OBJ files, and loading materials from MTL files. The OBJ loader we already had only works on really, really simple OBJ files, and it won't cut it for loading most models with texture maps.

The second part will put this to better use by adding some simple lighting to the project.


Expect the whole thing before the end of the month. After the next tutorial, I plan on making a model viewer example to show what can be done.

Tuesday, April 14, 2015

OpenTK Tutorial 7: Simple Objects from OBJ files

This tutorial is going to be rather short. What we'll do is add a new class that can open very simple OBJ files and add some sample models to the project.


Wednesday, March 25, 2015

Inside the Sprite Example

Last time I posted a new example that uses OpenTK for a 2D view with sprites. Let's go into a bit more detail about how it works: