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
transferIDCT.c
Package: Visual C++视频音频开发实用工程案例精选.rar [view]
Upload User: tuheem
Upload Date: 2007-05-01
Package Size: 21889k
Code Size: 1k
Category:
Multimedia Develop
Development Platform:
Visual C++
- #include "portab.h"
- void transferIDCT_add(int16_t *sourceS16, uint8_t *destU8, int stride) {
- int x, y;
- stride -= 8;
- for (y=0; y<8; y++) {
- for (x=0; x<8; x++) {
- #define SUM16 (*(destU8) + *(sourceS16))
- if (SUM16 > 255) *(destU8) = 255;
- else if (SUM16 < 0) *(destU8) = 0;
- else *(destU8) = SUM16;
- sourceS16++;
- destU8++;
- }
- destU8 += stride;
- }
- }
- void transferIDCT_copy(int16_t *sourceS16, uint8_t *destU8, int stride) {
- int x, y;
- stride -= 8;
- for (y=0; y<8; y++) {
- for (x=0; x<8; x++) {
- if (*(sourceS16) > 255) *(destU8) = 255;
- else if (*(sourceS16) < 0) *(destU8) = 0;
- else *(destU8) = (unsigned char) *(sourceS16);
- sourceS16++;
- destU8++;
- }
- destU8 += stride;
- }
- }