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
deblock_horiz.c
Package: VC++视频传输.rar [view]
Upload User: hxb_1234
Upload Date: 2010-03-30
Package Size: 8328k
Code Size: 2k
Category:
Visual C++ Books
Development Platform:
Visual C++
- #include "postprocess_mmx.h"
- #ifdef PP_COMPONENTS_INLINE
- #ifndef INLINE
- #define INLINE static __inline
- #endif
- #include "deblock_horiz_DC_on.c"
- #include "deblock_horiz_useDC.c"
- #include "deblock_horiz_default_filter.c"
- #include "deblock_horiz_lpf9.c"
- #endif
- void deblock_horiz(uint8_t *image, int width, int stride, QP_STORE_T *QP_store, int QP_stride, int chromaFlag) {
- int x, y;
- int QP;
- uint8_t *v;
- int useDC, DC_on;
- #ifdef PREFETCH_AHEAD_H
- void *prefetch_addr;
- #endif
- y = 0;
- for (x=8; x<width; x+=8) {
- QP = chromaFlag ? QP_store[y/8*QP_stride+x/8]
- : QP_store[y/16*QP_stride+x/16];
- v = &(image[y*stride + x]) - 5;
- #ifdef PREFETCH_AHEAD_V
- prefetch_addr = v + PREFETCH_AHEAD_V;
- __asm {
- push eax
- push ebx
- mov eax, prefetch_addr
- mov ebx, stride
- add eax , ebx
- prefetcht0 [eax]
- add eax , ebx
- prefetcht0 [eax]
- add eax , ebx
- prefetcht0 [eax]
- add eax , ebx
- prefetcht0 [eax]
- pop ebx
- pop eax
- };
- #endif
- useDC = deblock_horiz_useDC(v, stride);
- if (useDC) {
- DC_on = deblock_horiz_DC_on(v, stride, QP);
- if (DC_on) {
- deblock_horiz_lpf9(v, stride, QP);
- #ifdef SHOWDECISIONS_H
- if (!chromaFlag) {
- v[0*stride + 4] =
- v[1*stride + 4] =
- v[2*stride + 4] =
- v[3*stride + 4] = 255;
- }
- #endif
- }
- } else {
- deblock_horiz_default_filter(v, stride, QP);
- #ifdef SHOWDECISIONS_H
- if (!chromaFlag) {
- v[0*stride + 4] =
- v[1*stride + 4] =
- v[2*stride + 4] =
- v[3*stride + 4] = 0;
- }
- #endif
- }
- }
- __asm {
- emms
- };
- }