Friday, September 05, 2014

Youtube Filter Extension - Inception

There are a lot of young kids watching Youtube videos.  I went looking for the parental controls, and found Google's statement: Youtube is for people 13 and over.  To which I respond, hahahahahahaha

I thought about using a Squid proxy, but the video is encoded into a GET request, which Squid didn't seem ready to handle...

Then I saw this extension, and it looks like a good way forward...

Monday, August 11, 2014

Bridgehead

"Bridgehead" (David Drake) - I was unpleasantly surprised by this book.  I expect a lot more from Drake, and this was not up to his usual standard.  He took an unusual idea (FTL via some sort of row and column based system), and wrapped it up in a lot of mystery and drama (which are not his strong suit).  The combat was a fairly minor part of the book, and always one-sided.

Tuesday, June 10, 2014

C++: make the simple case broken

I've been programming C++ for twenty years, and I learned something yesterday about a fundamental class that I use a lot...

int main(int argc, char **argv)
{
   std::map<int, int> myMap;
   myMap.insert(std::make_pair(0, 1));
   myMap.insert(std::make_pair(0, 2));
   printf("%d\n", myMap[0]);
   return 0;
}

What should this program print?  1 or 2?  If you said 2, you'd be horribly wrong!

Because, sometimes, you just want your insert operations to fail.

If you don't want total failure, you need to write:

int main(int argc, char **argv)
{
   std::map<int, int> myMap;
   myMap.insert(std::make_pair(0, 1));
   std::pair::iterator, bool> i = myMap.insert(std::make_pair(0, 2));
   if (!i.second)
      i.first->second = 2;
   printf("%d\n", myMap[0]);
   return 0;
}

That's why I love C++.

Tuesday, April 08, 2014

Crowdsourcing your brainstorming

Back in the days of Mudge, it was easy to brainstorm an idea like industrial applications of black holes.

Now, it's harder.

I figured I would make use of the largest collection of nerds that I know about - Reddit (seeing as how Slashdot has gone down the tubes).

Reddit is divided into groups, and finding the right one can be somewhat of a challenge.

The most direct would be /r/AskScience, since it is really a science question (or, applied science).  But they take a dim view on science fictiony things.

There is also /r/AskScienceFiction, which sounds perfect.  Except, everything there is in role-playing form (it should be /r/AskLARP or something).  There are other more conceptual/design subreddits, but they are all low traffic.

So, I just had to ask my question in a RP fashion, and try and make sense of RP answers.

The answers weren't spectacular.  But I must give credit to /u/Sriad for the best one.  I had thought about using extreme matter compression, but I was thinking of something like a diamond press (which would not be forceful enough).  Treating it more like a fusion bomb makes a lot of sense.