Monday, October 27, 2008

How to setup Streaming for media - xbox 360, xbox, ps3, wii - movies, videos, music, pictures

How to set up a streaming media network | News | TechRadar UK
Software streaming

What if you only want to stream to a laptop or another PC? All you need is some software.

A dedicated media streamer is all well and good, but most of them cost in the the region of £100 to £200, which certainly doesn't make them the cheapest solution. If you want to view pictures or listen to audio on your laptop, or another PC in the house, then all you need to do is set up a shared folder, then browse to it on the network and open the files in the same way that you would do on the local machine.

As long as your network has the range, taking your laptop into the garden and plugging in some external speakers, is possibly the simplest way of getting music to your garden party. However, Windows networking is notoriously fickle, especially if you are mixing operating systems, so a dedicated software solution may be better.

Windows Media Player 11 is built into Windows Vista and can be downloaded for XP and once set up for sharing, WMP11 turns your PC with the media library into a media server. A Vista laptop will usually automatically detect a shared library and ask whether you want to connect to it. You can also share your iTunes library, and then access it from another PC or laptop running iTunes.

However, one of our favourite solutions for sharing media is Orb, which enables you to share music, video, pictures and documents, not just across your local network, but across the internet as well. It's a great way to listen to your music collection when you're at work, a friend's house or anywhere else that you can get a respectible internet connection.

Not only is Orb free, but you can use it to stream your files to the Xbox 360, Playstation 3, Nintendo Wii and even some handhelds, like the iPod touch and mobile phones. An alternative is TVersity, which will also work with any internet connected device that has a web browser that supports Flash.

Xbox 360

Got an Xbox 360? Then there's no need to buy yourself a separate media streamer. It's not just a games console you know.

While the Xbox 360 might have enjoyed phenomenal success as a games console, it has some other rather nifty tricks up its sleeve. Although the Xbox 360 has no built-in wireless, it does have an Ethernet connection, and there's a wireless adaptor available, although it does only use the 802.11g standard.

The Xbox 360 is designed to connect to a PC running Windows Media Center, and if you have a PC running that (either Vista, or Windows XP MCE) then the system works very well. The Xbox's interface is pretty much the same as Media Centre and it is slick and easy to use. If you don't have a PC running any form of media centre, then you can use Windows Media Player 11 instead.

Once sharing has been setup, the Xbox is able to connect and browse the folders in much the same way as any other media streamer. It's not nearly as good as the Media Centre Interface, and it has a nasty habit of failing to connect to our shared library, but when it works, it's pretty good. Since Microsoft updated the firmware, the Xbox is able to play Xvid and DivX content, but cannot play some other file formats. In this case, you can use a program called Tversity which can transcode incompatible file formats on the fly, into ones the Xbox can play.

Using Tversity, the Xbox can even stream live video feeds, which is a pretty unique feature. An alternative is to use Orb, which enables you to view almost any content you wish to share, by using folder sharing. You may not think that the Xbox is a natural contender for streaming audio and video to your TV and stereo, but after testing a large number of media streamers, we have to say the Xbox is actually one of the best devices we've ever used, especially when you decide to use it with Media Centre.

Playstation 3

Playstation 3 owners rejoice! You too can stream all your media with ease. Don't let the Microsoft fanboys have all the fun.

The last few months has seen a number of significant updates released for the PS3, all of which have increased the console's functionality. Like the Xbox 360, you can use Windows Media Player 11 to share your media and view it using the PS3. However, just as with the Xbox, Windows Media is a temperamental beast and can cause irrational anger and the urge to chuck the controller at the TV when it stops working properly.

In our expericene, you are much better off using Tversity, which also works with the Xbox. However, you will need to configure your router to make it work correctly, but it's a two minute job and is pretty simple. First of all download Tversity and leave all the settings at the defaults.

You may want to download FFDShow and any other additional codecs you use regularly. You'll need to change your Windows or third-party firewall settings to allow mediaserver.exe, which is found in the Tversity folder, access to the internet. Configure your router, by typing its IP address into your web browser's address bar, it's usually, but if it isn't, run ipconfig from a command prompt to determine your PC's IP address and use the first IP in that range for your router.

Within your router's control panel you find that you'll need to edit the section for virtual servers or port forwarding, and allow access to port 41952. In addition, just as with the Xbox, you can use Orb with the PS3, although instead of using the folder sharing, you use the built-in browser and navigate to

Wednesday, October 08, 2008

how to escape lucenes search characters

Lucene: Escaping Special Characters |
Thankfully, the necessary code to fix this isn't all that difficult. There are two scenarios at this point: 1.) You are using Lucene 1.9 or newer., or 2.) You are using Lucene 1.4 or prior

If you are using Lucene 1.9, the task of escaping user input for the query parser is very straightforward:

Lucene 1.9 Escaping

String userQuery = // ...
String escaped = QueryParser.escape(userQuery);
Query query = QueryParser.parse(escaped);
// ...

Thursday, October 02, 2008

best subversion merge guide

Domain of the Bored » Blog Archive » How to use svn merge
How to use svn merge

2006-10-29 23:49:10 UTC

A number of my fellow Adium developers have observed that svn merge is hard to use. I think the main problem is that the command is quite general (it can be put to several different uses) and the documentation not particularly clear. In order to promote better understanding of the svn merge command, here's what I know about it.

The command in a nutshell: svn merge is essentially svn diff $ARGS | patch -p0; the only real difference is that svn merge will handle addition, movement, and deletion of files, whereas patch won't.

This now having been stated up front, let's get into details.
Summary of tasks and how to do them

1. svn merge sourceURL1[@N] sourceURL2[@M] [WCPATH]
2. svn merge sourceWCPATH1@N sourceWCPATH2@M [WCPATH]
3. svn merge [-c M | -r N:M] SOURCE[@REV] [WCPATH]


To apply changes from another directory (branch, tag, trunk): Use format #1 (or #2 if you have a checkout of it), supplying at least the first revision (N), and the second (M) if it is not HEAD. With format #1, you should not need to be using the same repository URL as the CWD for either one or both; you should be able to merge between two URLs, or between a single URL into your checkout of a different URL.

To travel back in time to a previous revision: Use format #3, with -rHEAD:THEN. For example, -rHEAD:42000.

To cherry-pick a changeset (apply only that changeset, not any others): Use format #3, with -cTHEN.

To undo a particular changeset without disturbing things that happened after it (hopefully): Use format #3, with -c -THEN. Note the minus sign. For example, to revert r42000, use “svn merge -c -42000 .”. You can also use the -r flag: “svn merge -r 42000:41999 .”. This may be advisable, for clarity reasons, if you have a script that must always revert a particular revision.

In both examples, note the “.” and the space before it. “.” means the current directory, and is used here as the SOURCE argument to format #3. It's a separate argument from the revision, so you need the space.

All formats apply their changes to the CWD by default. I don't know what happens if the CWD is not a WC. You can specify a different destination for the changes by specifying a different WCPATH (the last argument in all the formats above).

In format #3, the first path that it accepts is a URL or local WC path to the object you want to diff. (Remember my initial statement about svn merge being essentially svn diff | patch -p0.) The second path is a local WC path to the destination for the changes that are observed.

Updated 2007-07-12: Fixed error in traveling back in time (I had the revs backward); added cherry-picking technique.
svn help merge, in RTF

The “svn help merge” text is an invaluable summary of the command's operation, but it's plain-text, and therefore somewhat hard to read on a screen. To that end, I created an RTF version and printed it out, and decided to put it up here in case anyone else wants to do the same.