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

Gfx save #13430

Open
wants to merge 11 commits into
base: master
Choose a base branch
from
Open

Gfx save #13430

wants to merge 11 commits into from

Conversation

Deedolith
Copy link

Implemented the possibility to save the currently displayed gfx set using the snapshot hotkey (default F12).
The file (PNG) will be saved under the gfxsave directory wich will be created if needed).

Moved gfx_viewer out of anonymous namespace.
Renamed gfxWriter class to gfx_writer.
Made gfx_writer class friend of gfx_viewer class.
Changed bitmap_rgb32 to bitmap_argb32 for transparency support.
Sorted out #include.
…o a PNG file.

The file is saved under the gfxsave directory, it will be created if needed.
@Deedolith
Copy link
Author

Hello,
It's been over 2 weeks since I posted this request, and nothing happened since then.
What's going on ?
Is there something missing ? Wrong ?
Is it rejected ?

Please, let me know.

@JimCarlTay
Copy link

It looks like workflows are still awaiting approval.


bitmap_argb32 gfx_writer::getBitmap(int xCells, int yCells, gfx_viewer::gfxset::setinfo& set, gfx_element& gfx) const
{
auto cellXpix{ (set.m_rotate & ORIENTATION_SWAP_XY) ? gfx.height() : gfx.width() };
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You seem to like that method of initialization for scalar variables. I know it's correct, but it's extremely unusual. We try to avoid unusual when possible, so it would be nice to switch back to the standard '='.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Noted.
I updated te source code accordingly.

Updated variables initialisation to coding standards.
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

Successfully merging this pull request may close these issues.

3 participants