Sign in with
Sign up | Sign in

Chrome Browser Beta Now Supports C, C++ Apps

By - Source: Google | B 28 comments

The latest beta of Google's Chrome browser adds support for apps written in C and C++.

Thursday Google Chrome software engineer Chris Rogers said that the latest beta channel release (14.0.835.35) brings big improvements to the popular browser.

For starters, Chrome Beta received what the company calls Native Client (NaCI). Originally announced last year, Native Client allows C and C++ code to be seamlessly executed inside the browser with security restrictions similar to JavaScript. "Native Client apps use Pepper, a set of interfaces that provide C and C++ bindings to the capabilities of HTML5," he said. "As a result, developers can now leverage their native code libraries and expertise to deliver portable, high performance web apps."

Also new to Chrome Beta is the Web Audio API, a new JavaScript API that offers advanced audio capabilities and effects like room simulation and spatialization. Rogers added that this new API will allow web developers to create even more interactive experiences and games, and even provided a few examples for experimentation.

This latest Chrome Beta build also reportedly embraces optimizations for OS X Lion like proper Lion scrollbars and support for fullscreen mode. Mac users also finally received Print Preview, a feature which originally appeared for Windows and Linux clients back in version 13. Previously Google implemented a new Javascript rendering engine into Chrome 14's developmental cycle while also increasing security on secure (HTTPS) web pages.

Thursday Google also made changes on the Chrome 15 Dev front as well with the release of v15.0.849.0. Just on the visuals alone, the initial presentation has changed once a New Tab is opened, moving each section (Most Visited, Apps, Bookmarks etc) to their own sliding "window" without creating a new tab. App icons and website preview icons are now much larger, presenting the feeling of a mobile OS overall rather than a mere web browser. If anything, the new "interface" begs for touch-based input.

The new release also overhauls the Print Preview panel for improved speed and usability, and also features additional enhancements when using the browser on OS X Lion. But mainly this release is focused on stability and performance.

Ask a Category Expert

Create a new thread in the Streaming Video & TVs forum about this subject

Example: Notebook, Android, SSD hard drive

This thread is closed for comments
  • 1 Hide
    thisisaname , August 12, 2011 11:23 PM
    Once they have Native Client (NaCI) running nicely whats the bet they roll it into Andriod and kill off Java support?
  • -1 Hide
    Anonymous , August 12, 2011 11:41 PM
    Oh gawd, now they can look forward to memory leaks, BSODs and virii... These things should really be done in either a managed language like Vala, or something like Perl or Python.
  • 0 Hide
    Anonymous , August 13, 2011 12:01 AM
    I think Google's marketing plan is to have their own OS and browser tied to their eco system. Very similar to Apple's vision back in the 90's. However, even Apple finally decided you can't compete unless you make steps towards opponent. When Apple trashed the Power PC chip and adopted Intel chips. It brought so many opportunities for Apple. The ability to have a Mac and run Windows was one of the biggies. Google however is choosing a more closed system then Apple had.
  • Display all 28 comments.
  • 5 Hide
    Kamab , August 13, 2011 1:44 AM
    @jescott, I really doubt that. Google's goal always has been to have their web apps and software be available on all platforms. They don't make money off of "locking you" into their closed system the way that apple does. They make money through advertising, which means support for Java apps is probably not going away any time soon.

    So much so is this true that they spent millions showing smartphone developers how to make a good android smartphone to improve competition in the market (and to encourage development of android phones).

    I'm curious what you are basing your assumptions off of.
  • 6 Hide
    wifiwolf , August 13, 2011 3:04 AM
    The first thing that came to my mind was that Google is getting really serious about making Chrome an OS in the browser.
  • 5 Hide
    cheepstuff , August 13, 2011 3:28 AM
    Considering that this is Chrome, Google is probably looking for a logical way to introduce optimizations into their browser by allowing developers to write in an unmanaged language. This seems like a step backwards in some ways because a managed language more simple syntactically, naturally allows for less bugs (particularly in the dreaded memory realm) and is all around far easier to write than the lower level counterpart. One glaring problem with browser apps, however, is it can never compete with an application in performance. An app created for a browser has an associated overhead because it, by being a script parsed by an application, is necessarily several more steps removed from the processor than a program compiled to native calls in the first place. This feature would erode the performance disadvantage that browser developers occasionally have to struggle with. Naturally, it makes sense that Google would have an interest in introducing a way to have high-performance applications on a browser because, if it works, this would be a feature foundational to Chrome OS, their browser-based operating system.

    As far as this taking over conventional browser development, like javascript, there is no chance of that. This would only be a useful tool for a developer trying to get more performance than the traditional script can offer. In any other case, it would not be worth the effort.

    The thing I don't understand however, is unless these programs are wrapped in some sort of local API or library suite, aren't they just introducing a huge target for virus exploit?
  • 1 Hide
    Anonymous , August 13, 2011 4:08 AM
    NaCl a.k.a Salt. Thus, you get Salt & Pepper. Get it?
  • 0 Hide
    ojas , August 13, 2011 5:35 AM
    Been wondering the same as others have, viruses may be an issue this way...i'm even scared of the potential bugs, one unnoticed bug makes it's way through and we'd be stuck in an infinite loop! :D 
  • -6 Hide
    martel80 , August 13, 2011 6:46 AM
    viriiiOh gawd, now they can look forward to memory leaks, BSODs and virii... These things should really be done in either a managed language like Vala, or something like Perl or Python.

    Garbage collection is necessary only for garbage programmers.
    Additionally, C++ has auto pointers.
  • 0 Hide
    Anonymous , August 13, 2011 1:34 PM
    imo, this will be a decision that makes a turn in OS history. especially mobile's one
    Google is threatening Apple and Microsoft with the same stone.
    imagine all those C++ applications working in a browser online, with the coming of cloud; im sure its gonna be a winner.
    good strategy ras Al'Google.
  • 3 Hide
    razor512 , August 13, 2011 2:30 PM
    does that mean we can write malware and have it simply run in the browser instead of having to make something that has to exploit the browser and do privilege escalation on the OS.

    If you are ok with c++ but not java script, you can write something that will cause the browser to bruteforce the login of the users router and change the DNS servers to something malicious, especially if it allows more functionality than java script.
  • 0 Hide
    andersx , August 13, 2011 3:24 PM
    So you have the dynamically linked libraries on your computer, and then Chrome apps are allowed to interface?
  • 0 Hide
    annymmo , August 13, 2011 3:45 PM
    Wouldn't NaCl be better used to compile javascript to C++ and then executable code?
    This way it works immediately for everything.
  • 0 Hide
    mjpereira76 , August 13, 2011 4:49 PM
    martel80Garbage collection is necessary only for garbage programmers.Additionally, C++ has auto pointers.

    Pure ignorance. You are either an old school programmer whose skills are no longer needed and stuck in the past or you just don't know much about anything programming related.
  • 0 Hide
    stuart72 , August 13, 2011 6:04 PM
    What exactly is the difference between this and an activeX control written in c/c++?
  • 2 Hide
    calinkula , August 13, 2011 7:22 PM
    martel80Garbage collection is necessary only for garbage programmers.Additionally, C++ has auto pointers.

    AHHH HA HA HA HA HA...... You're killing me..... AAAAHHHH HA HA HA HA HA HA HA HA HA HA HA ha ha ha ha ha ha ha ha..... with laughter... AAHHH HA HA HA HA HA HA HA ha ha ha ha ha........ can't breathe......
  • 1 Hide
    Anonymous , August 13, 2011 8:59 PM
    cnoo13/jorerr, can I come to your house and club you over the head with a golf club and then take a 20-lb sledge to all of your electronics equipment?
  • 4 Hide
    husker , August 13, 2011 11:23 PM
    kitchen_tableNaCl a.k.a Salt. Thus, you get Salt & Pepper. Get it?

    That was my first thought. I was really surprised that someone could write this article and not use that fact to demonstrate their writing skill and wit. I mean, it was handed to them on a Ag platter!
  • 0 Hide
    doorspawn , August 14, 2011 8:53 AM
    From the article, NaCl is sandboxed. I can't be bothered looking up how.
    But, just like virtualization, it is possible to redirect system calls from directly-executed machine code, including those that manage memory. In this way you can prevent excess memory use and stop virii. Since the C++ code will be running in a separate thread or process, lockups won't lock up chrome.

    Also, garbage collection is for programmers that are happy to accept performance hits (that only matter in large programs) in exchange for an easier-to-understand and somewhat safer model that is also slightly more succinct, (although arguably less elegant) than C++'s RAII templates.
    I prefer not to use GC, but I have no issue with GC users who don't have issue with non-GC users.
  • 2 Hide
    MrBig55 , August 14, 2011 10:49 AM
    My guess is that Half-Life2/Counter-strike source would run on chrome with little modifications, and viruses and trojans too! ^-^ Oh and in theory we could run windows in chrome with that in mind isn't fantastic? :-D
Display more comments
Tom’s guide in the world
  • Germany
  • France
  • Italy
  • Ireland
  • UK
Follow Tom’s guide
Subscribe to our newsletter
  • add to twitter
  • add to facebook
  • ajouter un flux RSS