MCPcopy Create free account
hub / github.com/FFmpeg/FFmpeg / output_subframes

Function output_subframes

libavcodec/flacenc.c:1123–1150  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1121}
1122
1123static void output_subframes(FlacEncodeContext *s)
1124{
1125 FlacFrame *frame;
1126 FlacSubframe *sub;
1127 int ch;
1128
1129 frame = &s->frame;
1130
1131 for(ch=0; ch<s->channels; ch++) {
1132 sub = &frame->subframes[ch];
1133
1134 /* subframe header */
1135 put_bits(&s->pb, 1, 0);
1136 put_bits(&s->pb, 6, sub->type_code);
1137 put_bits(&s->pb, 1, 0); /* no wasted bits */
1138
1139 /* subframe */
1140 if(sub->type == FLAC_SUBFRAME_CONSTANT) {
1141 output_subframe_constant(s, ch);
1142 } else if(sub->type == FLAC_SUBFRAME_VERBATIM) {
1143 output_subframe_verbatim(s, ch);
1144 } else if(sub->type == FLAC_SUBFRAME_FIXED) {
1145 output_subframe_fixed(s, ch);
1146 } else if(sub->type == FLAC_SUBFRAME_LPC) {
1147 output_subframe_lpc(s, ch);
1148 }
1149 }
1150}
1151
1152static void output_frame_footer(FlacEncodeContext *s)
1153{

Callers 1

flac_encode_frameFunction · 0.85

Calls 4

output_subframe_constantFunction · 0.85
output_subframe_verbatimFunction · 0.85
output_subframe_fixedFunction · 0.85
output_subframe_lpcFunction · 0.85

Tested by

no test coverage detected