[FFmpeg-devel] [PATCH] OpenEXR decoder rev-16

Jimmy Christensen jimmy
Tue Sep 8 15:30:26 CEST 2009


On 2009-09-08 13:42, Diego Biurrun wrote:
> On Tue, Sep 08, 2009 at 01:36:42PM +0200, Jimmy Christensen wrote:
>>
>> Thanks for the review.
>
> You are welcome.
>
>> Guess too much vacation makes you forget the
>> basic stuff :)
>
> :)
>
>> --- Changelog	(revision 19793)
>> +++ Changelog	(working copy)
>> @@ -37,9 +37,9 @@
>>   - Bluray (PGS) subtitle decoder
>>   - LPCM support in MPEG-TS (HDMV RID as found on Blu-ray disks)
>>   - Wmapro decoder
>> +- OpenEXR image decoder
>>
>>
>> -
>>   version 0.5:
>
> Please keep the empty line in place.
>

Fixed.

>> --- libavcodec/exr.c	(revision 0)
>> +++ libavcodec/exr.c	(revision 0)
>> @@ -0,0 +1,464 @@
>> +
>> +typedef struct EXRContext {
>> +    AVFrame picture;
>> +    int compr;
>> +
>> +    int   red_channel;
>> +    int green_channel;
>> +    int  blue_channel;
>> +    int bits_per_color_id;
>> +
>> +    int     red_channel_offset;
>> +    int   green_channel_offset;
>> +    int    blue_channel_offset;
>> +
>> +} EXRContext;
>
> nit: pointless empty line
>

Removed the empty lines and re-arranged a bit.

>> +    if (buf_end - buf>= minimum_length&&  !strncmp(buf, value_name, strlen(value_name))) {
>> +
>> +    if (channel_iter == s->red_channel || channel_iter == s->green_channel || channel_iter == s->blue_channel) {
>> +
>> +                    if (get_rgb_channel(&buf, channel_list_end, s, channel_iter,&current_channel_offset) == -1) {
>
> These lines for example could easily be broken, there are more.
>

Should have gotten them all now.

>> +    switch (s->bits_per_color_id) {
>> +        // 32-bit
>> +        case 2:
>
> Indent switch and case at the same depth.
>


Done

-------------- next part --------------
A non-text attachment was scrubbed...
Name: OpenEXR-rev16.diff
Type: text/x-patch
Size: 19647 bytes
Desc: not available
URL: <http://lists.mplayerhq.hu/pipermail/ffmpeg-devel/attachments/20090908/56a11fc5/attachment.bin>



More information about the ffmpeg-devel mailing list