Hi every body...
I've got a problem with references(type &var) and pointers(type *var).look at the following sample code :

/* (1) */
void CreateTexture1( IDirect3DTexture9* pTexture )
{
// some code that create texture from file
};

/* (2) */
void CreateTexture2( IDirect3DTexture9*& pTexture )
{
// some code that create texture from file
};

void mainFunction()
{
.
.
.

IDirect3DTexture9* pTexture = NULL ;

CreateTexture1( pTexture );
CreateTexture2( pTexture );

.
.
.
};

I'm going to use passed argument as an output.
Both CreateTexture1 & CreateTexture2 using exactly the same code , but different type of argument passings.

"CreateTexture1" can not alter pTexture but "CreateTexture2" can. why? I passed the argument with it's pointer so it must be changed? but it didn't on CreateTexture1! I don't have such a problem with types DWORD,UINT ,... but I have this with IDirect3DTexture9 .

Can you tell me why or redirect me to an article about it on the web?

Thank you.