NEW YORK -- Imagine using your phone to snap a photo of the cool pair of sunglasses your friend is wearing and instantly receiving a slew of information about the shades along with a link to order them.

It's a great idea -- but it doesn't quite work.

Though many companies are trying to make "visual search" a reality, this seemingly simple notion remains elusive.

Take Amazon, which made visual search a key feature in its new Fire smartphone. The e-commerce company says the feature, known as Firefly, can recognize 100 million items. It's similar to a Flow feature Amazon has on its apps for other phones.

So far, Firefly can reliably make out labels of products such as Altoids or Celestial Seasonings tea. That makes it easy to buy items such as groceries online.

But try it on a checkered shirt or anything without sharp corners, and no such luck.

"It works really well when we can match an image to the product catalogue," says Mike Torres, an Amazon executive who works on the Fire's software. "Where things are rounded or don't have (visual markers) to latch on to, like a black shoe, it's a little harder to do image recognition."

Visual search is important to retailers because it makes mobile shopping a snap -- literally.

It's much easier to take a picture than to type in a description of something you want. Shopping on cellphones and tablets is still a small part of retail sales, but it's growing quickly. That makes it important to simplify the process as much as possible -- especially as people look to visual sites such as Instagram and Pinterest as inspiration for purchases.

"Retailers are trying to get the user experience simple enough so people are willing to buy on their phones, not just use it as a research tool," eMarketer analyst Yory Wurmser said.

Mobile software that scans codes, such as QR codes and UPC symbols, are fairly common. Creating apps that consistently recognize images and objects has been more challenging. Forrester analyst Sucharita Mulpuru believes it could take at least three more years.

Since 2009, Google's Goggles app for Android has succeeded in picking up logos and landmarks. But Google says on its website that the app is "not so good" at identifying cars, furniture and clothes in photos.

What's holding visual search back?

The technology works by analyzing visual characteristics, or points, such as colour, shape and texture. Amazon's Firefly, for example, identifies a few hundred points to identify a book and up to 1,000 for paintings. U.K. startup Cortexica uses 800 to 1,500 points to create a virtual fingerprint for the image. It then scans its database of about 4 million images for a match.

Without easily identifiable markers, non-labeled objects are difficult to identify. Lighting conditions, photo quality, distance, angles and other factors can throw the technology off. Visual search works best when there is a clearly defined image on a white background.

Some retailers are finding success with visual search by keeping the selection of searchable products limited.

Target's new "In a Snap" app works only with items from its Room Essentials furniture, bedding and decor line. And it works only when snapping a product image in a magazine ad, not when you see the actual product on a shelf. When a shopper scans the ad, items pop up for the shopper to add to a shopping cart.

Heels.com, an online shoe retailer, keeps visual search limited to shoes. Shoppers upload pictures or send links of shoes and are offered similar pairs for sale on the company's website.

"People shop through images nowadays," Heels.com CEO Eric McCoy says. "We want to give them the exact shoe, or something similar."

So, the race is on to perfect the technology that will create smartphone apps that easily recognize objects in a real-world environment.

Cortexica's founders spent seven years on academic research before forming the company in 2009. Since then, it has been trying to mould the technology work more like the human brain when it comes to identifying objects.

"Someday you'll be taking a picture of a whole person, and it will identify the different the things they're wearing and offer recommendations," says Iain McCready, CEO of Cortexica. "That's really challenging technically, but that's what people tell me they really want to do."

The U.K. company was hired by eBay to develop an app that recognizes cars from behind and matches them with similar cars available on eBay.

Next, eBay asked Cortexica to develop a similar app for fashion. The outcome was Find Similar, which analyzes a clothing item's colour, texture and shapes to find similar items available for sale. Find Similar is now being used by startup app Style Thief and other Cortexica clients.

Superfish, a startup in Palo Alto, California, counts 12 people with doctorate degrees on its staff and has 10 patents for visual search technology. Its technology can be found at PetMatch, an app that matches photos of pets with local pets available for adoption.

Superfish CEO Adi Pinhas believes it will be normal in two or three years to use your smartphone to search for things visually.

"Your camera will be as smart as the rest of your smartphone," he says.

Once that happens, Forrester's Mulpuru says, it will "unleash a whole new type of e-commerce."