Wednesday, February 15, 2012

Falling in love with the Google+ API


By Melina Mattos, Program Manager for Google Africa and Bob Aman, Program Manager for Developer Relations

Cross-posted from the Google Africa Blog

Attention developers! Of the 90+ Google APIs, which is your favorite? We know that we fell in love with the Google+ API after we saw the amazing applications built from the Hackathons in South Africa and Kenya. We want to continue spreading the love!

This Valentine’s Day we’re thrilled to announce that we are holding three more Google+ Hackathons with the support of the Google Technology User Groups (GTUGs) in Accra, Kampala, and Lagos.

If you are ready to wow us with your application, please apply for the event using these forms: Kampala on March 10 at the 4th floor of Solis House, Lagos on March 17 at the CCHub Nigeria, and Accra on March 21 at the Meltwater Entrepreneurial School of Technology.

Remember to start today on getting those creative juices flowing! Familiarize yourself with the API and review these resources. Begin gathering ideas and coding a little. Take advantage of the Google+ Platform Office Hours on the 15th of February. If you have any questions, please address them to us in our Google+ Hangout on February 23. Use the Hackathon to perfect your application and win one of the multiple prizes we will be awarding - including a ticket for the overall winning application to Google’s premiere developer event, Google I/O!

Any updates relating to these Hackathons and the Hangout will be posted on Google+ (of course!) using the hashtag #hackgplus. Stay tuned!


Posted by Scott Knaster, Editor

Tuesday, February 14, 2012

Building Web Apps? Check out our Field Guide

Author Photo
By Pete LePage, Developer Advocate

Yesterday, the Chrome Developer Relations team launched several new resources, including the Field Guide to Web Applications. It’s a new resource that is designed to help web developers create great web apps. We’ve heard loud and clear from users that they want more and better web apps, and we hope this new field guide will enable you to create those web apps. Our fictitious author Bert Appward guides you through topics like the properties of web applications, design fundamentals, tips for creating great experiences, and a few case studies that put best practices to use. Whether you're building your first web app or are just looking for ways to improve your existing apps, I hope you'll find the field guide useful.




We built the field guide to embody the principles and best practices that it preaches. We stepped away from the normal webpage look, and instead designed the experience around a field guide. We used many CSS3 features like box-shadow, opacity, multiple backgrounds and more to provide a rich, visual experience. To make sure that it worked offline, we used AppCache and other than some URL rewriting techniques, didn't use any server-side code. We used the HTML5 History API to maintain page state even though everything is served from a single HTML page. We've started working on a new case study about the field guide, so check back soon for that!


Pete LePage is a Developer Advocate on the Google Chrome team and works with developers to create great web applications for the Chrome Web Store. He recently helped launch the +Chrome Developers page on Google+.

Posted by Scott Knaster, Editor

Image results now available from the Custom Search API

Author Photo
By Nam Nguyen, Software Engineer

Last year we added image results to Google Custom Search Engines to enable sites to offer image-only results that showcase photos and other digital images. For site owners who want more flexibility in presentation, they are also now available from the Custom Search API.

Read more about accessing Image Results from the Custom Search API or try it out in the Custom Search API Explorer. For billing purposes, image queries will be treated the same as web queries. If you are still using the deprecated Google Image Search API, now’s a great time to switch!

Below is an example of an image search to find small jpeg images of flowers:

https://www.googleapis.com/customsearch/v1?key=YOUR_API_KEY&cx=YOUR_CSE_ID&q=flower&searchType=image&fileType=jpg&imgSize=small&alt=json

With a valid key and cse id, here is a possible json result returned for an image item:
{
   "kind": "customsearch#result",
   "title": "flower-photo",
   "htmlTitle": "\u003cb\u003eflower\u003c/b\u003e-photo",
   "link": "http://images.example.com/flowerphoto.jpg",
   "displayLink": "images.example.com",
   "snippet": "photo of flower",
   "htmlSnippet": "photo of \u003cb\u003eflower\u003c/b\u003e",
   "mime": "image/jpeg",
   "image": {
    "contextLink": "http://images.example.com/flowergallery.html",
    "height": 100,
    "width": 100,
    "byteSize": 6104,
    "thumbnailLink": "https://encrypted-tbn2.google.com/images?q=tbn:3x4MPL3",
    "thumbnailHeight": 82,
    "thumbnailWidth": 82
   }
}

which you can use to render the image in your own site.

Note that you need to enable image search in your custom search engine control panel for the custom image search to work.


Nam Nguyen works on the JSON/Atom Custom Search API, which lets developers retrieve and display results from Google Custom Search programmatically. He is dedicated to making developers' lives a little easier by providing a simple API.

Posted by Scott Knaster, Editor

Monday, February 13, 2012

A fresh new look for HTML5Rocks.com

Author Photo
By Eric Bidelman, Senior Developer Programs Engineer, Google Chrome Team

Over the past year, HTML5Rocks.com has become a top destination for developers craving to learn more about HTML5. Today, we have over 60 articles and tutorials covering the latest HTML5 tech, published by 30 contributors from around the world! We've worked hard to bring great content to the site as quickly as possible, but it's been challenging to consolidate so much information as HTML5 continues to push the web forward and evolve at an accelerated pace.


HTML5 Rocks logo

Today, we're launching an updated HTML5Rocks with better tools for finding content, including an edgy new look and "rocking" logo. As our content expands, finding things becomes more important. To address this, we've created "persona pages" with catered content in 3 different verticals (Games, Business, Mobile). If you're one of those developers, finding content relevant to you should now be a snap. We've also consolidated many of the different components (Updates, Studio, Playground) into the main site and have deeply integrated the HTML5 technology classes to bring a better identity to the content.

All in all, it's a little bit Punk and a little bit Rock and Roll.

Lastly, if you're interested in contributing to the site, it's an open source project and we'd love to have your expertise. See our contributors guide.


Eric Bidelman is a Senior Developer Programs Engineer on the Google Chrome Team and a core contributor to html5rocks.com. He is the author of the book Using the HTML5 Filesystem API.

Posted by Scott Knaster, Editor

See you at the Game Developers Conference

Author Photo
By Amy Walgenbach, Developer Marketing Team

We’re returning to the Game Developers Conference (GDC) in San Francisco this year with 2 Developer Days and a booth on the Expo floor. At the conference we'll be giving a peek at the latest technologies we're developing for games.

Our Developer Days will take place in Room 2020 at Moscone Center. Day 1 (March 5) will focus on web games and Day 2 (March 6) will feature mobile games. From scalable servers, to high-performance code and graphics in web browsers, to porting console games to the web, come learn about how our technologies can help you better create, distribute, promote, and monetize games. We also have several Googlers speaking at other sessions during the conference. In addition, we'll have booth 1901 on the show floor March 7th-9th where you can meet Googlers working on games, demo what's new, meet partners, and get answers to your questions.

For more information on our presence at GDC, including a full list of our talks and speaker details, please visit http://www.google.com/events/gdc. If you stop by, you might even be able to score a pass to Google’s invitation-only GDC party. We look forward to meeting you in person!


Amy Walgenbach leads marketing for the Google+ Platform and developer marketing for games at Google.

Posted by Scott Knaster, Editor

Friday, February 10, 2012

Fridaygram: Unicode, ancient lake, very ancient sound

Author Photo
By Scott Knaster, Google Code Blog Editor

Unicode was created with the ambitious goal of representing every human language, with room left over for a whole bunch of symbols, too. More than 20 years after Unicode was started, over 60% of the pages on the web are now encoded in Unicode. That’s pretty good growth when you consider that Unicode’s coverage was less than 5% of the web in 2005. Having a standard like Unicode is important because, as Mark Davis writes, "The more documents that are in Unicode, the less likely you will see mangled characters (what Japanese call mojibake) when you're surfing the web."


In news of older stuff, a Russian expedition that has been working for 10 years has finally drilled through Antarctic ice and reached Lake Vostok, a huge freshwater lake more than 12,000 feet below the surface. The ice has covered this lake for at least 15 million years, which is well before the work on Unicode began. Eventually the team will take samples of the lake water, looking for signs of life and other ancient treasures.

Finally, you can go back even further in time and listen to the song of a cricket that was around during the Jurassic period, 165 million years ago. That cricket really sounds great for its age.


On Fridays we take a break and do a Fridaygram post just for fun. Each Fridaygram item must pass only one test: it has to be interesting to us nerds.

Saturday, February 04, 2012

Google Summer of Code 2012 is on!


By Carol Smith, Open Source Team

Cross-posted with the Google Open Source Blog


Today at FOSDEM I was proud to announce Google Summer of Code 2012.

This will be the 8th year for Google Summer of Code, an innovative program dedicated to introducing students from colleges and universities around the world to open source software development. The program offers student developers stipends to write code for various open source projects with the help of mentoring organizations from all around the globe. Over the past seven years Google Summer of Code has had 6,000 students from over 90 countries complete the program. Our goal is to help these students pursue academic challenges over the summer break while they create and release open source code for the benefit of all.

Spread the word to your friends! If you know of a university student that would be interested in working on open source projects this summer, or if you know of an organization that might want to mentor students to work on their open source projects, please direct them to our Google Summer of Code 2012 website where they can find our timeline along with the FAQs. And stay tuned for more details coming soon!


Posted by Scott Knaster, Editor

Friday, February 03, 2012

Fridaygram: science education, simulating galaxies, spider webs

Author Photo
By Scott Knaster, Google Code Blog Editor

Most software developers started getting interested in technology at an early age. With that in mind, Google Roots in Science and Engineering (RISE) is a program that annually awards grants to groups that come up with great new ways to teach students in Computer Science (CS) and science, technology, engineering, and math (STEM). This year’s awards were just announced. The winners included a program that helps primary school students in Dublin, girls in the San Francisco Bay Area, and kids in Uganda who want to learn about technology.

Scientists love to have reproducible results so they can test theories and ideas. What if you’d like to reproduce the creation of a galaxy? That task is still out of scale for humans, but scientists at the Laboratoire pour l'Utilisation de Lasers Intenses (LULI) have figured out a lab procedure that simulates the magnetic fields in newly formed galaxies. The experimental version uses lasers and carbon rods in place of clouds of gas and dark matter, but the results are useful, and you don’t need a galaxy-sized lab to work in.

Narrowing our view from giant galaxies to little spiders, a new study says spider webs are not just strong, but also have the ability to become either stiff or soft, as necessary. Spider webs are also designed to stay as strong as possible when strands are damaged. So spiders are good engineers.

Finally, you might use some of your weekend time to ponder this Vi Hart video about SpongeBob SquarePants and Fibonacci sequences.


Fridaygram posts are just for fun. Fridaygrams are designed for your Friday afternoon and weekend enjoyment. Each Fridaygram item must pass only one test: it has to be interesting to us nerds, and we certainly love our lasers.

Tuesday, January 31, 2012

Angry Birds Chrome now uses the Web Audio API

Author Photo
By Fred Sauer, Developer Advocate

Cross-posted with the Google Web Toolkit Blog

Last week Angry Birds for Chrome was updated to use the Web Audio API for all its in-game audio for Chrome users, which means Chrome users get the full Angry Birds experience, without any plugins. The Web Audio API supports a wide variety of use cases, including the high fidelity and low latency requirements of games. Users of other supported browsers will still get sound via Flash or HTML5 audio.



How does this cross-browser audio magic work? As you may have seen or heard, Angry Birds was in no small part made possible by the cross-platform open source PlayN library. When building for the HTML platform, PlayN in turn relies heavily on Google Web Toolkit (GWT) to delivery a highly optimized web experience for users, and on gwt-voices to easily deliver a cross-browser audio experience.

The responsibility of choosing the appropriate audio API for the game's sound is (mostly) left up to gwt-voices, which chooses the audio API that will give the best experience. If you'd like to hear how other audio APIs perform, you can ask gwt-voices to try to use the Web Audio API, Flash, HTML5 Audio, or even native audio. Your mileage will vary by browser and platform and which plugins you have installed. Also, gwt-voices will select the best available fallback, if the desired audio API is not going to work at all in your environment.

Want to learn more? Check out the Web Audio API tutorial and don't let those pigs grunt too much.


Fred Sauer is a Developer Advocate at Google where most of his time is devoted to Google App Engine and Google Web Toolkit. He is the author of various GWT related open source projects including gwt-dnd (providing in browser Drag and Drop capabilities), gwt-log (an advanced logging framework) and gwt-voices (for cross browser sound support). Fred has dedicated much of his career to Java related development, with an increasing focus on HTML5.

Posted by Scott Knaster, Editor

Monday, January 30, 2012

Translating JavaScript to Dart

Marcin
Aaron

By Aaron Wheeler, Senior User Experience Prototyper, and Marcin Wichary, Senior User Experience Designer

Cross-posted with the Chromium Blog

It took approximately 2000 years for the original Rosetta Stone to be discovered, which helped translate the Egyptian Hieroglyphs. We couldn’t wait that long to bridge the Dart and JavaScript worlds, so today we are releasing the JavaScript to Dart Synonym app.

Like most web developers, we are familiar, comfortable, and productive with JavaScript. We were curious about Dart, and thanks to a recent Dart hackathon, we had the chance to play with the language and libraries. The problem was, as JavaScript developers, we didn’t know how to map common JavaScript idioms to Dart. Hence the idea for this synonym app was born.

We started with the basics that every JavaScript and jQuery developer knows: variables, arrays, functions, classes, DOM manipulation, and many more. Then, with the help of the Dart team, we recorded the corresponding Dart versions of each idiom. To practice what we learned, we wrote this app with Dart.



We hope our app that maps between JavaScript and Dart eases your introduction to Dart and gives you a sense of where the project is going. We know the team is eager to hear your feedback. Don’t hesitate to join the conversation or file a new issue for either Dart or the Synonym app. And remember, Dart isn’t set in stone, so your feedback counts.


Aaron Wheeler is a user experience prototyper working on special projects that go beyond the Web. He balances design and engineering outside of work as well, splitting time between artistic pursuits and bicycle maintenance.

Marcin Wichary is a user experience designer, currently working on the Chrome browser and thinking of the future of the Web platform. He also occasionally codes interactive homepage doodles, such as Pac-Man and Stanislaw Lem.

Posted by Scott Knaster, Editor