Lines Matching defs:yop
58 YopDecContext *yop = s->priv_data;
91 yop->frame_size = avio_r8(pb) * 2048;
101 yop->palette_size = video_dec->extradata[0] * 3 + 4;
102 yop->audio_block_length = AV_RL16(video_dec->extradata + 6);
104 video_dec->bit_rate = 8 * (yop->frame_size - yop->audio_block_length) * frame_rate;
107 if (yop->audio_block_length < 920 ||
108 yop->audio_block_length + yop->palette_size >= yop->frame_size) {
122 YopDecContext *yop = s->priv_data;
126 int actual_video_data_size = yop->frame_size -
127 yop->audio_block_length - yop->palette_size;
129 yop->video_packet.stream_index = 1;
131 if (yop->video_packet.data) {
132 *pkt = yop->video_packet;
133 yop->video_packet.data = NULL;
134 yop->video_packet.buf = NULL;
137 yop->video_packet.destruct = NULL;
140 yop->video_packet.size = 0;
141 pkt->data[0] = yop->odd_frame;
143 yop->odd_frame ^= 1;
146 ret = av_new_packet(&yop->video_packet,
147 yop->frame_size - yop->audio_block_length);
151 yop->video_packet.pos = avio_tell(pb);
153 ret = avio_read(pb, yop->video_packet.data, yop->palette_size);
156 }else if (ret < yop->palette_size) {
166 pkt->pos = yop->video_packet.pos;
168 avio_skip(pb, yop->audio_block_length - ret);
170 ret = avio_read(pb, yop->video_packet.data + yop->palette_size,
175 av_shrink_packet(&yop->video_packet, yop->palette_size + ret);
178 return yop->audio_block_length;
181 av_free_packet(&yop->video_packet);
187 YopDecContext *yop = s->priv_data;
188 av_free_packet(&yop->video_packet);
195 YopDecContext *yop = s->priv_data;
203 pos_max = avio_size(s->pb) - yop->frame_size;
204 frame_count = (pos_max - pos_min) / yop->frame_size;
208 frame_pos = timestamp * yop->frame_size + pos_min;
213 av_free_packet(&yop->video_packet);
214 yop->odd_frame = timestamp & 1;
220 .name = "yop",
228 .extensions = "yop",