Microsoft Live Labs - SeaDragon / DeepZoom

24. September 2009 15:04

Microsoft Silverlight 

Microsoft introduces yet another way to present you image collection online and its not only limited to present your huge photo collection but can also help you in your presentation (well I mean jaw-dropping presentation). After Microsoft Photosynth® it is another way to represent the collection of your picures. One thing is good for that you don't even have to download the huge/high resolution images from a website instead you can zoom in/out to get it all done at one place with this great technology. Here is how you can get a quick look and start.

To get started visit: http://livelabs.com/seadragon This is an official seadragon link where you get to know more about seadragon and DeepZoom . One good thing I found is that you can use Seadragon with AJAX and in Silverlight both and both supports APIs for developers to develop and leverage DeepZoom functionality. You can download the AJAX library and documenations to guide you throughout your own development process.

If you want to have a quick look on how this in actual works then visit: http://www.seadragon.com. Here you just have to give the URL of the photo you want to view with Seadragon viewer as shown in the below screenshot:

Once you provide the URL of your image just click Create and you can see the image withing the viewer above and other option to View, Embed and Share. Similarly here you can choose here from different images available.

 

In the coming posts I will describe how to use DeepZoom composer to create our own custom DeepZoom views. And atlast here is the outcome of the above.

 

 No Rating

.NET Framework 4.0 Architecture

23. September 2009 15:51

.NET Framework Microsoft 

 No Rating

GOOGLE Office - New York City

23. September 2009 01:29

Fundoo 

[flv:Google_NY.flv]

 

 No Rating

Using Hashtables

20. September 2009 21:40

C# 

Here I illustrate how to create and use hash table. Each element of hash table is a combination of Key/Value pair stored in a DictionaryEntry object. A value in a hash table can be null or contains no value but a key cannot be of null reference. Key in hash table work as an identifier for the value where you can search a hash table for a value with a specified key.

First you will need to import the namespace System.Collection. We use System.Collection namespace because it contains various interface and classes the defines various collection of objects like list, dictionary, queues, hash tables and bit arrays.

1. Adding Key/Values to Hash Table

using System;
using System.Collections;
class HashtableClass
{
 public static void Main()
 {
   Hashtable htbl = new Hashtable();
   htbl.Add("AL", "Alabama");
   htbl.Add("CA", "California");
   htbl.Add("FL", "Florida");
   htbl.Add("NY", "New York");
   htbl.Add("WY", "Wyoming");
   // Get a collection of the keys.
   ICollection coll = htbl.Keys;
   foreach (string str in coll)
   {
     Console.WriteLine(str + ": " + htbl[str]);
   }
 }
}

2. Clear all Key/Value pairs in a hash table

To clear all the key/value pairs in a hash table use Clear() method of a hash table class:

htbl.Clear();

3. Remove Key/Value pairs from hash table

Just if you want to remove a particular value from a hash table use the Remove() method of hash table class and specify the Key to remove the key/value:

htbl.Remove("NY");

4. Adding Key/value pair to hash table by using indexer

We can use Add() method of the hash table class to add key/value pair to the hash table, but instead we can use indexer to add key/pair:

htbl["NY"] = "New York";

5. Use the ContainsKey() method to check if hash table contains a key

Just a simple method to use with an IF condition:

if(htbl.ContainsKey("NY"))
{
       Console.WriteLine("Hashtable contains key NY");
}

6. Use the ContainsValue() method to check if hash table contains a key

Just a simple method to use with an IF condition:

if(htbl.ContainsValue("New York"))
{
Console.WriteLine("Hashtable contains value New York");
}

7. Copy the keys from hash table into an array using the CopyTo() method

string[] keys=new string[5];
htbl.Keys.CopyTo(keys,0);
 No Rating

Laws of Computer Programming

13. September 2009 02:42

Fundoo 

1.    Any given program, once deployed, is already obsolete.

2.    It is easier to change the specification to fit the program than vice versa.

3.    If a program is useful, it will have to be changed.

4.    If a program is useless, it will have to be documented.

5.    Only ten percent of the code in any given program will ever execute.

6.    Software expands to consume all available resources.

7.    Any non-trivial program contains at least one error.

8.    The probability of a flawless demo is inversely proportional to the number of people watching, raised to the power of the amount of money involved.

9.    Not until a program has been in production for at least six months will its most harmful error be discovered.

10. Undetectable errors are infinite in variety, in contrast to detectable errors, which by definition are limited.

11. The effort required to correct an error increases exponentially with time.

12. Program complexity grows until it exceeds the capabilities of the programmer who must maintain it.

13. Any code of your own that you haven’t looked at in months might as well have been written by someone else.

14. Inside every small program is a large program struggling to get out.

15. The sooner you start coding a program, the longer it will take.

16. A carelessly planned project takes three times longer to complete than expected; a carefully planned project takes only twice as long.

17. Adding programmers to a late project makes it later.

18. A program is never less than 90% complete, and never more than 95% complete.

19. If you automate a mess, you get an automated mess.

20. Build a program that even a fool can use, and only a fool will want to use it.

21. Users truly don’t know what they want in a program until they use it.

Currently rated 4.0 by 1 person