Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Example for retrieve buffer size of bin file via ostream* pointer #97

Closed
Annie834 opened this issue May 5, 2022 · 0 comments
Closed

Comments

@Annie834
Copy link

Annie834 commented May 5, 2022

I am intented to get buffer size from ostream, after performing the method "GetBufferStream"

std::string bufferStr; for (auto ele : doc.bufferViews.Elements()) { // std::stringstream std::ostream* ostrem = glbResourceWriter->GetBufferStream(ele.id); (*ostrem) << bufferStr; bufferStr += bufferStr; } bin_out.append(bufferStr.data(), bufferStr.data() + bufferStr.length());

the issue is that value of bufferStr is awalys empty or null, therefore, it is impossible to calculate the buffer size and data from the bufferStr.

the screenshot of result:
image

it's appreciated if you can reply my question.

@Annie834 Annie834 closed this as completed May 6, 2022
@Annie834 Annie834 reopened this May 6, 2022
@Annie834 Annie834 closed this as completed May 6, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant