[vlc-devel] HLS player
kcadieux at gmail.com
Sun May 19 09:30:25 CEST 2013
On Sat, May 18, 2013 at 4:24 PM, Rafaël Carré <funman at videolan.org> wrote:
> What's wrong with keeping it as C ?
> I'm genuinely curious, DASH plugin is in C++ but except from being slow
> to compile I have no idea how well it works and how maintainable it is.
I am more comfortable with C++ in general. Therefore, If I do write the HLS
version 4 and 5 support in C++ I think it might be best for consistency to
wrap the existing HLS code in classes so that it better integrates with my
Also, when a source file gets really long, I like to organize it into
multiple smaller files, each with a well defined sub-purpose. In C it's a
bit hard to work with multiple interrelated files because usually most
functions must be declared static to avoid having the names being
accessible from every other compilation unit. This also prevents functions
from other files from accessing them even if they are logically closely
related. In C++ this is less of a problem because although class methods
are linkable from every other compilation unit, they have their own scope
and you can also use namespaces.
This is really just a question of style preference and habit. I find it
easier to maintain C++ code but it doesn't mean this is true for everyone.
If everyone prefers the HLS code to be in C I'll be happy to oblige :)
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the vlc-devel