Jump to content
  • Advertisement
Sign in to follow this  
Duel93

glGetProgramBinary question

This topic is 2532 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

When I use glGetProgramBinary and save the result to a file, I see the source code, along with the binary data when I open the saved file with notepad. I don't want any source to display with the binary data. How to I prevent this?

Share this post


Link to post
Share on other sites
Advertisement
The binary you get is only for the purpose of caching and pre-compilation on a single computer. The binary is, as far as the specification is concerned, only valid on the very computer you compile it on as long as the setup (possibly even including driver version) is not changed. You cannot distribute the binary, because its content is not defined and will vary, and you must pre-compile the binary on every computer the first time you run it and every time the driver thinks its outdated (due to an updated driver version, for example). You must, therefore, already have the source to compile it the first time, so it doesn't matter if the source is visible in the binary.

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

GameDev.net is your game development community. Create an account for your GameDev Portfolio and participate in the largest developer community in the games industry.

Sign me up!