Click here to Skip to main content
15,898,938 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: calling code with MFC in non MFC environment Pin
Mark Salsbery6-Feb-08 8:48
Mark Salsbery6-Feb-08 8:48 
GeneralRe: calling code with MFC in non MFC environment Pin
act_x6-Feb-08 8:51
act_x6-Feb-08 8:51 
GeneralRe: calling code with MFC in non MFC environment Pin
act_x6-Feb-08 8:52
act_x6-Feb-08 8:52 
GeneralRe: calling code with MFC in non MFC environment Pin
Mark Salsbery6-Feb-08 9:00
Mark Salsbery6-Feb-08 9:00 
GeneralNamedpipe communication Pin
harsha u6-Feb-08 5:52
harsha u6-Feb-08 5:52 
GeneralRe: Namedpipe communication Pin
Mark Salsbery6-Feb-08 6:09
Mark Salsbery6-Feb-08 6:09 
GeneralD3DXCreateTextureFromFile() Pin
Hanan8886-Feb-08 5:43
Hanan8886-Feb-08 5:43 
GeneralRe: D3DXCreateTextureFromFile() Pin
Cedric Moonen6-Feb-08 7:27
Cedric Moonen6-Feb-08 7:27 
I never used DirectX myself but I suppose that it is a normal behavior. I suppose that the function will load data from the file, which is always a "slow" process. Do you need to load 150 different images ? Because then your software is not very optimized. The best way to tackle this is to use a unique resource manager (make it a singleton for example) from which you will load your textures. The manager will cache the textures internally so that later, if the same texture is needed, it is returned directly, no need to reload the file once again. This has another big advantage: you just have one copy of the same texture in memory (instead of having 150 instances of the same texture, which of course takes a LOT of memory).

Hope that helps.

Cédric Moonen
Software developer

Charting control [v1.2]

GeneralRe: D3DXCreateTextureFromFile() Pin
Hanan8886-Feb-08 22:18
Hanan8886-Feb-08 22:18 
GeneralRe: D3DXCreateTextureFromFile() Pin
Cedric Moonen7-Feb-08 0:09
Cedric Moonen7-Feb-08 0:09 
GeneralRe: D3DXCreateTextureFromFile() Pin
Hanan8887-Feb-08 0:44
Hanan8887-Feb-08 0:44 
GeneralRe: D3DXCreateTextureFromFile() Pin
Maximilien6-Feb-08 8:11
Maximilien6-Feb-08 8:11 
GeneralRe: D3DXCreateTextureFromFile() Pin
Hanan8886-Feb-08 22:24
Hanan8886-Feb-08 22:24 
Questionhow to convert hex to int Pin
Electronic756-Feb-08 5:21
Electronic756-Feb-08 5:21 
AnswerRe: how to convert hex to int Pin
David Crow6-Feb-08 5:46
David Crow6-Feb-08 5:46 
GeneralRe: how to convert hex to int Pin
Electronic756-Feb-08 5:51
Electronic756-Feb-08 5:51 
AnswerRe: how to convert hex to int Pin
CPallini6-Feb-08 5:57
mveCPallini6-Feb-08 5:57 
GeneralRe: how to convert hex to int Pin
Electronic756-Feb-08 6:27
Electronic756-Feb-08 6:27 
GeneralCall external executable Pin
sunny.rana6-Feb-08 4:52
sunny.rana6-Feb-08 4:52 
QuestionRe: Call external executable Pin
CPallini6-Feb-08 4:56
mveCPallini6-Feb-08 4:56 
GeneralRe: Call external executable Pin
Matthew Faithfull6-Feb-08 4:58
Matthew Faithfull6-Feb-08 4:58 
QuestionRe: Call external executable Pin
David Crow6-Feb-08 5:45
David Crow6-Feb-08 5:45 
GeneralRe: Call external executable Pin
Iain Clarke, Warrior Programmer7-Feb-08 0:06
Iain Clarke, Warrior Programmer7-Feb-08 0:06 
Generalmt.exe : general error c10100b1 (VS 2008) [modified] Pin
Ravi K6-Feb-08 3:36
Ravi K6-Feb-08 3:36 
GeneralRe: mt.exe : general error c10100b1 (VS 2008) Pin
Iain Clarke, Warrior Programmer6-Feb-08 4:14
Iain Clarke, Warrior Programmer6-Feb-08 4:14 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.