OH during the component-based software development lecture

Lector:

— I am personally not convinced with EJB-QL approach and I don't see why you should be unless you love to embed SQL into your code, then surely you can say "Yay! I love it" — otherwise, as I said, I am not convinced. 
Filed under  //   geek   uni  

Comments [0]

Flash must die and Flash eventually will

Start-up airline Virgin America has decided HTML is "good enough" for animating online content on its brand-new website, which went live Monday, dumping Flash.

I would only say I am not surprised at all by this step — given amount of pressure Apple has pressed on Flash-based content (and obvious progress of JavaScript support in modern browsers) it is not surprising.

© The Register — http://www.theregister.co.uk/2010/03/02/virgin_america_html_flash/

Filed under  //   apple   geek  

Comments [0]

British Piracy Bill May Kill Most Small Public Wi-Fi Connections

The new Digital Economy Bill, a piece of copyright crackdown legislation, would hold owners of open Wi-Fi connections in Britain liable for any form of copyright infringement conducted on their networks.  There would be zero exceptions for individuals, businesses, public locations, libraries, universities, or small businesses.That could essentially kill the popular open Wi-Fi movement by making it too dangerous to businesses and universities to offer open services to their customers.  Lilian Edwards, professor of internet law at Sheffield University states, "[The bill could] outlaw open Wi-Fi for small businesses.  This is going to be a very unfortunate measure for small businesses, particularly in a recession, many of whom are using open free Wi-Fi very effectively as a way to get the punters in."

Very disturbing news articles from DailyTech and Telegraph — namely these two:

If this is indeed the case, Orwellian future is closer, than we used to think. 

Jeremy Hunt, the shadow culture secretary, told the Times newspaper: “It is grossly unfair that Labour expects millions of innocent customers to pay extra each month because of the actions of a minority. By their own admission this will make broadband unaffordable to tens of thousands of people, which flies in the face of Government policy to increase take-up in disadvantaged communities.” ISPs have been vocally opposing the Bill for some time. BT described the measures as a “collective punishment”, while Carphone Warehouse called on the entertainment industry to pay for the measures, rather than consumers.


 

Filed under  //   geek   news  

Comments [0]

Google's commercial — very nice and probably didn't cost a penny

(download)

OK, granted — probably they did pay a great deal of money for the idea
to that guy (or guys, for all it worths) who invented and wrote a
script. However, filming was probably the cheapest in the history of
TV commercials ever. Like it. A lot.

Filed under  //   video  

Comments [0]

Digital Image Processing, Playboy and The Most Famous Image in Computer Science

Have you ever seen this girl? Odds are — if you've ever dealt with image processing as a computer science discipline, then you had — in fact, many times. 

You can probably pick any book on the subject and you'll find this picture — perhaps, significantly more than once. I found myself interested in tracking down, who's the girl on this picture; obviously, all I knew was her name — Lena.

Quick search has proven that I was not the only one who found it interesting. Go to http://lenna.org and find out for yourself, how Playboy's Miss November '72 has become the icon of the computer science. Here you can find the full page scan — slightly NSFW, but she's damn good anyway (and I can understand why computer scientists preferred her to their usual rabbits and landscapes).
Filed under  //   geek  

Comments [0]

On iPhone Unlock: official + unofficial = ?

I have my iPhone officially unlocked by O2. However, today I had to unlock it unofficially too — naturally, using blackra1n + blacksn0w combination (I've donated for blackra1n once, and now I feel like I need to donate for using blacksn0w — it was my most painless jailbreak and unlock ever). You can ask, why did I do that?

Well, how'd you like a reason: when I swap my SIM cards I am not necessarily at my home iMac so I can connect iPhone to iTunes to do an iActiva..damn, just to activate it! I don't want it, really — it's nowhere simple and counterintuitive like hell: I've activated it already once, and I've unlocked it once — why should I bother doing it every now and then?

So I had my iPhone blackra1n'ed, installed blacksn0w — whoa! It turns out, swapping SIM cards could be just that — swapping SIM cards. And this is the way it supposed to work.
Filed under  //   apple   geek  

Comments [0]

Awesomely stupid gamma-code encoder

Coded while professor explained what is the gamma code. Horribly inefficient but apparently works.

#
include <memory.h> #include <math.h> #include <stdio.h> int binlog(int number) { return log((float)number) / log(2.0); } int main() { int value = 26; char buf[0x100]; int i; int position = 0; memset(buf, 0x100, 0); printf("%d\n", binlog(value)); int power = binlog(value); for ( i = 0; i < power; ++i ) { buf[position++] = '0'; } buf[position++] = '1'; int remains = value - ( 1 << power ); int tmppos = position; for ( i = 0; i < power-1; ++i ) { buf[tmppos++] = '0'; } i = 0; while ( remains != 0 ) { printf("Remains: %d\n", remains); buf[tmppos-i] = '0' + (remains & 1); remains >>= 1; ++i; } printf("%s\n", buf); return 0; }
Filed under  //   geek  

Comments [0]

Developing using Eclipse CDT, remote Linux server and rsync

 

For quite a while I used to have a huge pain in my arse — namely, programming in C++ for Linux on my Mac.

I think I said this before, but I like IDEs — especially, I like Eclipse: it saves my time and allows me to develop stuff much faster and more efficiently, it is also great when you’re learning some new code (and if you have a very large project at hands, that means pretty much all the time).

The problem was, I should still build the project on Linux. That means I was doomed to put all the sources on the network drive, which was accessible both from my Mac and from Linux server, and build it all there. Not convenient and slow. Very slow, in fact — builds were taking ages and ages. Other guys were using stuff like vim and emacs, and I didn’t find it useful at all: these tools are old, and give you next to none help when it comes to writing the code. So I kept struggling with using Eclipse in this hostile environment, until I come out with the idea, which is best of all described by these few lines of Makefile:

build: 
       rsync -rvz . my.dev.server:/path/to/project 
       ssh my.dev.server 'cd /path/to/project && build' 

test: build 
       ssh my.dev.server 'cd /path/to/project && make test' 

Now, when I finish editing the files (or want to check something) I simply do on my local machine:

 kirillov:/local/source/dir $ make test 

And voila — all sources are synchronised, built and tested! An extra benefit of this approach is that I have no object files, .d files, executable files and other useless stuff in my dev-folder (and, consequently, visible in my project). An only downside is, if your source tree is very large, rsync can take a good deal of time (that is why I’m syncing only my subproject in my real Makefile).

 

Filed under  //   c++   eclipse   geek  

Comments [0]

SSH tunnelling, VNC and Mac OS X

That said, one can do almost anything as long as this anything is not writing a lecture (which that specific one should be doing — at least, theoretically). 

Now, I'm not different in any sense. Instead of writing an Image-Based Information Processing lecture (which puts me to sleep almost immediately — or is it the professor who does it?) I've managed to get a VNC working on my Mac. On my home Mac. 

Well, it all started with the TeamViewer, which suddenly stopped to work. It was disappointing, as I couldn't play with Boxee on my home computer during the lecture anymore, so I've tried to invent something. Indeed, I could SSH into my iMac (via a resident NAS which acts as an SSH gateway to my home network). What I ended up doing could be best described by these commands:

imac$ sudo port install tightvnc
imac$ vncserver 
... password
... verify
... your VNC server is running on iMac:1

nas$ sudo ssh -f roman@imac -L 5901:localhost:5901 -N
macbook$ ssh -f my-nas-username@my-nas-host 5901:127.0.01:5901 -N # it didn't work with localhost here

Then I simply used JollyFastVNC to VNC into my iMac by connecting to 127.0.0.1 and port 5901. Yay!

However, ten minutes later I realised, that in fact I can set up a tunnel to my Mac's default (bundled) VNC server on screen 0. So I did — and apart of the fact that I should've enabled monitor mirroring (otherwise it tried to skew my iMac's monitor + my HD TV connected to it into one rectangular window, which didn't look neither pretty nor comfortable), it did work quite good. That works and an only question I ask myself - why on Earth do I need it if TeamViewer has started working again?
Filed under  //   geek   mac  

Comments [0]

Woman & Man: an information exchange

via pixdaus.com

Filed under  //   pics  

Comments [0]

About

A mad-eye programmer. No, really!