main441.m
上传用户:cxsjwj
上传日期:2022-08-09
资源大小:34k
文件大小:3k
- %main441
- I1=double(I1);
- JQ=forwardDCT(I1,array);
- bufferI1 = inverseDCT(JQ,array);
- c= makeLayers(JQ);
- %%calling decoder
- identifier=1;
- decoder(c,motionVect,identifier,flag);
- %%%this loop is for accessing frame from actual movie
- if i~=1
- j=i-round(i/10);
- [B2,B3,P4,B5,B6,P7,B8,B9,I10]=GOP1(j,resize,long,wide);
- elseif i==1
- j=i;
- [B2,B3,P4,B5,B6,P7,B8,B9,I10]=GOP1(j,resize,long,wide);
- end
- %processing on P4 frame
- [bufferP4,streamP4,motionVect]=compensatedFrame(P4,bufferI1,mbSize,p,array);
- c= makeLayers(streamP4);
- %calling decoder
- identifier=4;
- %decoder(diffDC,valVectorBase,lenVectorBase,valVectorEnhan,lenVectorEnhan,identifier,flag,motionVect);
- decoder(c,motionVect,identifier,flag);
- % % %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-
- %for B2
- [B2t ,motionVect, flag] = bFrameProc(B2,bufferI1,bufferP4,0.5*array,mbSize,p);
- c= makeLayers(B2t);
-
- %calling decoder
- identifier=2;
- decoder(c,motionVect,identifier,flag);
-
- %for B3
- [B3t ,motionVect ,flag] = bFrameProc(B3,bufferI1,bufferP4,0.5*array,mbSize,p);
- c= makeLayers(B3t);
-
- %calling decoder
- identifier=3;
- decoder(c,motionVect,identifier,flag);
-
- %predicting p7 from p4
- [bufferP7,streamP7,motionVect]=compensatedFrame(P7,bufferP4,mbSize,p,array);
- c= makeLayers(streamP7);
-
- %calling decoder
- identifier=7;
- decoder(c,motionVect,identifier,flag);
- %
- %for B5
- [B5t motionVect flag] = bFrameProc(B5,bufferP4,bufferP7,0.5*array,mbSize,p);
- c= makeLayers(B5t);
-
- %calling decoder
- identifier=5;
- decoder(c,motionVect,identifier,flag);
-
- %for B6
- [B6t motionVect flag] = bFrameProc(B6,bufferP4,bufferP7,0.5*array,mbSize,p);
- c= makeLayers(B6t);
-
- %calling decoder
- identifier=6;
- decoder(c,motionVect,identifier,flag);
-
- %processing on I10 frame
- streamI10=forwardDCT(I10,array);
- bufferI10 = inverseDCT(streamI10,array);
- c= makeLayers(streamI10);
- %%calling decoder
- identifier=10;
- decoder(c,motionVect,identifier,flag);
- %
- %for B8
- [B8t motionVect flag] = bFrameProc(B8,bufferP7,bufferI10,0.5*array,mbSize,p);
- c= makeLayers(B8t);
-
- %calling decoder
- identifier=8;
- decoder(c,motionVect,identifier,flag);
- %for B9
- [B9t motionVect flag] = bFrameProc(B9,bufferP7,bufferI10,0.5*array,mbSize,p);
- c= makeLayers(B9t);
-
- %calling decoder
- identifier=9;
- decoder(c,motionVect,identifier,flag);
-
-