Here's today's tidbits. I don't have much time so I'll keep the list relatively short (it currently amounts to about 10% of the stuff I have in my "pending" file):
Development
- Here's a bizarre trick (via Ayende): apparenly when binary-searching an array (via Array.BinarySearch) if the specified value is not found, you can get the index of the next largest value by bitwise-complementing the result (index =~ index;). Convoluted, but useful.
- Here's a cool shell extension improvement from Jeff Atwood called Clean Sources Plus (based on the original codebase by Omar Shahine); it allows you to "clean up" a VS.NET solution from intermediate files and source control bindings for sharing with other developers. Dead useful.
- Fascinating discussion in response to Jeff's post about eliminating the user field from login screens. Personally I don't think there's anything wrong with the current system (I read the post too late to participate meaningfully in the discussion), but there's a lot of interesting stuff to read there.
- Nifty demonstration of basic CSS 1.1 and JavaScript. It doesn't work in Internet Explorer because IE does not support alpha in PNGs (a very annoying limitation in itself) and does not fully implement DOM events.
- I stumbled upon an old article by Joel, which states something so absolutely obvious most people completely fail to realize it: people (and programmers specifically) are only very good at doing one complex thing at a time. Giving a programmer (even a good one) more than one project, or alternatively interrupting his project for "right here, right now" kind of work, is hazardous to his or her productivity. It reminds me of Fred Brooks' excellent The Mythical Man-Month; in retrospect the conclusion is just so obvious it seems almost impossible that people didn't realize it at the time.
Stuff
- DARPA challenge finally beaten! This is a huge event for robotics fans, which I'm not - however I recognize that this is a landmark in AI and robotics. Impressive stuff.
- My next keyboard is probably going to be the new Microsoft Natural Ergo 4000. I intensely dislike most keyboards out in the market these days (still use a Microsoft Natural Elite or IBM Model M) and it would be a nice change of pace to get a new Natural with added features (padded wrist-pad, standard page-up/down cluster etc.) which doesn't suck. I hope the tactile response is at least as good as the Elite's. I was looking to get one of those, but apparently only Dagesh carry those in Israel so far (for 380 shekels, shipping included ~ $75 + VAT); I would get it from eBay, but it won't cost any less and it's a warrantee nightmare. Guess I'll just wait.
- Here's an interesting concept: labs.zarate.org allows you to create passwords on a per-site basis by providing a master password and target URL. It works by MD5-hashing the master-password with the site URL. Cool idea and seemingly quite secure (assuming the hashing function is strong enough; considering the general quality of passwords people use, I'd say it's about 1,482,918 times better).
- The Flying Spaghetti Monster is apparently old news, but completely hysterical never-the-less, particularly in today's age of religious zealots and their "intelligent design" dogma.
Politics
- Assuimg this article is to be believed, post-Taliban Afghanistan is about to put a journalist on trial for charges of blasphemy. You'd think that the US with its self-proclaimed desire to bring democracy to the world would not have left a radical Islamic government in Afghanistan. You'd be wrong.
- UK Labor party member Walter Wolfgang, 82, was forcibly ejected from a conference for heckling the foreign secretary. This in itself is common in stupid political strife; what worries me is that a second delegate (Steve Forrest) who protested the treatment was also forcibly ejected and then denied access to the venue under the powers of the Terrorism Act. If said act can be used to circumvent lawful political activity by democratically-elected public officials, I cringe at the thought of what kind of power it gives the police over, say, an ex-Israeli army officer visiting London.
- A Delaware public official lost in court against an anonymous blogger who posted what said official perceived were defamatory comments against him. The court ruled that the blogger's ISP may not expose his identity, which I consider a major win for free speech. Too bad other courts are not quite as sensible.
About a month ago I invited a bunch of people to an impromptu LAN party to be held at my parent's house (as they were out of the country at the time). Despite some organizational hurdles (primarily the lack of a network switch with enough ports) we eventually managed to overcome the party was sweet, short and to the point.
Omer playing StarCraft
During the course of about 20 hours we played loads of Call of Duty, some StarCraft: Brood War, a bit of WarCraft III and a whole lot of my personal favourite: UT2k4. UT flavours included regular deathmatch, quite a bit of Onslaught (not my favourite of gaming modes, but nevermind that), a little bombing match and what I consider the best gaming-mode: instagib deathmatch. It's hillarious, and you can't beat the andrenaline rush (well, except maybe Q3 DM17 with 5 bots at hardcore).
Myself, concentrating on a round of UT
As usual we saved StarCraft for the wee hours of the night. The two games I played prove that I can still hold my own; my personal preference is for team melee where I control base contruction and expansion at first and combat later, with a second player supporting me on construction and exploration at first and maintenance later. I find that I'm extremely capable when it comes to fast micromanagement but am terrible when I have to do more than one big task at once (for example managing combat while micromanaging fleet construction). Playing with my brother that way was an extremely effective combination and we took the game by a large margin, which was very satisfying.
Oren next to Call of Duty
My personal
forté is first person shooters though, so it's no surprise that's what I played the most (I couldn't be bothered joining in on WarCraft III). We played Call of Duty and UT2k4 for several hours each; Call of Duty proved to be an excellent multiplayer game, but only if there are a lot of players in the game. 8 players are enough for a good game, but say 5 or less simply aren't enough to keep the action up and the game becomes very dull indeed.
I wish I could convince the others to give Tron 2.0 a multiplayer spin, but other than that I don't even know where to start in looking for good multiplayer games. Halo proved to be a big disappointment for me (way too slow - not in performance but in gameplay - and too much emphasis on vehicles) and trying Counter Strike: Source for a bit only strengthened my resolve not to play tactical shooters.
Am I the only one going insane over the time it takes for the average IDE to load these days? It takes Visual Studio 2003 up to ten seconds from click to functionality, and with ReSharper installed (which I consider a must-have) it takes ever longer. In the days of multiple-gigaherz machines with multiple-gigabytes of RAM and souped-up, quad-rate busses, why the hell do I have to wait for my development environment to load?
Mind you, VS2003 is not the worst of the bunch; Eclipse used to be the slowest-starting app I've ever seen up until version 3.1. Now it's more or less on par with VS2003. NetBeans lags behind in the performance department. Looking at the VS2005 beta 2 (I haven't tested the RCs) it looks like Microsoft has improved performance - at least startup performance - drastically. I certainly hope that's the case. Since I usually work with 3 or more instances of VS2003 open concurrently any improvements to its performance or memory footprint would be welcome in the extreme.
A product I'm working on consists of a primary component and two sattelite components. The sattelite components are designed to run remotely and communicate with the primary component via .NET Remoting. The product is currently undergoing a QA cycle, and the QA team had a bizarre issue to report: when the system is configured to run on localhost and the network cable is disconnected while the system is up and running, remoting requests fail (they reported that the primary component fails to notify the satellite component instances to shut down, but it was actually the same with any remote call). My immediate response was "huh?" but subsequent local testing assured me that they weren't smoking anything illegal.
After quite a bit of research (this is a seemingly little-known issue with .NET Remoting) I managed to come some interesting insights into .NET, but only one relevant post I managed to find after playing with Google Groups a bit: apparently when Windows detects a network cable disconnect (via a feature called Media Sense) it "removes the bound protocols from that adapter until it is detected as "up" again". The only workaround I could find was to completely disable Media Sense, which needless to say is a very unwelcome solution.
I suppose the obvious question is "why the hell does Media Sense shut down localhost connections?" I'm often dumbfounded by bizarre design decisions in Microsoft products, but this one may just necessitate adding a really awful hack to our installation procedures on clients' sites, which just sucks.
And now for the rest of it.
General Stuff
- The Deer Park (Firefox 1.5) beta has been out for a couple of weeks now and is very stable and fast; beta 2 is due to come out any minute now. Despite the lack of a compatible Noia 2.0 eXtreme (my favourite Firefox theme) I highly recommend the upgrade.
- Fasterfox is a major performance tweak for Firefox. We don't have the fastest internet connection here so it's difficult to tell how effective it is, but I'll try and gauge it over the next few days anyway.
- Metal Gear Solid fans owe it to themselves to hear virt's remix titled My Frequency Is 140.85.
- Martin of Tipmonkies (heh. Tipmonkies. Heh.) published a list of free disposable e-mail address services. My personal favourite is DodgeIt.
- Finally, Serenity seems to be doing rather badly financially. I haven't seen the movie yet (and I doubt I'll get to see it in the Israeli theaters, with all the crap movies taking valuable theater space) but I have a very good feeling about it, and I hate to see anything original, interesting or (in Firefly's case) underdog do badly.
- Mystified by Virgill is awesome. For that matter, so is elements. The guy knows his shit.
Politics
- It bothers me a great deal when American agencies (or goverment agencies in general) presume to tell me what I'm entitled, or not entitled, to. As far as I'm concerned the default should be "I can do whatever the hell I want as long as it's not declared illegal", not "I can do whatever is declared legal". Very important distinction. So it's no surprise I was really pissed off to read an FCC document in which a statement began with "consumers are entitled to run applications and use servics of their choice". Thanks! I always wanted a government to officially allow me the liberties I've always taken for granted. But that's nothing compared to the rest of the statement: "... subject to the needs of law enforcement." You know what? To hell with the needs of law enforcement. I won't have police/FBI/shabak/whatever goons telling me what programs I can or can't use. I realize that it's like that in practice (the old issue of >128-bit RSA encryption not allowed outside the US, for one), but it's no excuse to make it official policy. I'll run whatever the hell I want on my machine. If it's illegal, have the police come up with sufficient justification for a search warrant, signed by an independant judge.
- The US Patent Office upholds a patent owned by Eolas, which has bearing on their case against Microsoft. I don't know the details of the patent and don't care. Ideas and thoughts should not be patentable, as simple as that. As Florian Mueller puts it (direct quote from the linked article):
Pro-patent politicians told us that broad and trivial patents can be invalidated. If even Microsoft with all of its resources doesn't always succeed in that, what can smaller companies do?
- Apparently a single, disabled mom has found the strength to sue the RIAA back for wrongful legal practices. Any dent in the RIAA litigation behemoth is a good thing in my book.
- An ISP owner from Oklahoma wins a $10M lawsuit against a known spammer. It's doubtful he'll be getting any of his money, but the precedent-setting case is good in the long run anyway.
Seeing that I don't have anything of value to write per se (with the exception of experiences from the LAN party, and Turkey, and a bunch of reviews, and some development-related rants, and some other stuff) I figure I might as well just toss everything I have here. There's quite a bit of development-related stuff so I've split this into two seperate posts:
- Ilya linked me to this newsgroup discussion which is something of a revelation.
- During the QA cycle for a product I'm working on I got a request to limit the logs for just the last 10 days. I use log4net 1.2.9 incubation release, which is an absolute pleasure to use (even the documentation is up to snuff these days); however I've found that there is simply no way to do that using the stock RollingFileAppender when you roll by date (as opposed to by size). Since I didn't have time to research creating scheduled tasks using the godawful Visual Studio 2003 Setup and Deployment Project I just hacked a RollingFileAppender-derivative, only to find that most of its protected methods are not declared virtual - meaning I had to copy the code for the class in its entirety and hack away instead of just inheriting and overriding behavior. If anyone's interested in the hack let me know, but be advised that it's probably not very stable nor particularly elegant.
- I was looking for a way to execute an interactive process remotely (which can't be done easily, certainly not with my original research subject, WMI). Apparently the only practical way to do this under Win32 is to use a remote service with administrative privileges; security was a workable issue in this case, so I was left with having to research and write the service and deal with all the bugs, which given the project schedule was not an option. The first obvious option was to use SysInternals' PsExec tool; this would've been perfect except that PsExec's license forbids redistributing it without a license, which we were very inclined to purchase had there not been easier (and cheaper) options. BeyondExec is an equally solid solution that's distributed as freeware and is therefore useful for commercial purposes. Lastly, Jim Wiese has an interesting article up at The Code Project which might've saved us a great deal of time had BeyondExec proved irrelevant.
- John Wood's SafeInvoke is a very elegant solution to the classic GUI thread invocation issue when programming for Windows Forms. He's not the first to utilize .NET Reflection for that purpose, but his solution is extremely elegant as well as performant (since his helper class caches the generated code, a performance hit is incurred only when a delgate is first used, and System.Reflection is supposed to be dramatically faster in the upcoming CLR 2.0). Two thumbs up.
- One of my favourite writers, Reymond Chen over at The Old New Thing, wrote an insightful little tip on why you should never use sleep(0). The comments are equally informative. On a side note, I've recently become a very big fan of java and C#'s Monitor synchronization primitive along with its signalling capacity (in java it's part of the java.lang.Object API
, which is much more elegant than C#'s Monitor class and its static members).
Damned if I know why, but the Call of Duty 2 demo sucks. Oh, I can describe the symptoms alright, but there's a fundamental problem there that eludes me. Why would a sequel that's seemingly based off of the same (extremely good) codebase as its predecessor not be able to compete in visuals and performance with two year-old games?
Now don't get me wrong, I'm as big a sucker for visuals as the next guy (if not more so), but although the CoD2 screenshots look pretty sweet there's nothing there to take the visual acuity crown from either of the games I mentioned above. There's certainly nothing to justify a former hi-end machine - AthlonXP 2800+, 1GB RAM, Radeon 9800XT - grinding to unplayable framerates at low resolutions (about 20 frame per second at 640x480 with most everything turned either off or low) or having decimal-point framerates at high resolutions (0.2-0.5 frames per second at 1024x768 with medium-high details and no antialiasing). The same machine plays Doom 3 and Half-Life 2 at 1024x768 with x4 AA and crunches frames like there's no tomorrow. To reiterate, both games look considerably better than CoD2.
On a radically different note, I managed to miss the fact that the Serious Sam II demo is out. I'm downloading it and will report when I get the chance to play it. Indigo Prophecy is out too, so I guess my current playlist reads something like:
Guess I gotta get some spare time on my hands...
There is one particularly nasty blogspammer which every few days posts a spam comment to this post. MT blacklist doesn't seem to cut it in stopping the bastard.
Has anyone had success fighting off blogspammers? Do you have any advice?
What the hell were the guys at Microsoft on when they build the Setup and Deployment Project code for VS2003? To say that is sucks would be some of the biggest understatement ever. All I wanted was for my application to delete some intermediate files when it uninstalls. You'd expect to be able to do that from the File System settings of the install project, but you'd be dead wrong; of course, the next logical step is to interject a script of some sort into the uninstall chain. Simple enough.
I wrote a 7-line batch script to do the work for me (batch files are crappy scripting tools, but you'd be surprised what you can do with them with enough patience) only to find out that, well, you can't add bloody batch files as custom actions; you can only add DLLs, EXEs and VBScript/JScript files. So I spent an hour teaching myself the basics of VBScript (I already have a solid handle of VB6, just needed a look at the WSH reference and some turorials about FileSystemObject) and moved on.
Only to find out that the script doesn't work; it's run from a god-knows-which working directory, meaning you have to do some extra fussing around to get to the right directory. After a little reading I found the Session.TargetPath property, which apparently doesn't do the trick. To make a long story short, I found a tutorial on The Code Project which showed me how to do it:
- Add [TARGETDIR] to the CustomActionData property of your custom action
- The property is accessible with Session.Property( "CustomActionData" )
Why the hell is the simplest thing with MSI so goddamn convoluted?
Just realized it's been quite a while since I posted anything demoscene-related. Well here goes: you positively, absolutely must watch Iconoclast. It is the single most important demo since, well, I have no idea. It's broad, it's beautifully executed, it's glriously original and it's insanely well-programmed (running smooth as silk on my Radeon 9700-equipped laptop) and it has some of the best music ever written by a scener. I've been following aMUSiC and Leviathan since the 2002 demo Edge of Forever and they never cease to astound me. Actually, now that I've mentioned ASD, you should definitely watch Edge of Forever, Dreamchild, Eon and Planet Risk.
Iconoclast by Andromeda Software Development (All images shamelessly stolen from pouet.net)
Also noteworthy is the Assembly'05 demo from Synesthetics called sts-04: instant zen which, while not altogether very different from their debut demo at Breakpoint 2005 sts-03: aeon flux is very well made and has great music.
The 200mb or so video download for TBL's 2005 comeback Ocean Machine is very well worth it; aside from being an Amiga demo (an achievment in itself over 11 years after the last machine was launched) it has some really stunning effects, such as the dancing ninja (?) in the screenshot below, and a brilliant soundtrack by Crankshaft.
Ocean Machine by The Black Lotus
Portal Process have been prolyfic lately. After winning The Gathering 2005 with the singularly cool meet the biots they got 3rd place at Assembly 2005 with don't stop. Now don't get me wrong, "don't stop" is a great demo - but it's just more of the same. Stick with "meet the biots", it was great.
meet the biots by Portal Process
64k intro in javascript? Very much so - redbug is wicked!
Finally, plastic's astounding 195/95 and Final Audition are an absolute must-see, particularly the final version of 195/95.
195/95 by Plastic
|