Previous Thread
Next Thread
Print Thread
Page 98 of 116 1 2 96 97 98 99 100 115 116
Joined: Mar 2001
Posts: 16,923
Likes: 57
R
Very Senior Member
Offline
Very Senior Member
R
Joined: Mar 2001
Posts: 16,923
Likes: 57
chdman itself is wide-threaded, so it's not a great idea to run more than one instance at a time; you'll slow down all of them.

Joined: Mar 2008
Posts: 1,049
Very Senior Member
OP Offline
Very Senior Member
Joined: Mar 2008
Posts: 1,049
Oh, you're right, Arbee...

But the idea is to run the next process just after finishing the last one. I just want to automate the process (put every cue+bin in the same folder, run a script and convert every one to CHD after some time).

I don't know how to create a script for this yet.
Would it be something like this?

Code:
var inputFolder = "c:/input";
var outputFolder = "c:/output";
var file;
var id;

while(chdman.dirHasNextEntry())
{
   file=chdman.dirNextEntry();
   id=???;//I want to create the outputfile with the same name of the original, but .chd. Example: mame.cue -> mame.chd
   chdman.projectSetCreateCDInputFile(id, file);
   //wait until the process finish
}

(one after other, of course)

Ps.: there's any script file to take a look?


"A user interface is like a joke. If you have to explain it, it's not that good."
Joined: May 2008
Posts: 4,930
Likes: 24
Q
Very Senior Member
Offline
Very Senior Member
Q
Joined: May 2008
Posts: 4,930
Likes: 24
Take a look at the example scripts that are available from the wiki page (edit: new version). Currently there's only one script in this "collection" but it demonstrates many important features (like connecting a JS function to a signal from qchdman, how to utilize (possible) parallelism, using JS's forEach() and more).

The ID is the unique "project ID" that you have to define and use within your script. See the function "processChdFile" in the example which creates "chdman copy" projects and starts them by their name.

Last edited by qmc2; 11/30/15 03:23 PM.

A mind is like a parachute. It doesn't work unless it's open. [Frank Zappa]
Joined: May 2008
Posts: 4,930
Likes: 24
Q
Very Senior Member
Offline
Very Senior Member
Q
Joined: May 2008
Posts: 4,930
Likes: 24
Also, when all projects within a loop are more or less the same, you can create one manually as a template, store it under some file name and load it within the script (projectCreateFromFile()). Then just change the settings that need to be set individually (i.e. input / output files), start it and call syncProjects() (or waitForRunningProjects()).


A mind is like a parachute. It doesn't work unless it's open. [Frank Zappa]
Joined: May 2008
Posts: 4,930
Likes: 24
Q
Very Senior Member
Offline
Very Senior Member
Q
Joined: May 2008
Posts: 4,930
Likes: 24
BTW, the script engine has a built-in debugger. Put the word "debugger" in one of the first lines of your script to open the debugger window... if a script encounters an error, the debugger will open automatically.


A mind is like a parachute. It doesn't work unless it's open. [Frank Zappa]
Joined: Jul 2010
Posts: 40
P
Member
Offline
Member
P
Joined: Jul 2010
Posts: 40
I made an embarrassing mistake. Maybe you can save others from making the same mistake.
So what happened? Occasionally the power quality here slightly deteriorates for a few minutes. Not by much, just enough to make the UPS wildly click on and off. It does this so rapidly, that the poor UPS can miss a beat and my PC unexpectedly goes off. When my UPS started manically switching earlier this week, I started closing programs for a controlled shut-down, including an open QMC2 (running on Win7 x64). Too slow! Suddenly it switched off. Loading QMC2 up again after re-boot, _nearly_ everything was fine. Except for an empty 'Played' tab and 'Favourites' tab. Last played isn't that important, but Favourites are! Oddly, Favourites within Soft Lists were unaffected. Opening the mame.fav in the .qmc2 directory within C:\Users\MyUsername revealed it to be totally empty. Hmm, that's annoying but no problem; I'm careful enough to use both a UPS AND Backups. Specifically the built in Windows 7 backup tool. I'll just use that to restore the missing file, just like I've been doing for years to restore corrupted Firefox session files, or to restore anything else from C:\Users\MyUsername. What did I find when I searched the normally-fine default settings Windows 7 backups? No sign of the .qmc2 directory.
So I suppose my request would be, please put the .qmc2 directory in one of the AppData directories (AppData\Roaming perhaps?). Maybe that will save others who have successfully relied on default Win 7 Backup and Restore in the past, from being caught out in the same way I was.

Joined: May 2008
Posts: 4,930
Likes: 24
Q
Very Senior Member
Offline
Very Senior Member
Q
Joined: May 2008
Posts: 4,930
Likes: 24
I'm not sure if moving to AppData would avoid such situations but I'll consider it anyway since it's more common on Windows.


A mind is like a parachute. It doesn't work unless it's open. [Frank Zappa]
Joined: Nov 2011
Posts: 175
O
Senior Member
Offline
Senior Member
O
Joined: Nov 2011
Posts: 175
Hello Rene, now with the last SVN r7223 have problem with compiling:

Code:
s\win32-g++-4.6" -o release\movierecordersetup.o movierecordersetup.cpp
compilation terminated.
Makefile.qmake.Release:3508: recipe for target 'release/collectionrebuilder.o' failed
make.exe[2]: *** [release/collectionrebuilder.o] Error 1
make.exe[2]: *** Waiting for unfinished jobs....
make.exe[2]: Leaving directory 'g:/compile_mame/qmc2'
Makefile.qmake:34: recipe for target 'release' failed
make.exe[1]: *** [release] Error 2
make.exe[1]: Leaving directory 'g:/compile_mame/qmc2'
makefile:1049: recipe for target 'qmc2-bin' failed
make.exe: *** [qmc2-bin] Error 2
make.exe: Leaving directory 'g:/compile_mame/qmc2'
Finish at:  8:52:43,35


tnx smile

Joined: May 2008
Posts: 4,930
Likes: 24
Q
Very Senior Member
Offline
Very Senior Member
Q
Joined: May 2008
Posts: 4,930
Likes: 24
That doesn't tell us where the problem is... could you post the relevant parts as well smile!?

It could be caused by the old default setting for MKSPEC in case of MinGW now that the tools use a newer gcc. I've just changed the default to "MKSPEC=win32-g++" in the hope that it fixes it.

Last edited by qmc2; 12/20/15 08:20 AM.

A mind is like a parachute. It doesn't work unless it's open. [Frank Zappa]
Joined: Nov 2011
Posts: 175
O
Senior Member
Offline
Senior Member
O
Joined: Nov 2011
Posts: 175
Rene same problem smile
Whats more info u need ?

Code:
DQT_SVG_LIB -DQT_SQL_LIB -DQT_XMLPATTERNS_LIB -DQT_XML_LIB -DQT_GUI_LIB -DQT_NETWORK_LIB -DQT_CORE_LIB -DQT_HAVE_MMX -DQT_HAVE_SSE -DQT_HAVE_MMXEXT -DQT_HAVE_SSE2 -DQT_THREAD_SUPPORT -I"..\buildtools\vendor\qt\mingw64\Qt\include\QtCore" -I"..\buildtools\vendor\qt\mingw64\Qt\include\QtNetwork" -I"..\buildtools\vendor\qt\mingw64\Qt\include\QtGui" -I"..\buildtools\vendor\qt\mingw64\Qt\include\QtXml" -I"..\buildtools\vendor\qt\mingw64\Qt\include\QtXmlPatterns" -I"..\buildtools\vendor\qt\mingw64\Qt\include\QtSql" -I"..\buildtools\vendor\qt\mingw64\Qt\include\QtSvg" -I"..\buildtools\vendor\qt\mingw64\Qt\include\phonon" -I"..\buildtools\vendor\qt\mingw64\Qt\include\QtWebKit" -I"..\buildtools\vendor\qt\mingw64\Qt\include" -I"..\buildtools\vendor\qt\mingw64\Qt\include\QtTest" -I"minizip" -I"zlib" -I"lzma" -I"..\buildtools\vendor\mingw64\x86_64-w64-mingw32\include" -I"..\buildtools\vendor\mingw64\x86_64-w64-mingw32\include\SDL2" -I"..\buildtools\vendor\qt\mingw64\Qt\include\ActiveQt" -I"..\buildtools\vendor\qt\mingw64\Qt\include\phonon_compat" -I"release" -I"." -I"..\buildtools\vendor\qt\mingw64\Qt\mkspecs\win32-g++" -o release\missingdumpsviewer.o missingdumpsviewer.cpp
Makefile.qmake.Release:3508: recipe for target 'release/collectionrebuilder.o' failed
make.exe[2]: *** [release/collectionrebuilder.o] Error 1
make.exe[2]: *** Waiting for unfinished jobs....
make.exe[2]: Leaving directory 'g:/compile_mame/qmc2'
Makefile.qmake:34: recipe for target 'release' failed
make.exe[1]: *** [release] Error 2
make.exe[1]: Leaving directory 'g:/compile_mame/qmc2'
makefile:1049: recipe for target 'qmc2-bin' failed
make.exe: *** [qmc2-bin] Error 2
make.exe: Leaving directory 'g:/compile_mame/qmc2'
Finish at: 11:11:58,75

Last edited by oddi; 12/20/15 09:13 AM.
Page 98 of 116 1 2 96 97 98 99 100 115 116

Moderated by  qmc2 

Link Copied to Clipboard
Who's Online Now
2 members (Heihachi_73, 1 invisible), 23 guests, and 3 robots.
Key: Admin, Global Mod, Mod
ShoutChat
Comment Guidelines: Do post respectful and insightful comments. Don't flame, hate, spam.
Forum Statistics
Forums9
Topics9,103
Posts119,286
Members5,019
Most Online890
Jan 17th, 2020
Our Sponsor
These forums are sponsored by Superior Solitaire, an ad-free card game collection for macOS and iOS. Download it today!

Superior Solitaire
Forum hosted by www.retrogamesformac.com