It seems to me that we have arrived at the conclusion that a good drawing API 
should be mostly stateless (like Moz2D), instead of Cairo's stateful API. As a 
result we are currently removing all uses of the Cairo API and we will 
eventually remove Cairo from our codebase altogether (in favor of D2D via Moz2D 
on Windows and Skia via Moz2D elsewhere).

The C++ CS is free to standardize whatever they like, but if they ask for our 
opinion we probably want to point them at Moz2D instead of Cairo.

That having said, for maximum performance there is a fair amount of detailed 
knowledge callers need to have about the innards of Moz2D backends. You 
sometimes want to explicitly wrap a draw target around a texture and then use 
that texture in the compositor, etc. So I am not sure you can have a nice, 
non-leaky abstraction for 2D graphics in the language.

My best guess is that whatever they standardize will end up not being useful 
for high-performance applications. In that case, I wonder why bother. A library 
really might do just fine here.

Just my 2c. roc or Bas might have a more detailed opinion here.

Andreas

On Feb 9, 2014, at 11:29 AM, Botond Ballo <bba...@mozilla.com> wrote:

> The C++ Standards Committee is aiming to standardize a 2D 
> drawing API in the post-C++14 timeframe. A study group 
> (SG 13 - Graphics [1]) has been created to investigate 
> possible approaches.
> 
> SG 13 is considering using Cairo as the basis for a 
> lightweight C++ drawing API [2] [3]. The idea would be to
> automatically wrap Cairo's C API into a C++ API without
> changing the semantics of the operations (see the last
> two pages of [2] for details).
> 
> This sounds like the sort of thing we might be interested
> in / have an opinion on.
> 
> Any thoughts?
> 
> SG 13 will be meeting in Issaquah next week as part of the
> larger C++ Standards Committee meeting, which I will be
> attending. If anyone has thoughts on this proposal, I am
> happy to convey them at the study group's meeting.
> 
> Thanks,
> Botond
> 
> 
> [1] http://isocpp.org/std/the-committee
> [2] http://isocpp.org/files/papers/N3825.pdf
> [3] http://lists.cairographics.org/archives/cairo/2013-December/024858.html
> _______________________________________________
> dev-platform mailing list
> dev-platform@lists.mozilla.org
> https://lists.mozilla.org/listinfo/dev-platform

_______________________________________________
dev-platform mailing list
dev-platform@lists.mozilla.org
https://lists.mozilla.org/listinfo/dev-platform

Reply via email to