Googles appar
Huvudmeny

Post a Comment On: cbloom rants

"09-30-10 - Coder News"

7 Comments -

1 – 7 of 7
Blogger blq said...

Not quite on topic, and perhaps you've already heard about it but what do you think about the new Google image (compression) format, WebP?
http://googlecode.blogspot.com/2010/09/webp-new-image-format-for-web.html
...blogpost hint :)

September 30, 2010 at 1:53 PM

Blogger cbloom said...

I'd like some more information, but my first reaction is that they are exaggerating the benefits and it sort of sucks to be introducing yet another format which is not feature-rich or a big improvement.

The VP8 I-frame codec is something like 10 years old, and results that I've seen for it are not compelling vs. JPEG. (it's significantly worse than H264's I frames for example, and even that only barely beat JPEG in the working band of JPEG; if you try to push JPEG to sizes it isn't supposed to handle then H264 looks a lot better)

Also comparing size vs. baseline JPEG is rather unfair, you should compare vs. Stuffit repacked JPEG or something modern like that which uses the same JPEG DCT coefficients but puts a better entropy coder on the back end.

September 30, 2010 at 2:48 PM

Blogger won3d said...

More infos here:

http://code.google.com/speed/webp/docs/c_study.html

September 30, 2010 at 2:58 PM

Blogger cbloom said...

Wait what?

That looks like a classic example of using lots of statistics to make something look rigorous when it's completely not.

They're re-jpegging jpegs? Why are they using PSNR to study perceptual image formats? How about some actual modern coders in the study? How about doing some human visual tests if you're gonna be serious?

September 30, 2010 at 3:15 PM

Blogger Jeff Roberts said...

Dude, if you can't read the Rvalue References Explained paper without realizing that C++ is done, done, done, then you are crazy with a capital C. I mean:

"So as you can see, in order to really use rvalue references and move semantics in an optimal way, you need to fully understand and take into account today's compilers' "special effects" such as return value optimization and copy elision.... The details get pretty subtle."

and...

"C++0x, by contrast, introduces the following reference collapsing rules:

* A& & becomes A&
* A& && becomes A&
* A&& & becomes A&
* A&& && becomes A&&
"

or

"the argument of the factory function gets passed on to A's constructor through two levels of indirection, both by reference. Moreover, A's constructor sees as its argument an expression that is declared as an rvalue reference and does not have a name. By the no-name rule, such a thing is an rvalue. Therefore, A's constructor gets called on an rvalue. This means that the forwarding preserves any move semantics that would have taken place if the factory wrapper were not present.

Note that for the forwarding to preserve move semantics, it was necessary to explicitly specify Arg as the template argument of std::forward. Had we not done this, std::forward would have deduced its template argument to be X&, because its argument, having a name, is an lvalue. Therefore, the actual implementation of std::forward adds a little extra code whose only effect is to force clients to explicitly specify the template argument..."

They are done. They are all fired.

September 30, 2010 at 6:53 PM

Blogger frog said...

I've been using R-value references in VS2010 for awhile now(along with those other features you mentioned), and have found them very useful. Once you start using them they are fairly simple to understand.
The most useful new C++0x feature for me has been lambda, lets you write some very functional style code without all the verbosity of C++ 03.

October 1, 2010 at 12:23 PM

Blogger Tom Forsyth said...

I made it to page 4 of Becker's explanation just fine. Then this:

"std::move is a very simple function. Unfortunately, though, I cannot show you the implementation yet. We'll come back to it later."

I'm going to need a bigger boat.

October 4, 2010 at 10:13 PM

You can use some HTML tags, such as <b>, <i>, <a>

This blog does not allow anonymous comments.

Comment moderation has been enabled. All comments must be approved by the blog author.

You will be asked to sign in after submitting your comment.