comparison vgmplay.c @ 1558:55d357bb4398

Fix vgmplay
author Michael Pavone <pavone@retrodev.com>
date Mon, 02 Apr 2018 00:58:42 -0700
parents 57637d17b59e
children 0174759e559f
comparison
equal deleted inserted replaced
1557:a0fbb1e90533 1558:55d357bb4398
106 106
107 char * lowpass_cutoff_str = tern_find_path(config, "audio\0lowpass_cutoff\0", TVAL_PTR).ptrval; 107 char * lowpass_cutoff_str = tern_find_path(config, "audio\0lowpass_cutoff\0", TVAL_PTR).ptrval;
108 uint32_t lowpass_cutoff = lowpass_cutoff_str ? atoi(lowpass_cutoff_str) : 3390; 108 uint32_t lowpass_cutoff = lowpass_cutoff_str ? atoi(lowpass_cutoff_str) : 3390;
109 109
110 ym2612_context y_context; 110 ym2612_context y_context;
111 ym_init(&y_context, render_sample_rate(), MCLKS_NTSC, MCLKS_PER_YM, render_audio_buffer(), opts, lowpass_cutoff); 111 ym_init(&y_context, MCLKS_NTSC, MCLKS_PER_YM, opts);
112 112
113 psg_context p_context; 113 psg_context p_context;
114 psg_init(&p_context, render_sample_rate(), MCLKS_NTSC, MCLKS_PER_PSG, render_audio_buffer(), lowpass_cutoff); 114 psg_init(&p_context, MCLKS_NTSC, MCLKS_PER_PSG);
115 115
116 FILE * f = fopen(argv[1], "rb"); 116 FILE * f = fopen(argv[1], "rb");
117 vgm_header header; 117 vgm_header header;
118 fread(&header, sizeof(header), 1, f); 118 fread(&header, sizeof(header), 1, f);
119 if (header.version < 0x150 || !header.data_offset) { 119 if (header.version < 0x150 || !header.data_offset) {