Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:101055 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 59759 invoked from network); 4 Nov 2017 21:39:30 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 4 Nov 2017 21:39:30 -0000 Authentication-Results: pb1.pair.com smtp.mail=cmbecker69@gmx.de; spf=pass; sender-id=pass Authentication-Results: pb1.pair.com header.from=cmbecker69@gmx.de; sender-id=pass Received-SPF: pass (pb1.pair.com: domain gmx.de designates 212.227.15.19 as permitted sender) X-PHP-List-Original-Sender: cmbecker69@gmx.de X-Host-Fingerprint: 212.227.15.19 mout.gmx.net Received: from [212.227.15.19] ([212.227.15.19:56086] helo=mout.gmx.net) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id FC/02-09857-F833EF95 for ; Sat, 04 Nov 2017 16:39:28 -0500 Received: from [192.168.2.106] ([79.243.124.218]) by mail.gmx.com (mrgmx002 [212.227.17.190]) with ESMTPSA (Nemesis) id 0MBWo2-1e0cJR1wLm-00ASdT; Sat, 04 Nov 2017 22:39:23 +0100 To: Rowan Collins , internals@lists.php.net, Andreas Treichel References: <25D0259A-3857-4188-8626-DE9447859F9C@gmail.com> Message-ID: Date: Sat, 4 Nov 2017 22:39:26 +0100 User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:52.0) Gecko/20100101 Thunderbird/52.4.0 MIME-Version: 1.0 In-Reply-To: <25D0259A-3857-4188-8626-DE9447859F9C@gmail.com> Content-Type: text/plain; charset=utf-8 Content-Language: de-DE Content-Transfer-Encoding: 7bit X-Provags-ID: V03:K0:WBOBfxaBUoEZGw4HpcBCl+NWnwgnJ1jD+hZG4szhupcSDKfmeem YppamHhNrUIWm8UEswgboCva/ExRRLK18hR6yUf3kNH+GtO0CgTODoDw2dfFex1nhR938bt xhvgURAR3RIvAstzQTbXU4zTbEiw9+HkmORsafiowpN9T9EhrrTp7bIKX0Os2abfN83+0ZF g1DtfY57YPJlbUD2ncrcw== X-UI-Out-Filterresults: notjunk:1;V01:K0:rQTwjD0vJbQ=:LNz4xFihicM3Xs0GLs7px2 lZNE5UMXpmtYrAs0hv/Ru3wEF6AqKZza9ZKr8cDjkXFcNdVO1WmIoFo8GlMPY0WAHZEntiJC4 8AU+d6q4YxMIZn8EdjT27H3PZCmKVb0PGSg0IhMVblotBm79FWsCpfmh4SBEf2tm0II2CKpyH 2dxFUMQTkDPRgMCyTUaUoD7o8gcIh/pSt7YyBvPSvbACg/1/Qv3Pd8vdheMJO9D++gxKzKu+a UdvQeO/o/wXnVRoqh9iw/nt0fZZgLLKNtL24NCbPlf5bCPfXH7TtsOcj8IqvZhPlW0uG1l3NU ZHCOZp121xV9cU63QugqWyc9Bm4WbE1mwuBNmZJ8yEFp9UI0oIx5ABNt/9BVPrncWVbNgc8Kg 1h9Xn3oTQVIUJ6dsigKOf81o5yDwZAwq/xS+NGXa8g5hyUbuc0km2c7k060hnijjTmV3ko5WU nCTzLQ9KmIpMzL4p/wa7VE81bv5FXy19i/onrnzT5V7tanodFh/vr0yW6ATCeOdieNV+Jvspd wQNsB8aVTzO8oFxOvJILAwA+X9rWDTy7AQko+s5h8kMjZCUGr9s+KctusYEBnaBcKNHvQLUz/ srwL0FHrAfOljQq+owHm4jaVbDjCfoqYbcwaNEpJ6okmHWQMBCQisAnMD9wWmc09NqHegzqIq Sa7zo96lqfcL43ZL1jyoRd6ZoVpAao3MdOMD9mMWJ+S7a2H23DAdmUHFjvuF0Ht+ANPOOd+zd bNHmodZKX5RfM1CaJkal9hTI//aRcF4EkJhFxCAEmdmQAZcGA7QCvf9kJuDube5epebAUlIPt z9z5qU1Nr3NLmp9H2TiJ92bk16LE9g5SDaeEa5g7vRPsylJscc= Subject: Re: [PHP-DEV] Proposal: Rename image functions From: cmbecker69@gmx.de ("Christoph M. Becker") On 04.11.2017 at 18:39, Rowan Collins wrote: > On 4 November 2017 16:40:56 GMT+00:00, Andreas Treichel wrote: > >> The only >> exception is image2wbmp which is renamed to image_to_wbmp. > > What is the difference between imagewbmp and image2wbmp? If we're going to rename things, shouldn't that difference be made clearer? Or should we be looking to deprecate one of them anyway? WBMP images are monochrome (at least in practice). Theoretically, image2wbmp() allows to set a threshold (light pixels will become foreground, dark pixels will become background), but imagewbmp() allows only to chose a foreground color (all other pixels will become background). However, this somewhat useful distinction has been removed as of PHP 5.0.0, see . Re-introducing the supposed functionality of image2wbmp() doesn't appear to be sensible after that long time, so I'm +1 on deprecating the function. Instead we might consider to add a general function to convert an image to monochrome according to a given brightness threshold. And frankly, I have doubts that WBMP is of any real value nowadays, so we might consider to deprecate both functions (imagecreatefromwbmp() might still be useful to convert old WBMP images to a more contemporary format). -- Christoph M. Becker