Skip to content

Commit

Permalink
konami/zr107.cpp and some related devices: initialized some variables
Browse files Browse the repository at this point in the history
  • Loading branch information
Osso13 committed Jan 19, 2025
1 parent 9aa85a7 commit cf1d2ee
Show file tree
Hide file tree
Showing 4 changed files with 36 additions and 11 deletions.
19 changes: 19 additions & 0 deletions src/mame/konami/k001005.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,25 @@ k001005_renderer::k001005_renderer(device_t &parent, screen_device &screen, devi
m_3dfifo = std::make_unique<uint32_t[]>(0x10000);
m_3dfifo_ptr = 0;
m_fb_page = 0;
m_light_r = 0;
m_light_g = 0;
m_light_b = 0;
m_ambient_r = 0;
m_ambient_g = 0;
m_ambient_b = 0;
m_fog_r = 0;
m_fog_g = 0;
m_fog_b = 0;
m_far_z = 0;
m_fog_start_z = 0;
m_fog_end_z = 0;
m_reg_fog_start = 0;
m_viewport_min_x = 0;
m_viewport_max_x = 0;
m_viewport_min_y = 0;
m_viewport_max_y = 0;
m_viewport_center_x = 0;
m_viewport_center_y = 0;

m_cliprect = rectangle(0, width-1, 0, height-1);

Expand Down
2 changes: 1 addition & 1 deletion src/mame/konami/k054156_k054157_k056832.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -211,7 +211,6 @@ k056832_device::k056832_device(const machine_config &mconfig, const char *tag, d
//m_line_dirty[K056832_PAGE_COUNT][8],
//m_all_lines_dirty[K056832_PAGE_COUNT],
//m_page_tile_mode[K056832_PAGE_COUNT],
//m_last_colorbase[K056832_PAGE_COUNT],
//m_layer_tile_mode[8],
m_default_layer_association(0),
m_layer_association(0),
Expand All @@ -224,6 +223,7 @@ k056832_device::k056832_device(const machine_config &mconfig, const char *tag, d
m_cur_tile_bank(0),
m_k055555(*this, finder_base::DUMMY_TAG)
{
std::fill(std::begin(m_last_colorbase), std::end(m_last_colorbase), 0);
}

void k056832_device::create_tilemaps()
Expand Down
3 changes: 3 additions & 0 deletions src/mame/konami/konppc.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,9 @@ void konppc_device::device_start()
for (i=0; i < num_cgboards; i++)
{
dsp_comm_ppc[i][0] = 0x00;
dsp_comm_ppc[i][1] = 0x00;
dsp_comm_sharc[i][0] = 0x00;
dsp_comm_sharc[i][1] = 0x00;
dsp_shared_ram[i] = std::make_unique<uint32_t[]>(DSP_BANK_SIZE * 2/4);
dsp_shared_ram_bank[i] = 0;

Expand Down
23 changes: 13 additions & 10 deletions src/mame/konami/zr107.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -169,21 +169,24 @@ Check drivers/gticlub.cpp for details on the bottom board.
*/

#include "emu.h"

#include "k001005.h"
#include "k001006.h"
#include "k001604.h"
#include "k054156_k054157_k056832.h"
#include "konami_helper.h"
#include "konppc.h"

#include "cpu/m68000/m68000.h"
#include "cpu/powerpc/ppc.h"
#include "cpu/sharc/sharc.h"
#include "machine/adc083x.h"
#include "machine/eepromser.h"
#include "machine/k056230.h"
#include "konppc.h"
#include "machine/watchdog.h"
#include "sound/k054539.h"
#include "sound/k056800.h"
#include "k001005.h"
#include "k001006.h"
#include "k001604.h"
#include "k054156_k054157_k056832.h"
#include "konami_helper.h"

#include "emupal.h"
#include "speaker.h"

Expand Down Expand Up @@ -238,10 +241,10 @@ class zr107_state : public driver_device
required_shared_ptr<uint32_t> m_sharc_dataram;
required_device<konppc_device> m_konppc;

int m_ccu_vcth;
int m_ccu_vctl;
uint8_t m_sound_ctrl;
uint8_t m_sound_intck;
int m_ccu_vcth = 0;
int m_ccu_vctl = 0;
uint8_t m_sound_ctrl = 0;
uint8_t m_sound_intck = 0;

uint8_t sysreg_r(offs_t offset);
void sysreg_w(offs_t offset, uint8_t data);
Expand Down

0 comments on commit cf1d2ee

Please sign in to comment.