Thursday, December 17, 2009

Pirates of The World

http://apps.facebook.com/pirates_world/new.php?invite=Peter_APIIT

Thursday, October 1, 2009

Sunday, September 13, 2009

Thursday, August 27, 2009

FYP Project Title

1. Touchless VOIP System
2. Automatic Face Recognition Surveillance System
3. Body Visualization System

Monday, August 24, 2009

Body Visualization Software

Input from webcam and doing processing and display body image.

Saturday, August 22, 2009

CSI Software

Seeparate background voice with fro, foregournd voice

Content Recognition Software

Voice Recognition
Video Recognition

http://www.associatedcontent.com/article/1702413/pros_cons_on_using_voice_recognition.html

Wednesday, August 19, 2009

Interface Principle

Putting interface of a class in separate header file often increase flexibility and extensibility.

Sunday, August 16, 2009

Web Services

http://www.devx.com/cplus/Article/10188

Real Time System

People often need fast which cause fast also cause real time system.

real time email system
real time shared Broker system
real time server management system
-- server often down for any reasons
-- this system inspect why down(log them) and solve the problem by create virtual network node

real time plane traffic control system

Automatic Waste Recycling Monitoring System

Put a sensor in a tong and when full send sensors back to system and schedule for collecting.

Automatic Energy System

Virus Spread Map System

Eco System

Automatic Car Eye System

Automatic Humidity Control System

Automatic spray water

Automatic VOIP Surveillance Simulation System

When theft enter your house, automatic voip to Police.

Friday, August 14, 2009

Telecommunication Industry

Syniverse Technologies (Malaysia) Sdn Bhd

VOIP

[a href] http://www.codeguru.com/forum/showthread.php?t=482681 [/a href]

Tradisional Telephony Problem Compare to VOIP
1. Eavesdropping
2. Difficult in Maintenance
3. Costly
4. require point to point connection
5. Consume high bandwidth requirement
6. interfere with audio streams
7. DDOS
8. Spit = Spam Over VOIP
9. Phishing, snooping and spoofing.
10. Latency (delay)
11. Affect current network architecture
12. Under going rapid development not stable
13.





Solution :
1. VOIP with zrtp and codec compression

Function :
1. Encryption
2. Compression
3. Hide caller
4. Call History
5. Call Graph
6. Session border controller to protect private VOIP network
7. Voice VPN
8. Streaming Audio Recorder (Oreka)

VOIP Protocol
1. H.323
2. SIP
3. RTP
3. Secure RTP
4. ZRTP




http://www.testyourvoip.com/
http://voip.about.com/od/voipfeatures/a/featuresvoip.htm

Echo
= Sound reflection
Causes of echo
1. Noise level
2. Latency
http://www.solicall.com/

http://en.wikipedia.org/wiki/IP_PBX
http://www.linuxjournal.com/article/8424

VOIP network
Session Border Controller



* Google Search engine sip:18004664411@tf.voipmich.com +18004664411 Google 1-800-GOOG-411 Free 411 service - Speech recognition to search and connect business

* Intertex autoattendant sip:info@intertex.se

* Mouselike.org (UK) Echo and audio quality tests sip:904@mouselike.org or PSTN:+441483604781 - Allows test / connection from anywhere.

* Party Line sip:17475552663@proxy01.sipphone.com ( all-VoIP conference call every Saturday at 20:00 GMT )

* TELLME sip:18005558355@proxy01.sipphone.com (news, sports, weather)

* UCLA sip:13108254321@ucla.edu (no G.729)
* Xmission sip:xmission@pbx.xmission.com (no G.729)
* Prato City Hall, Italy - Echo test sip:05741837999@voip.comune.prato.it or iax:guest@voip.comune.prato.it/05741837999
* John Todd's screaming monkeys sip:1234@loligo.com
* http://www.telephreak.org sip:telephreak@voip.telephreak.org - The Telephreak's Free Voicemail/Conference system
* Echo test from Voxalot (USA) sip:*010600@ekiga.net Echo test from Voxalot (USA)
* Echo test from Voxalot (Europe) sip:*031600@ekiga.net
* Echo test from Voxalot (Australia) sip:*061600@ekiga.net
* Kansas State University Test Phone Number sip:*01317853950049@ekiga.net
* VoIP.Brujula.net's conference room (51112 creates a new room #12) sip:*201511@ekiga.net
* Wengo's echo test (France) sip:*248333@ekiga.net
* Blueface Monkey sounds (Ireland) sip:*266300@ekiga.net
* Blueface echo test (Ireland) sip:*266301@ekiga.net
* Blueface speaking clock (Ireland) sip:*266303@ekiga.net
* Blueface Music (Ireland) sip:*266305@ekiga.net
* Ixcall echo testsip: *318613@ekiga.net

http://www.iptel.org/sip/intro/purpose
http://www.sipdev.org/wiki/index.php/A_newcomer%27s_guide_to_SIP
http://www.ietf.org/rfc/rfc3261.txt


Video IVR
Weather Forecast Video IVR

Technology VS Algorithm/Design Patterns/OS/Threading/Concurrency

I like to learn the latter than the former. Once you dive in java, you need to learn a lot of technology like JSP, servlet, Beans, Hibernate and ...

Thursday, August 13, 2009

Huffman Coding

The idea of this algorithm is to construct a tree for every symbol where symbol that occurred more consume less bits. On the other hands, symbol that occurred least consumed more bits

Programming Philosophy

You know what you write and write what you know

80 - 20 Rule

Tuesday, August 11, 2009

Adapter

// to bind the second element to 5.
(greater_equal(), 5));

// Compare sequence to string 5
bind2nd(greater_equal(), string("5"))

Focus on If true case only

In many situation, we often need to use if. Therefore, just focus on if true case only.

if (true)
{
// Do something
}

Not need bother the false case.

Tuesday, August 4, 2009

Class Template VS Function Template

Class Template Instantiation requires full type.

Compiler cannot deduced based on context.

Function Template can deduced based on context.

Indirection Layer

Software problem often can solve by another layer/indirection/abstraction.

Reflection

It a kind of manipulation mechanism from extern object.

Type Deduction

Function Template has better type deduction than class template.

Saturday, August 1, 2009

Pirate

http://apps.facebook.com/pirates_world/new.php?invite=Peter_APIIT

Smart Pointer

You can assign a shared_ptr type to another shared_ptr type
if there is relationship between the two.

shared_ptr(Human) sph;
shared_ptr(Staff) sps;
sps = sph; -> OK

Friday, July 31, 2009

Polymorphic on Smar Pointer

Polymorphic on smart pointer is allow.

Staff : class Human

shared_ptr(human) sph;
shared_ptr(staff) sps;

list(shared_ptr(human) ) cont;

cont.push(sph); -> OK
cont.push(sps); -> OK


Monday, July 20, 2009

Named Parameter Idiom

C++ supports only positional parameters and not parameters mapping.


Solution:

The idea, called the Named Parameter Idiom, is to change the function's parameters to methods of a newly created class, where all these methods return *this by reference. Then you simply rename the main function into a parameterless "do-it" method on that class.

Wraps all parameter into member function of a class and its required parameters as private member.


class File;



class OpenFile {

public:

OpenFile(const std::string& filename);

// sets all the default values for each data member

OpenFile& readonly(); // changes readonly_ to true

OpenFile& readwrite(); // changes readonly_ to false

OpenFile& createIfNotExist();

OpenFile& blockSize(unsigned nbytes);

...

private:

friend class File;

std::string filename_;

bool readonly_; // defaults to false [for example]

bool createIfNotExist_; // defaults to false [for example]

...

unsigned blockSize_; // defaults to 4096 [for example]

...

};



inline OpenFile::OpenFile(const std::string& filename)

: filename_ (filename)

, readonly_ (false)

, createIfNotExist_ (false)

, blockSize_ (4096u)

{ }



inline OpenFile& OpenFile::readonly()

{ readonly_ = true; return *this; }



inline OpenFile& OpenFile::readwrite()

{ readonly_ = false; return *this; }



inline OpenFile& OpenFile::createIfNotExist()

{ createIfNotExist_ = true; return *this; }



inline OpenFile& OpenFile::blockSize(unsigned nbytes)

{ blockSize_ = nbytes; return *this; }

class File {

public:

File(const OpenFile& params);

...

};

Construct on First Use Idiom

You need to control the evaluation order of static initialization.

This approach solved the problem.


static Fred& X()
{
static Fred* obj = new Fred();
return *obj;
}

Named Constructor Idiom

you would like to overload constructor on same type argument.

class Rational
{
private:
int x, y;

static Rational rectangular(int, theX, theY)
{
return Rational(theX, theY);
}

static Rational polar(int userX, int userY)
{
return Rational(userX * angle, userY * angle);
}
};

Iteration

Instead of advance iterator with a big step in loop, advance one step ahead each time.

Wrong:
while (LoginIte != loginResult.end())
{
loginResult.insert(LoginIte + 2, "\n");

if (LoginIte + 3 != loginResult.end())
{
LoginIte += 3;
}
else
{
break;
}


Correct:
while (iter != loginResult.end() && ++iter != loginResult.end())
{
++iter;
iter = loginResult.insert(iter, "\n");
++iter;
}

Invalid Iterator

Iterator become invalid after all STL container erase or insert.

Thursday, July 9, 2009

Playing Game .........

AIX && Sparc 1085 32MB

............

Validation Logic ...... TL

bool Human::IsNotAllDigit(const std::vector& result)
{
bool flag(false);
size_t MAX = result.size();

for (size_t loop = 0; loop < MAX;++loop)
{
if (result[loop] == 0)
{
flag = true;
}
}

return flag;
}

Negate of true become false. T....

Wednesday, July 8, 2009

HK

Makiyo, Livana. E

Tuesday, July 7, 2009

Traits

#ifndef EDGETYPETRAITS_H
#define EDGETYPETRAITS_H

// General
template
class edgeTypeTraits;
// =============================================
// Edge Specialization
template <>
class edgeTypeTraits
{
public:
typedef edge edgeType;
};
// =============================================
// Arcs Specialization
template <>
class edgeTypeTraits
{
public:
typedef arcs edgeType;
};
// =============================================
#endif


#ifndef VERTEXTYPETRAITS_H
#define VERTEXTYPETRAITS_H

class edge;
class arcs;

template
class vertex;


// Base class no definition
template
class vertexTypeTraits;


// Partial Specialization
template
class vertexTypeTraits
{
public:
typedef boost::shared_ptr > vertexPtr;
typedef std::vector allVertexVector;
typedef edge edgeType;
};


// Partial Specialization
template
class vertexTypeTraits
{
public:
typedef boost::shared_ptr > vertexPtr;
typedef std::vector allVertexVector;
typedef arcs edgeType;
};
#endif

/*
Traits
= A class template used to describle
another class template parameter
= If/else of type
= Used to Type Parameterize

The compiler looks up information
about the edgeType from graph class template
in the vertex's traits class

Example:
1. char_traits
2. float_traits(std::numeric_limits)

*/



Usage in Graph.h

template
class graph
{
public:

typedef edgeType edgeType;
typedef typename vertexTypeTraits::vertexPtr vertexPtr;
}




Out of Difficulties Makes Miracle

..............