Showing results for July 2009 - Page 3 of 5 - The Old New Thing

Jul 16, 2009
0
0

Separating the metadata from the DIB pixels: Changing the raster operation

Raymond Chen
Raymond Chen

For a few days now, we've used the function in conjunction with a precomputed to draw a DIB with an alternate color table without modifying the . The function operates like a with raster operation . If you want another raster operation, you can use , which has a final raster operation parameter. Despite its name, you don't have to stretch w...

Code
Jul 15, 2009
0
0

On gender differences in expectations of thinness, and the impact on guys who live in their parents' basement

Raymond Chen
Raymond Chen

At dinner a few years ago, one of my friends brought up a study (which I can't find, so who knows if it's actually true, but let's assume it's true for the sake of the story) that examined the effect of gender differences in expectations of thinness. One of the factors that the study considered was sexual orientation, and they found that homosexual...

Non-Computer
Jul 15, 2009
0
0

Separating the metadata from the DIB pixels: Precalculating the BITMAPINFO

Raymond Chen
Raymond Chen

Last time, we saw that you can use the function to draw a DIB with an alternate color table without having to modify the . In that version of the function, we selected the into a device context in preparation for drawing from it, but in fact that step isn't necessary for drawing. It was merely necessary to get the original color table so we cou...

Code
Jul 14, 2009
0
0

What happens to your restaurant tip?

Raymond Chen
Raymond Chen

Some time ago, the Seattle Times ran an article on how your restaurant tip gets divided up among the staff. A week later, they ran an entire article of responses to the original article, some from customers, but many from restaurant staff (both cooks and servers). And, now on a roll, the next week's food section looked at the sociology of spli...

Non-Computer
Jul 14, 2009
0
0

The fun and profit of manipulating the DIB color table can be done without having to modify it

Raymond Chen
Raymond Chen

If I were Michael Kaplan, I'd have a more clever title like I'm not touching you! or Look but don't touch or maybe Looking at a DIB through -colored glasses. We saw some time ago that you can manipulate the DIB color table to perform wholesale color remapping. But in fact you can do this even without modifying the DIB color table, which is a h...

Code
Jul 13, 2009
0
0

Failed follow-up: The case of the dubious dental work

Raymond Chen
Raymond Chen

I've been waiting for an opportunity to do a follow-up on this story, but the trail appears to have gone cold. Here's the story as we know it so far: In 2004, a woman (who had previously run unsuccessfully for a city council position) files a $6,370 claim for dental work against McDonald's, claiming that she injured her teeth biting into a cherry...

Non-Computer
Jul 13, 2009
0
0

Speculation on how a mishandled 13-character string can result in a blue screen

Raymond Chen
Raymond Chen

Commenter nolan reminisces about an old Windows 95 bug in the networking layer that crashed if a string was exactly 13 characters long. "So for the past 10 years or so, I've been wondering exactly how one could write code with that bug. Any bug that weird has to have a great story behind it." I don't know what the story behind it is, but i...

Other
Jul 10, 2009
0
0

The world reaction to the unexpected death of Michael Jackson extends to young children

Raymond Chen
Raymond Chen

I had occasion to meet up with the same family whose two-year-old was learning to lie in an earlier story. It was only a day or two after the death of Michael Jackson, and the older sister (five years old) told me, "Did you know? Michael Jackson, he went to sleep and he is never going to wake up." Her younger sister (now three), corrected her. "...

Non-Computer
Jul 10, 2009
0
0

If dynamic DLL dependencies were tracked, they'd be all backwards

Raymond Chen
Raymond Chen

Whenever the issue of DLL dependencies arises, I can count on somebody arguing that these dynamic dependencies should be tracked, even if doing so cannot be proven to be reliable. Even if one could walk the call stack reliably, you would still get it wrong. The example I gave originally was the common helper library, where loads via an intermed...

Code
Jul 9, 2009
0
0

Film students and The Bicycle Thief

Raymond Chen
Raymond Chen

The current generation of young people grew up in a very different world from us older folks. There has always been an Internet. Everybody is accessible by mobile phone. Cars have always had power windows. (Which reminds me of a story of a friend of mine who has an older-model car and was giving a ride to an eight-year-old relative. The youngster p...

Non-Computer