2010 Jan 20, 8:28GZip vs Deflate execution speeds. Deflate found to be much faster in particular cases and about the same in the rest.
gzip deflate performance technical http compression programming development blog 2010 Jan 5, 1:47
The New Super Mario Bros. Wii is a great game. Its the fun of old school Mario with the addition of great graphics and the kind of multiplayer I've wanted for Mario since playing the original as a
child: its got up to four player simultaneous cooperative multiplayer. I recommend it to anyone who has enjoyed Mario in the past. Watch this amazing video of level 1-3 you can unlock in the game.
As noted elsewhere, multiple players attempting to navigate platforms, grab power ups, and throw turtle shells creates new
challenges but along with that there's new ways to be incredibly cheap.
-
Jumping Higher
-
A second player means a head one can jump on to reach higher locations. Jump on your friend's head at the apex of their jump while holding down the jump button yourself for maximum jumping. In
the game you can also grab other players and hold them over your head. This is useful for reaching the top of the flagpole at the end of levels. On that same line, if the player you grab has a
flying cap you can now use them to fly in the same manner you would use a flying block which makes it easy to get two players to the top of the finish flagpole if only one of you has a flying
cap.
-
Power-Ups
-
Normal power-up blocks now spawn enough power-ups for everyone. A mushroom is spawned for each small player and full power-ups for the rest, except in the case everyone is small: then one of the
power-ups is a full power-up. If there's two players and you're both small, the full power-up always jumps out of the block to the right. Some hidden power-up blocks only give out one power-up
and in that case its a mushroom or not based on the player who hits the block - so be sure that a big player hits that if you have one.
-
Death & Bubbles
-
When a player dies but at least one other player lives the dead player comes back in a limbo bubble from which they must be released before they may play again. Because of this, in a tough spot
you can send one player in and leave a second behind. If the first dies you don't lose your place in the level and the first comes back in a bubble ready to try again. For instance, if you're
trying to get the last star coin in 2-1 which sits just above the abyss, one player can just jump to their death for it and as long as another player lives you've collected the coin. However you
need not sacrifice your life to do this: you can press down and 'a' to force yourself into a bubble saving yourself from death. This is true in general as long as you have enough time to see your
death coming. This is also useful if one player runs ahead to the right. The screen will expand a bit but then it will just move to the right following the player in the lead. Players left behind
walls or now forced into lava pits will die unless they use the bubble.
-
Misc.
-
- If all players hit the ground at the same time from a ground pound it acts like hitting a pow block, killing the enemies on the screen.
- If you hold a player who has a projectile power over your head they can still use their power.
- Bubbles can be popped by hitting them with your fire or ice projectiles as well as thrown shells or blocks.
- All players get the extra lives from anyone collecting 100 coins or finishing a level with more than 7 enemies on the screen.
multiplayer mario wii 2009 Dec 31, 4:40"Nokia has been struggling a bit this year, but this "hack it" to get your phone unboxing is pretty interesting. Once you "root" the box it opens up and a little puff of smoke appears, along with
your phone (if you're a phone / gadget reviewer)." Makes me wonder how many devs and engineers they had working on the box to contain this phone.
phone video cellphone hack 2009 Oct 13, 11:15
QFC, the grocery store closest to me, has those irritating shoppers cards. They try to motivate me to use it with
discounts, but that just makes me want to use a card, I don't care whose card and
I don't care if the data is accurate. They should let me have my data or make it useful to me so that I actually care.
I can imagine several useful tools based on this: automatic grocery lists, recipes using the food you purchased, cheaper alternatives to your purchases, other things you might like based on what
you purchased, or integration with dieting websites or software. At any rate, right now all I care about is getting the discount from using a card, but if they made the data available to me then
the grocery store could align our interests and I'd want to ensure the data's accuracy.
idea boring data grocery store 2009 Oct 6, 9:43Articles on various APIs and other experiments from the NY Times. Some interesting things in here...
blog todo nytimes api programming mashup journalism technical 2009 Sep 27, 2:28Poster demonstrating example differences between Arial and Helvetica. Love the end line: "my buddies [said] ... “a documentary about a font is as interesting as it sounds.” i could not agree more."
visualization font design helvetica typography arial poster 2009 Sep 9, 5:35The FTP spec's section 3.5 'ERROR RECOVERY AND RESTART' describes how to resume an FTP download.
ietf reference ftp rfc resume download internet technical 2009 Aug 24, 9:56AtYourLibraryOrg interviews Cory Doctorow on library and librarian related Cory Doctorow topics, then breaks up his answers into short videos. Easy to watch and interesting.
video cory-doctorow library information drm literature business economics 2009 Aug 18, 4:19
Before we shipped IE8 there were no Accelerators, so we had some fun making our own for our favorite web services. I've got a small set of tips for creating Accelerators for other people's web
services. I was planning on writing this up as an IE blog post, but Jon wrote a post covering a
similar area so rather than write a full and coherent blog post I'll just list a few points:
- The first thing to try is looking for developer help for the web service, specifically if there's a REST-ful URL based API. For example, Bing Maps has great URL API documentation that would
be enough to create an Accelerator.
- The Accelerator XML is very similar to HTML forms. If you can find an HTML form for the web service for which you want to create an Accelerator, you can view the HTML source and create an
Accelerator based on that.
- I created the FormToAccelerator extension based on the previous idea. You can
use the extension to create an Accelerator from an HTML form, or just use it to create the start of one and edit it manually after.
- If the page doesn't use an HTML form, you can start up an HTTP debugger like Fiddler, use the web service from the normal web
page, and then in Fiddler see if you can find a REST-ful looking URL you can use.
- When looking to create a preview for your Accelerator, see if the web page for the web service has a mobile version or a version that's intended to embed in other web pages via an iframe. On
this same line, iPhone apps make great Accelerators usually with lovely previews.
- If there's no mobile or embeddable version and the only thing wrong with the normal web page for the web service is that the useful information doesn't fit in the preview window then see if you
can find an HTML tag with a name or id near the useful information, and stick a '#' fragment pointing to that tag onto the preview URL template.
- Without a reasonable REST-ful API you can use a combination of Google's "site:" and "I'm Feeling Lucky" to find the most relevant page on a particular site.
- The value of a name and value pair need not consist of only a single Accelerator variable. You can get creative and put other text in there. For instance, I implemented a Google currency conversion by setting the query to "{selection} in US Dollars".
technical accelerator ie8 ie 2009 Aug 13, 9:46An awesome health care protest sign. I've made a huge mistake.
humor photo obama politics television arrested-development sign protest 2009 Aug 11, 5:21"Michael Niggel took a look at Journey Under the Sea, and mapped out all possible paths. It turns out that death and unfavorable endings are in fact much more likely than the rest."
visualization via:ethan_t_hein literature fiction if interactive flowchart infographics chooseyourownadventure 2009 Aug 4, 7:19"Witnesses said that Sgt. Crowley, failing to recognize Gates on their flight to Logan Airport, arrested the tenured professor in midair, once again at the baggage claim, and twice during their
shared cab ride back to Cambridge"
humor onion politics 2009 Jun 29, 4:19
I've looked at my web server logs previously to see if anyone had used my Web Frotz Interpreter and until recently didn't realize that awstats (the web server log report generator) was truncating the query from my URL, so I couldn't tell that anyone was actually using
it. But after grepping the logs manually I've pulled out the URLs of visitor's text adventure sessions. If you'll recall, my Web Frotz Interpreter stores the game state in the
URL so its easy to see user's game states in the web server logs.
I've put some of the links up on the Web Frotz Interpreter page. Some of the interesting ones:
server-logs technical zork frotz pants interactive-fiction uri if 2009 Jun 27, 3:42
I've hooked up the printer/scanner to the Media Center PC since I leave that on all the time anyway so we can have a networked printer. I wanted to hook up the scanner in a somewhat similar fashion
but I didn't want to install HP's software (other than the drivers of course). So I've written my own script for scanning in PowerShell that does the following:
- Scans using the Windows Image Acquisition APIs via COM
- Runs OCR on the image using Microsoft Office Document Imaging via COM (which may already be on your PC if you have Office installed)
- Converts the image to JPEG using .NET Image APIs
- Stores the OCR text into the EXIF comment field using
.NET Image APIs (which means Windows Search can index the image by the text in the image)
- Moves the image to the public share
Here's the actual code from my scan.ps1 file:
param([Switch] $ShowProgress, [switch] $OpenCompletedResult)
$filePathTemplate = "C:\users\public\pictures\scanned\scan {0} {1}.{2}";
$time = get-date -uformat "%Y-%m-%d";
[void]([reflection.assembly]::loadfile( "C:\Windows\Microsoft.NET\Framework\v2.0.50727\System.Drawing.dll"))
$deviceManager = new-object -ComObject WIA.DeviceManager
$device = $deviceManager.DeviceInfos.Item(1).Connect();
foreach ($item in $device.Items) {
$fileIdx = 0;
while (test-path ($filePathTemplate -f $time,$fileIdx,"*")) {
[void](++$fileIdx);
}
if ($ShowProgress) { "Scanning..." }
$image = $item.Transfer();
$fileName = ($filePathTemplate -f $time,$fileIdx,$image.FileExtension);
$image.SaveFile($fileName);
clear-variable image
if ($ShowProgress) { "Running OCR..." }
$modiDocument = new-object -comobject modi.document;
$modiDocument.Create($fileName);
$modiDocument.OCR();
if ($modiDocument.Images.Count -gt 0) {
$ocrText = $modiDocument.Images.Item(0).Layout.Text.ToString().Trim();
$modiDocument.Close();
clear-variable modiDocument
if (!($ocrText.Equals(""))) {
$fileAsImage = New-Object -TypeName system.drawing.bitmap -ArgumentList $fileName
if (!($fileName.EndsWith(".jpg") -or $fileName.EndsWith(".jpeg"))) {
if ($ShowProgress) { "Converting to JPEG..." }
$newFileName = ($filePathTemplate -f $time,$fileIdx,"jpg");
$fileAsImage.Save($newFileName, [System.Drawing.Imaging.ImageFormat]::Jpeg);
$fileAsImage.Dispose();
del $fileName;
$fileAsImage = New-Object -TypeName system.drawing.bitmap -ArgumentList $newFileName
$fileName = $newFileName
}
if ($ShowProgress) { "Saving OCR Text..." }
$property = $fileAsImage.PropertyItems[0];
$property.Id = 40092;
$property.Type = 1;
$property.Value = [system.text.encoding]::Unicode.GetBytes($ocrText);
$property.Len = $property.Value.Count;
$fileAsImage.SetPropertyItem($property);
$fileAsImage.Save(($fileName + ".new"));
$fileAsImage.Dispose();
del $fileName;
ren ($fileName + ".new") $fileName
}
}
else {
$modiDocument.Close();
clear-variable modiDocument
}
if ($ShowProgress) { "Done." }
if ($OpenCompletedResult) {
. $fileName;
}
else {
$result = dir $fileName;
$result | add-member -membertype noteproperty -name OCRText -value $ocrText
$result
}
}
I ran into a few issues:
- MODI doesn't seem to be in the Office 2010 Technical Preview I installed first. Installing Office 2007 fixed that.
- The MODI.Document class, at least via PowerShell, can't be instantiated in a 64bit environment. To run the script on my 64bit OS I had to start powershell from the 32bit cmd.exe
(C:\windows\syswow64\cmd.exe).
- I was planning to hook up my script to the scanner's 'Scan' button, but
HP didn't get the button working for their Vista driver. Their workaround is "don't do that!".
- You must call Image.Dispose() to get .NET to release its reference to the corresponding image file.
- In trying to figure out how to store the text in the files comment, I ran into a dead-end trying to find the corresponding setter for GetDetailsOf which folks like James O'Neil use in PowerShell for interesting ends.
technical scanner ocr .net modi powershell office wia 2009 Jun 19, 8:07
The weekend before the previous, Sarah and I moved our belongings into the
new house and spent a lot of time packing and unpacking, and now we're officially living there (interested Facebook friends can find my
new address or just ask me). The Saturday of the previous weekend Sarah's family came over for a half house warming and half Sarah's birthday celebration which was fun and served to force us to do
more unpacking and forced me to take trips to Home Depot, Bed Bath and Beyond, etc. On Sunday, Sarah and I went out to her favorite restaurant and she opened her gifts that I had to hide to keep
her from opening before her birthday. Happy Birthday Sarah!
While at Home Depot I had trouble finding what I was actually looking for, but I did find everything I needed to terminate the Cat5e cables that are wired in the house. Each room has a wall plate
with two RJ45 sockets, both sockets wired to Cat5e cable. One of the cables per plate was already hooked up to a standard phone service punchdown board and the other cables per plate were all
hanging unterminated next to the punchdown board. So now I've terminated them all with RJ45 connectors and hooked them up to my hub, wireless router, cable modem, etc. I had the same sort of fun
setting all that up as I did playing with model train sets as a child. Hopefully no therapy will be required to figure out why that is.
personal2 train address sarah house new-house birthday 2009 Jun 1, 3:26Some unbelievable stuff in this video for future Xbox features. And I write 'unbelievable' as in, I find it difficult to believe the 3d motion sensing 'you are the controller' stuff would work as
well as it does in the demo video. The rest of the described features seem practical and sound neat.
blog microsoft video videogames xbox e3 2009 Jun 1, 11:07
When I heard that
Live Search is now Bing one of my initial thoughts was how'd they get that domain
name given
the unavailability of pronouncable four letter .COM domain names. Well, the names been used in the past.
Here now, via the
Wayback Machine is a brief, somewhat speculative, and ultimately anticlimactic
history
of bing.com:
-
2003 July: The first archived version of bing.com features "bing! is a small device (e.g., possibly even a small
Band-Aid(R)-like sticker!) that vibrates when a person's cell phone rings." I can't recall 2003 cell phones, were they big enough to require this device?
-
2004 August: Site for the same device is rewritten and looks much better, IMHO.
-
2006 June: The domain is now parked by easyDNS. I guess the "bing!" device didn't work out?
-
2006 November: Its now "BING*" and they won't say what they're working on ("we're still in stealth mode") but they are
hiring C#/.NET developers.
-
2007 January: And they're gone. Without even exiting stealth mode. Too bad, I liked their logo. Their domain is now for
sale...
-
2007 February: Looks like EasyMail buys the domain and offers a physical mailing service in Australia: "By simply clicking
a button on your computer, mail is beamed electronically to a bing post office. Your mail is automatically printed, folded, enveloped and dispatched into the Australia Post network the very same
day."
-
Present: Now its the new home for Live Search of course.
The new name reminds me of the show Friends. Also, I hope they get a new favicon - I don't enjoy the stretched 'b' nor its color scheme.
microsoft technical domain history search archive dns bing 2009 May 29, 12:12"Any object in Amazon S3 that can be read anonymously can also be downloaded via BitTorrent. ... Retrieving a .torrent file for any publicly available object is easy. Simply add a "?torrent" query
string parameter at the end of the REST GET request for the object." Yes, this is awesome!
torrent amazon s3 bittorrent p2p via:pskomoroch 2009 May 25, 10:19"Wallace and Gromit return-this time as purveyors of the Top Bun bakery, despite the fact that 12 other local bakers have disappeared in the previous year. Now it's up to Gromit to solve the mystery
while Wallace woos new love interest Piella Bakewell."
humor movie wallace-and-gromit animation claymation for:hellosarah 2009 May 13, 11:21Lots of interesting notes on the company culture of Zappos. "Yesterday I was lucky enough to visit Zappos and get a tour and talk with some of their executives, including Tony Hsieh, CEO."
twitter marketing business culture zappos shoes ecommerce