Welcome to Scribd, the world's digital library. Read, publish, and share books and documents. See more
Download
Standard view
Full view
of .
Look up keyword
Like this
5Activity
0 of .
Results for:
No results containing your search query
P. 1
Useful C Libraries

Useful C Libraries

Ratings: (0)|Views: 1,054|Likes:
C Code Library
C Code Library

More info:

Published by: Balaji.S (ACA) Srirangam on Mar 15, 2010
Copyright:Attribution Non-commercial

Availability:

Read on Scribd mobile: iPhone, iPad and Android.
download as DOC, PDF, TXT or read online from Scribd
See more
See less

10/18/2011

pdf

text

original

 
Useful C Libraries
 This is a collection of libraries for use in C programming.
A library of Bit Twiddling HacksA page of optimized code snippets for manipulating  bitsrapidly, collected and documented by Sean Eron Anderson. Most of the code is in the public domain, except where noted.Augmented Reality ARToolkitARToolKit is a software library for building Augmented Reality (AR) applications that overlayvirtual imagery on the real world.Libmspack - GNU Library for reading Microsoft compressed FilesThe purpose of libmspack is to provide both compression and decompression of some looselyrelated file formats used by Microsoft.Libtpl - a Serializing LibraryThe tpl library provides a way to store and reload your C data quickly and easily. It works withfiles, memory buffers and file descriptors so it can be used as a file format, IPC message formator anywhere you need to store and retrieve your data.LibUnwind - View the Stack ContentsThis is a portable C API to determine the call-chain of a program. The API also provides themeans to manipulate the saved state of each call-frame and to resume execution at any point inthe call-chain (non-local goto). The API supports both local (same-process) and remote (across- process) operation.Protobuf-c - Using Google's Protobuf in CProtcol Buffers are a way of encoding structured data in an efficient yet extensible format.Google uses Protocol Buffers for almost all of its internal RPC protocols and file formats.However They are for C++ and other languages. Protobuf-c lets yo use them in C.
==========================================================
Bit Twiddling Hacks
By Sean Eron Andersonseander@cs.stanford.edu
Individually, the
code snippets here are in the public domain
(unless otherwise noted)— feel free to use them however you please. The aggregate collection and descriptions are© 1997-2005 Sean Eron Anderson. The code and descriptions are distributed in the hopethat they will be useful, but
WITHOUT ANY WARRANTY 
and without even the impliedwarranty of merchantability or fitness for a particular purpose. As of May 5, 2005, all thecode has been tested thoroughly. Thousands of people have read it. Moreover,ProfessorRandal Bryant, the Dean of Computer Science at Carnegie Mellon University, has personallytested almost everything with hisUclid code verification system. What he hasn't tested, I
 
have checked against all possible inputs on a 32-bit machine.
To the first person toinform me of a legitimate bug in the code, I'll pay a bounty of US$10 (by check orPaypal)
. If directed to a charity, I'll pay US$20.
Contents
Sign extending
o
o
o
Counting bits set
o
o
o
o
o
o
o
Computing parity (1 if an odd number of bits set, 0 otherwise)
o
o
o
o
o
Swapping Values
o
o
o
Reversing bit sequences
o
o
o
o
o
o
Modulus division (aka computing
remainders
)
 
o
o
o
Finding integer log base 2 of an integer (aka the position of the highest bitset)
o
o
o
o
o
Counting consecutive trailing zero bits (or finding bit indices)
o
o
o
o
o
o
Interleaving bits (aka computing
Morton Numbers
)
o
o
o
o
 Testing for ranges of bytes in a word (and counting occurances found)
o
o
o
o
o
About the operation counting methodology
When totaling the number of operations for algorithms here, any C operator iscounted as one operation. Intermediate assignments, which need not be written to

Activity (5)

You've already reviewed this. Edit your review.
1 thousand reads
1 hundred reads
Aravind Putrevu liked this
sprj_svn liked this
coolmadhus liked this

You're Reading a Free Preview

Download
scribd
/*********** DO NOT ALTER ANYTHING BELOW THIS LINE ! ************/ var s_code=s.t();if(s_code)document.write(s_code)//-->