Gamestudio Links
Zorro Links
Newest Posts
Zorro tutorial ideas?
by mistery. 09/19/26 17:09
Trades during a running bar
by Martin_HH. 09/18/26 12:45
Capital slider is not saving in Z12
by frutza. 09/17/26 13:36
Avoiding pop-up training parameter results
by Martin_HH. 09/16/26 21:31
What are you working on?
by rayp. 09/16/26 20:20
Future of ZorroHFT
by TipmyPip. 09/16/26 09:28
AUM Magazine
Latest Screens
Dorifto samurai
Shadow 2
Rocker`s Revenge
Stug 3 Stormartillery
Who's Online Now
1 registered members (AlleyRatStudios), 2,283 guests, and 1 spider.
Key: Admin, Global Mod, Mod
Newest Members
mistery, lokkalyansamiti, rahulbuilds, speedx, liop
19236 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
LPDIRECT3DCUBETEXTURE9 #482443
02/06/21 10:33
02/06/21 10:33
Joined: Feb 2003
Posts: 146
RP China
2
20BN Offline OP
Member
20BN  Offline OP
Member
2

Joined: Feb 2003
Posts: 146
RP China
hello all,
someone help me, how to Release LPDIRECT3DCUBETEXTURE9 texture memory?
LPDIRECT3DCUBETEXTURE9* ABC
....
.....D3DXCreateCubeTextureFromFile....
....
ABC->Release();

ERROR: Release() is nor d3d9.h function.

THANKS!

Re: LPDIRECT3DCUBETEXTURE9 [Re: 20BN] #488154
04/01/24 08:39
04/01/24 08:39
Joined: Oct 2008
Posts: 683
Germany
Ayumi Offline
User
Ayumi  Offline
User

Joined: Oct 2008
Posts: 683
Germany
Hey, you have to use it right way:

Code

typedef struct _smpCube
{
	LPDIRECT3DCUBETEXTURE9 ShadowMap; 
   
} SmpCube;

SmpCube* SmpCubeObj;


// Cleanup
if(SmpCubeObj->ShadowMap != NULL)
{
   ((LPDIRECT3DCUBETEXTURE9)SmpCubeObj->ShadowMap)->Release();
   SmpCubeObj->ShadowMap = NULL;       
}



Re: LPDIRECT3DCUBETEXTURE9 [Re: 20BN] #488175
04/10/24 10:01
04/10/24 10:01
Joined: Sep 2009
Posts: 1,035
Budapest
Aku_Aku Offline
Serious User
Aku_Aku  Offline
Serious User

Joined: Sep 2009
Posts: 1,035
Budapest
Perhaps the bmap_purge() function does the same/similar action.
From the online documentation:
Quote
Releases texture memory used by the given bitmap. Useful for freeing the video memory when a certain panel won't be seen anymore. Video memory is automatically allocated again when the bitmap is seen the next time, so the instruction won't do any harm.

Re: LPDIRECT3DCUBETEXTURE9 [Re: 20BN] #488178
04/12/24 11:00
04/12/24 11:00
Joined: Oct 2008
Posts: 683
Germany
Ayumi Offline
User
Ayumi  Offline
User

Joined: Oct 2008
Posts: 683
Germany
No, that doesn't work.
Direct X functions can only be used via certain (material) events or by initializing your own D3DInstance.
(Have a look to draw_begin or Gamestudio SDK ->Plugin SDK-> Using Direct3D functions).


Moderated by  HeelX, Lukas, rayp, Rei_Ayanami, Superku, Tobias, TWO, VeT 

Gamestudio download | Zorro platform | shop | Data Protection Policy

oP group Germany GmbH | Birkenstr. 25-27 | 63549 Ronneburg / Germany | info (at) opgroup.de

Powered by UBB.threads™ PHP Forum Software 7.7.1