mirror of
https://github.com/jpd002/Play-.git
synced 2025-04-28 13:47:57 +03:00
Changes for thread based player.
This commit is contained in:
parent
231ffb8059
commit
82800241aa
6 changed files with 111 additions and 9 deletions
|
@ -12,7 +12,7 @@ let updateTimer : any;
|
|||
|
||||
let updateFct = async function() {
|
||||
let releaseLock = await tickMutex.acquire();
|
||||
await tickPsf();
|
||||
// await tickPsf();
|
||||
updateTimer = setTimeout(updateFct, updateDelay);
|
||||
releaseLock();
|
||||
};
|
||||
|
|
|
@ -6,7 +6,8 @@ let module_overrides = {
|
|||
locateFile: function(path : string) {
|
||||
const baseURL = window.location.origin + window.location.pathname.substring(0, window.location.pathname.lastIndexOf( "/" ));
|
||||
return baseURL + '/' + path;
|
||||
}
|
||||
},
|
||||
mainScriptUrlOrBlob: "",
|
||||
};
|
||||
|
||||
function convertStringVectorToArray(strVector : any) {
|
||||
|
@ -33,9 +34,10 @@ function convertStringMapToDictionary(strMap : any) {
|
|||
}
|
||||
|
||||
export let initPsfPlayerModule = async function() {
|
||||
module_overrides.mainScriptUrlOrBlob = module_overrides.locateFile('PsfPlayer.js');
|
||||
PsfPlayerModule = await PsfPlayer(module_overrides);
|
||||
PsfPlayerModule.FS.mkdir("/work");
|
||||
await PsfPlayerModule.ccall("initVm", "", [], [], { async: true });
|
||||
PsfPlayerModule.ccall("initVm", "", [], []);
|
||||
};
|
||||
|
||||
export let getPsfArchiveFileList = function(archivePath : string) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue