mirror of
https://github.com/holub/mame
synced 2025-04-24 09:20:02 +03:00
get rid of global_alloc (nw)
This commit is contained in:
parent
c58ef21768
commit
e0358a4ce4
@ -154,8 +154,6 @@ void crosshair_manager::exit()
|
||||
{
|
||||
machine().render().texture_free(m_texture[player]);
|
||||
m_texture[player] = nullptr;
|
||||
|
||||
global_free(m_bitmap[player]);
|
||||
m_bitmap[player] = nullptr;
|
||||
}
|
||||
}
|
||||
@ -173,7 +171,7 @@ void crosshair_manager::create_bitmap(int player)
|
||||
|
||||
/* if we have a bitmap and texture for this player, kill it */
|
||||
if (m_bitmap[player] == nullptr) {
|
||||
m_bitmap[player] = global_alloc(bitmap_argb32);
|
||||
m_bitmap[player] = std::make_unique<bitmap_argb32>();
|
||||
m_texture[player] = machine().render().texture_alloc(render_texture::hq_scale);
|
||||
}
|
||||
|
||||
|
@ -89,7 +89,7 @@ private:
|
||||
UINT8 m_used[MAX_PLAYERS]; /* usage per player */
|
||||
UINT8 m_mode[MAX_PLAYERS]; /* visibility mode per player */
|
||||
UINT8 m_visible[MAX_PLAYERS]; /* visibility per player */
|
||||
bitmap_argb32 * m_bitmap[MAX_PLAYERS]; /* bitmap per player */
|
||||
std::unique_ptr<bitmap_argb32> m_bitmap[MAX_PLAYERS]; /* bitmap per player */
|
||||
render_texture * m_texture[MAX_PLAYERS]; /* texture per player */
|
||||
screen_device * m_screen[MAX_PLAYERS]; /* the screen on which this player's crosshair is drawn */
|
||||
float m_x[MAX_PLAYERS]; /* current X position */
|
||||
|
Loading…
Reference in New Issue
Block a user