mirror of
https://github.com/ddidderr/wuffs.git
synced 2026-11-25 08:55:11 +01:00
Remove wbmp seen_etc fields
This commit is contained in:
1 parent
0d0a74c9a8
commit
149204c14e
2 files changed
+4
-18
No files matched your search
@@ -4237,8 +4237,6 @@ struct wuffs_wbmp__decoder__struct {
|
|||||||
uint32_t f_width;
|
uint32_t f_width;
|
||||||
uint32_t f_height;
|
uint32_t f_height;
|
||||||
uint8_t f_call_sequence;
|
uint8_t f_call_sequence;
|
||||||
bool f_seen_frame;
|
|
||||||
bool f_seen_frame_config;
|
|
||||||
uint64_t f_frame_config_io_position;
|
uint64_t f_frame_config_io_position;
|
||||||
wuffs_base__pixel_swizzler f_swizzler;
|
wuffs_base__pixel_swizzler f_swizzler;
|
||||||
|
|
||||||
@@ -13317,7 +13315,6 @@ wuffs_wbmp__decoder__decode_frame_config(wuffs_wbmp__decoder* self,
|
|||||||
self->private_impl.f_frame_config_io_position, 0, true, false,
|
self->private_impl.f_frame_config_io_position, 0, true, false,
|
||||||
4278190080);
|
4278190080);
|
||||||
}
|
}
|
||||||
self->private_impl.f_seen_frame_config = true;
|
|
||||||
self->private_impl.f_call_sequence = 2;
|
self->private_impl.f_call_sequence = 2;
|
||||||
|
|
||||||
goto ok;
|
goto ok;
|
||||||
@@ -13471,7 +13468,6 @@ wuffs_wbmp__decoder__decode_frame(wuffs_wbmp__decoder* self,
|
|||||||
v_dst_y += 1;
|
v_dst_y += 1;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
self->private_impl.f_seen_frame = true;
|
|
||||||
self->private_impl.f_call_sequence = 3;
|
self->private_impl.f_call_sequence = 3;
|
||||||
|
|
||||||
goto ok;
|
goto ok;
|
||||||
@@ -13544,7 +13540,6 @@ wuffs_wbmp__decoder__skip_frame(wuffs_wbmp__decoder* self,
|
|||||||
goto suspend;
|
goto suspend;
|
||||||
}
|
}
|
||||||
iop_a_src += self->private_data.s_skip_frame[0].scratch;
|
iop_a_src += self->private_data.s_skip_frame[0].scratch;
|
||||||
self->private_impl.f_seen_frame = true;
|
|
||||||
self->private_impl.f_call_sequence = 3;
|
self->private_impl.f_call_sequence = 3;
|
||||||
|
|
||||||
goto ok;
|
goto ok;
|
||||||
@@ -13680,7 +13675,7 @@ wuffs_wbmp__decoder__num_decoded_frame_configs(
|
|||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (self->private_impl.f_seen_frame_config) {
|
if (self->private_impl.f_call_sequence > 1) {
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
return 0;
|
return 0;
|
||||||
@@ -13698,7 +13693,7 @@ wuffs_wbmp__decoder__num_decoded_frames(const wuffs_wbmp__decoder* self) {
|
|||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (self->private_impl.f_seen_frame) {
|
if (self->private_impl.f_call_sequence > 2) {
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
return 0;
|
return 0;
|
||||||
@@ -13727,8 +13722,6 @@ wuffs_wbmp__decoder__restart_frame(wuffs_wbmp__decoder* self,
|
|||||||
return wuffs_base__make_status(wuffs_base__error__bad_argument);
|
return wuffs_base__make_status(wuffs_base__error__bad_argument);
|
||||||
}
|
}
|
||||||
self->private_impl.f_call_sequence = 1;
|
self->private_impl.f_call_sequence = 1;
|
||||||
self->private_impl.f_seen_frame = false;
|
|
||||||
self->private_impl.f_seen_frame_config = false;
|
|
||||||
self->private_impl.f_frame_config_io_position = a_io_position;
|
self->private_impl.f_frame_config_io_position = a_io_position;
|
||||||
return wuffs_base__make_status(NULL);
|
return wuffs_base__make_status(NULL);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -22,8 +22,6 @@ pub struct decoder? implements base.image_decoder(
|
|||||||
|
|
||||||
call_sequence : base.u8,
|
call_sequence : base.u8,
|
||||||
|
|
||||||
seen_frame : base.bool,
|
|
||||||
seen_frame_config : base.bool,
|
|
||||||
frame_config_io_position : base.u64,
|
frame_config_io_position : base.u64,
|
||||||
|
|
||||||
swizzler : base.pixel_swizzler,
|
swizzler : base.pixel_swizzler,
|
||||||
@@ -122,7 +120,6 @@ pub func decoder.decode_frame_config?(dst: nptr base.frame_config, src: base.io_
|
|||||||
background_color: 0xFF000000)
|
background_color: 0xFF000000)
|
||||||
}
|
}
|
||||||
|
|
||||||
this.seen_frame_config = true
|
|
||||||
this.call_sequence = 2
|
this.call_sequence = 2
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -196,7 +193,6 @@ pub func decoder.decode_frame?(dst: ptr base.pixel_buffer, src: base.io_reader,
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
this.seen_frame = true
|
|
||||||
this.call_sequence = 3
|
this.call_sequence = 3
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -209,7 +205,6 @@ pri func decoder.skip_frame?(src: base.io_reader) {
|
|||||||
|
|
||||||
args.src.skip?(n: total_bytes)
|
args.src.skip?(n: total_bytes)
|
||||||
|
|
||||||
this.seen_frame = true
|
|
||||||
this.call_sequence = 3
|
this.call_sequence = 3
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -240,14 +235,14 @@ pub func decoder.num_animation_loops() base.u32 {
|
|||||||
}
|
}
|
||||||
|
|
||||||
pub func decoder.num_decoded_frame_configs() base.u64 {
|
pub func decoder.num_decoded_frame_configs() base.u64 {
|
||||||
if this.seen_frame_config {
|
if this.call_sequence > 1 {
|
||||||
return 1
|
return 1
|
||||||
}
|
}
|
||||||
return 0
|
return 0
|
||||||
}
|
}
|
||||||
|
|
||||||
pub func decoder.num_decoded_frames() base.u64 {
|
pub func decoder.num_decoded_frames() base.u64 {
|
||||||
if this.seen_frame {
|
if this.call_sequence > 2 {
|
||||||
return 1
|
return 1
|
||||||
}
|
}
|
||||||
return 0
|
return 0
|
||||||
@@ -261,8 +256,6 @@ pub func decoder.restart_frame!(index: base.u64, io_position: base.u64) base.sta
|
|||||||
return base."#bad argument"
|
return base."#bad argument"
|
||||||
}
|
}
|
||||||
this.call_sequence = 1
|
this.call_sequence = 1
|
||||||
this.seen_frame = false
|
|
||||||
this.seen_frame_config = false
|
|
||||||
this.frame_config_io_position = args.io_position
|
this.frame_config_io_position = args.io_position
|
||||||
return ok
|
return ok
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in new issue
Block a user