Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- ID3DBlob* outBlob = nullptr, *errorBlob = nullptr;
- std::ifstream infile(fileName.c_str(), std::ios::binary);
- std::vector<char> content;
- infile.seekg(0, std::ios::end);
- content.resize(infile.tellg());
- infile.seekg(0, std::ios::beg);
- infile.read(content.data(), content.size());
- infile.close();
- hr = D3DCompile(content.data(), content.size(), "Shader", nullptr, nullptr, entryPoint.c_str(), shaderModel.c_str(), dwShaderFlags, 0, &outBlob, &errorBlob);
Advertisement
Add Comment
Please, Sign In to add comment