Commit MetaInfo
Log Message
[Qt][COMMAND_LINE] Fix not loading virtual floppy disks excepts D77/D88. Thanks to https://matsuri.5ch.net/test/read.cgi/i4004/1483504365/922 .
[Qt][COMMAND_LINE][FM8] Re-enable to loading bubble casette.
[Qt][COMMAND_LINE][PX7] Delay loading movie.Fix crash loading movie with command line.
Change Summary
Incremental Difference
| | @@ -301,6 +301,7 @@ void EmuThreadClass::doWork(const QString ¶ms) | 301 | 301 | // LED | 302 | 302 | uint32_t led_data = 0x00000000; | 303 | 303 | uint32_t led_data_old = 0x00000000; | | 304 | + int turn_count = 0; | 304 | 305 | // Tape | 305 | 306 | // DIG_RESOLUTION | 306 | 307 | // |
| | @@ -440,9 +441,24 @@ void EmuThreadClass::doWork(const QString ¶ms) | 440 | 441 | prevRecordReq = false; | 441 | 442 | } | 442 | 443 | } | 443 | | - | 444 | | - | 445 | | - | | 444 | +#if defined(USE_LASER_DISC) || defined(USE_MOVIE_PLAYER) | | 445 | + if(turn_count < 128) { | | 446 | + turn_count++; | | 447 | + } else { | | 448 | + if(vMovieQueue.size() >= 2) { | | 449 | + for(int ii = 0; ii < vMovieQueue.size(); ii += 2) { | | 450 | + QString _dom = vMovieQueue.at(ii); | | 451 | + QString _path = vMovieQueue.at(ii + 1); | | 452 | + bool _num_ok; | | 453 | + int _dom_num = _dom.right(1).toInt(&_num_ok); | | 454 | + if(!_num_ok) _dom_num = 0; | | 455 | + emit sig_open_laser_disc(_dom_num, _path); | | 456 | + } | | 457 | + vMovieQueue.clear(); | | 458 | + //turn_count = 0; | | 459 | + } | | 460 | + } | | 461 | +#endif | 446 | 462 | #if defined(USE_MOUSE) // Will fix | 447 | 463 | emit sig_is_enable_mouse(p_emu->is_mouse_enabled()); | 448 | 464 | #endif |
| | @@ -725,7 +725,7 @@ void EmuThreadClass::do_open_bubble_casette(int drv, QString path, int bank) | 725 | 725 | try { | 726 | 726 | fio->Fseek(0, FILEIO_SEEK_END); | 727 | 727 | int file_size = fio->Ftell(), file_offset = 0; | 728 | | - while(file_offset + 0x2b0 <= file_size && p_emu->d88_file[drv].bank_num < MAX_B77_BANKS) { | | 728 | + while(file_offset + 0x2b0 <= file_size && p_emu->b77_file[drv].bank_num < MAX_B77_BANKS) { | 729 | 729 | fio->Fseek(file_offset, FILEIO_SEEK_SET); | 730 | 730 | char tmp[18]; | 731 | 731 | memset(tmp, 0x00, sizeof(tmp)); |
| | @@ -877,9 +877,9 @@ void SetOptions(QCommandLineParser *cmdparser) | 877 | 877 | //SetBinaryOptions(cmdparser); // Temporally disabled. | 878 | 878 | SetCmtOptions(cmdparser); | 879 | 879 | SetCartOptions(cmdparser); | 880 | | - //SetBubbleOptions(cmdparser); // Temporally disabled. | | 880 | + SetBubbleOptions(cmdparser); // Temporally disabled. | 881 | 881 | SetQuickDiskOptions(cmdparser); | 882 | | - //SetLDOptions(cmdparser); // Temporally disabled. | | 882 | + SetLDOptions(cmdparser); // Temporally disabled. | 883 | 883 | SetCDOptions(cmdparser); | 884 | 884 | | 885 | 885 | } |
| | @@ -20,6 +20,8 @@ | 20 | 20 | #include "emu_thread_tmpl.h" | 21 | 21 | | 22 | 22 | #include "qt_gldraw.h" | | 23 | +#include "common.h" | | 24 | + | 23 | 25 | //#include "../../romakana.h" | 24 | 26 | | 25 | 27 | //#include "csp_logger.h" |
| | @@ -40,7 +42,8 @@ EmuThreadClassBase::EmuThreadClassBase(META_MainWindow *rootWindow, USING_FLAGS | 40 | 42 | skip_frames = 0; | 41 | 43 | calc_message = true; | 42 | 44 | mouse_flag = false; | 43 | | - | | 45 | + vMovieQueue.clear(); | | 46 | + | 44 | 47 | drawCond = new QWaitCondition(); | 45 | 48 | keyMutex = new QMutex(QMutex::Recursive); | 46 | 49 | mouse_x = 0; |
| | @@ -310,12 +313,17 @@ int EmuThreadClassBase::parse_command_queue(QStringList _l, int _begin) | 310 | 313 | fileInfo = QFileInfo(_file); | 311 | 314 | } | 312 | 315 | if(fileInfo.isFile()) { | | 316 | + _TCHAR *path_shadow = fileInfo.absoluteFilePath().toLocal8Bit().constData(); | 313 | 317 | if(_dom_type == QString::fromUtf8("vFloppyDisk")) { | 314 | 318 | emit sig_open_fd(_dom_num, fileInfo.absoluteFilePath()); | 315 | | - emit sig_set_d88_num(_dom_num, _slot); | | 319 | + if(check_file_extension(path_shadow, ".d88") || check_file_extension(path_shadow, ".d77")) { | | 320 | + emit sig_set_d88_num(_dom_num, _slot); | | 321 | + } | 316 | 322 | } else if(_dom_type == QString::fromUtf8("vBubble")) { | 317 | 323 | emit sig_open_bubble(_dom_num, fileInfo.absoluteFilePath()); | 318 | | - //emit sig_set_b77_num(_dom_num, _slot); | | 324 | + if(check_file_extension(path_shadow, ".b77")) { | | 325 | + emit sig_set_b77_num(_dom_num, _slot); | | 326 | + } | 319 | 327 | } | 320 | 328 | } | 321 | 329 | } else { |
| | @@ -330,7 +338,9 @@ int EmuThreadClassBase::parse_command_queue(QStringList _l, int _begin) | 330 | 338 | } else if(_dom_type == QString::fromUtf8("vCart")) { | 331 | 339 | emit sig_open_cart(_dom_num, fileInfo.absoluteFilePath()); | 332 | 340 | } else if(_dom_type == QString::fromUtf8("vLD")) { | 333 | | - emit sig_open_laser_disc(_dom_num, fileInfo.absoluteFilePath()); | | 341 | + vMovieQueue.append(_dom); | | 342 | + vMovieQueue.append(fileInfo.absoluteFilePath()); | | 343 | + //emit sig_open_laser_disc(_dom_num, fileInfo.absoluteFilePath()); | 334 | 344 | } else if(_dom_type == QString::fromUtf8("vCD")) { | 335 | 345 | emit sig_open_cdrom(_dom_num, fileInfo.absoluteFilePath()); | 336 | 346 | } |
| | @@ -13,6 +13,7 @@ | 13 | 13 | #include <QThread> | 14 | 14 | #include <QQueue> | 15 | 15 | #include <QString> | | 16 | +#include <QStringList> | 16 | 17 | #include <QElapsedTimer> | 17 | 18 | | 18 | 19 | #include "fifo.h" |
| | @@ -101,6 +102,7 @@ protected: | 101 | 102 | QString laserdisc_text; | 102 | 103 | QString bubble_text[16]; | 103 | 104 | QString clipBoardText; | | 105 | + QStringList vMovieQueue; | 104 | 106 | | 105 | 107 | void calc_volume_from_balance(int num, int balance); | 106 | 108 | void calc_volume_from_level(int num, int level); |
Show on old repository browser
|