Welcome to ShenZhenJia Knowledge Sharing Community for programmer and developer-Open, Learning and Share
menu search
person
Welcome To Ask or Share your Answers For Others

Categories

I am studying directx12 and I think there is a problem with understanding map and unmap, so I ask a question

hr = constantBufferUploadHeap[i]->Map(0, nullptr, reinterpret_cast<void**>(&cbColorMultiplierGPUAddress[i]));
    constantBufferUploadHeap[i]->Unmap(0, &readRange);
    memcpy(cbColorMultiplierGPUAddress[i], &cbColorMultiplierData, sizeof(cbColorMultiplierData));

If I use map and call unmap right away, can't memcpy be able to work normally? But seeing it work. Please explain about unmap

question from:https://stackoverflow.com/questions/65830388/please-explain-about-unmap

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
thumb_up_alt 0 like thumb_down_alt 0 dislike
1.1k views
Welcome To Ask or Share your Answers For Others

1 Answer

Waitting for answers

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
thumb_up_alt 0 like thumb_down_alt 0 dislike
Welcome to ShenZhenJia Knowledge Sharing Community for programmer and developer-Open, Learning and Share
...