mirror of
https://github.com/projectM-visualizer/projectm.git
synced 2026-03-07 07:55:15 +00:00
Issue#130 (#546)
* Fixes issue projectM-visualizer/projectm#130 Adds functionality of writing a rendered frame to file as requested by the issue https://github.com/projectM-visualizer/projectm/issues/130. Keyhandler.cpp has been updated to handle the keydown of 'd', which triggers writeNextFrameToFile to be set to true, which means at the end of Renderer::FinishPass1 we write the texture contents to file. Renderer::debugWriteMainTextureToFile() const contains the functionality of writing the contents of the main texture. * Addition to commit that fixes projectM-visualizer/projectm#130 Safe file write, making sure we don't overflow while creating the filename. If c++20 features was enabled, this could look so, so much better. * Added keybinding to README doc * Formatting Fixed snake_case to camelCase Changed delete to delete[] Turned magic constant to a named variable
This commit is contained in:
@ -311,6 +311,9 @@ void projectM::default_key_handler( projectMEvent event, projectMKeycode keycode
|
||||
renderer->studio = !renderer->studio;
|
||||
case PROJECTM_K_i:
|
||||
break;
|
||||
case PROJECTM_K_d: // d stands for write DEBUG output.
|
||||
renderer->writeNextFrameToFile = true;
|
||||
break;
|
||||
case PROJECTM_K_RETURN:
|
||||
renderer->toggleSearchText();
|
||||
if (renderer->showsearch) {
|
||||
|
||||
Reference in New Issue
Block a user