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

Categories

0 votes
1.0k views
in Technique[技术] by (71.8m points)

graphics - Please explain about unmap

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

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Answer

0 votes
by (71.8m points)
Waitting for answers

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...