Code/Resource
Windows Develop
Linux-Unix program
Internet-Socket-Network
Web Server
Browser Client
Ftp Server
Ftp Client
Browser Plugins
Proxy Server
Email Server
Email Client
WEB Mail
Firewall-Security
Telnet Server
Telnet Client
ICQ-IM-Chat
Search Engine
Sniffer Package capture
Remote Control
xml-soap-webservice
P2P
WEB(ASP,PHP,...)
TCP/IP Stack
SNMP
Grid Computing
SilverLight
DNS
Cluster Service
Network Security
Communication-Mobile
Game Program
Editor
Multimedia program
Graph program
Compiler program
Compress-Decompress algrithms
Crypt_Decrypt algrithms
Mathimatics-Numerical algorithms
MultiLanguage
Disk/Storage
Java Develop
assembly language
Applications
Other systems
Database system
Embeded-SCM Develop
FlashMX/Flex
source in ebook
Delphi VCL
OS Develop
MiddleWare
MPI
MacOS develop
LabView
ELanguage
Software/Tools
E-Books
Artical/Document
postprocess.c
Package: Visual C++视频音频开发实用工程案例精选.rar [view]
Upload User: tuheem
Upload Date: 2007-05-01
Package Size: 21889k
Code Size: 2k
Category:
Multimedia Develop
Development Platform:
Visual C++
- #include "postprocess_mmx.h"
- void postprocess(unsigned char * src[], int src_stride,
- unsigned char * dst[], int dst_stride,
- int horizontal_size, int vertical_size,
- QP_STORE_T *QP_store, int QP_stride,
- int mode) {
- uint8_t *puc_src;
- uint8_t *puc_dst;
- uint8_t *puc_flt;
- QP_STORE_T *QP_ptr;
- int y, i;
- for (y=0; y<vertical_size; y+= 4) {
- if (!(mode & PP_DONT_COPY)) {
- puc_src = &((src[0])[y*src_stride]);
- puc_dst = &((dst[0])[y*dst_stride]);
- fast_copy(puc_src, src_stride, puc_dst, dst_stride, horizontal_size, 4);
- }
- if (mode & PP_DEBLOCK_Y_H) {
- puc_flt = &((dst[0])[y*dst_stride]);
- QP_ptr = &(QP_store[(y>>4)*QP_stride]);
- deblock_horiz(puc_flt, horizontal_size, dst_stride, QP_ptr, QP_stride, 0);
- }
- if (mode & PP_DEBLOCK_Y_V) {
- if ( (y%8) && (y-4)>5 ) {
- puc_flt = &((dst[0])[(y-4)*dst_stride]);
- QP_ptr = &(QP_store[(y>>4)*QP_stride]);
- deblock_vert( puc_flt, horizontal_size, dst_stride, QP_ptr, QP_stride, 0);
- }
- }
- }
- horizontal_size >>= 1;
- vertical_size >>= 1;
- src_stride >>= 1;
- dst_stride >>= 1;
- for (i=1; i<=2; i++) {
- for (y=0; y<vertical_size; y+= 4) {
- if (!(mode & PP_DONT_COPY)) {
- puc_src = &((src[i])[y*src_stride]);
- puc_dst = &((dst[i])[y*dst_stride]);
- fast_copy(puc_src, src_stride, puc_dst, dst_stride, horizontal_size, 4);
- }
- if (mode & PP_DEBLOCK_C_H) {
- puc_flt = &((dst[i])[y*dst_stride]);
- QP_ptr = &(QP_store[(y>>3)*QP_stride]);
- deblock_horiz(puc_flt, horizontal_size, dst_stride, QP_ptr, QP_stride, 1);
- }
- if (mode & PP_DEBLOCK_C_V) {
- if ( (y%8) && (y-4)>5 ) {
- puc_flt = &((dst[i])[(y-4)*dst_stride]);
- QP_ptr = &(QP_store[(y>>4)*QP_stride]);
- deblock_vert( puc_flt, horizontal_size, dst_stride, QP_ptr, QP_stride, 1);
- }
- }
- }
- }
- do_emms();
- }