Re: Propagating AVIF support from libgd into PHP's bundled gd

From: Date: Sun, 06 Jun 2021 01:41:17 +0000
Subject: Re: Propagating AVIF support from libgd into PHP's bundled gd
References: 1 2  Groups: php.internals 
Request: Send a blank email to internals+get-114748@lists.php.net to get a copy of this message
Den søn. 6. jun. 2021 kl. 00.09 skrev Ayesh Karunaratne <ayesh@php.watch>: > > Hi Ben, > Thank you for opening this PR and the discussion. With the wide > availability of AVIF/AV1 support in browsers, I think this will fit > nicely. > > We have the Namespaces in Bundled Extensions RFC > (https://wiki.php.net/rfc/namespaces_in_bundled_extensions) passed, so > perhaps, the new functions are probably better in the Gd > namespace? > This would mean the new functions would be > \Gd\imagecreatefromavif > and \Gd\imageavif. They are inconsistent with the existing > functions > of course, but I thought to mention it because it's a recent proposal > and I don't think we added new functions after that RFC. Some examples > are recently renamed PHP classes in IMAP, Pgsql, LDAP, and FTP > extensions to follow this new proposal. I don't think it makes much sense to do that for a single function, because it makes the API cluttered, as why would I call \Gd\imagecreatefromavif when everything else is in the global namespace? That is a poor design, while I understand the intentions behind it is good. I think this needs to be well thoughtout in a topic on its own rather than off topicing it here, so I will leave it at that. Overall, +1 for adding this -- regards, Kalle Sommer Nielsen kalle@php.net

« previous php.internals (#114748) next »