Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Electron update and Linux support #23

Open
wants to merge 7 commits into
base: master
Choose a base branch
from

Conversation

GuillaumeDelorme
Copy link

No description provided.

@romainreignier
Copy link

Nice to see a PR for the Linux support, too bad it has not been merged yet.
We can still use the current version under Linux by copying a built PotreeConverter as libs/PotreeConverter2/PotreeConverter.exe.

I have also done a small patch that I was about to propose as a PR but this one is nicer.
Mine:

diff --git a/src/desktop.js b/src/desktop.js
index 1406c11..6d14299 100644
--- a/src/desktop.js
+++ b/src/desktop.js
@@ -1,4 +1,3 @@
-
 import * as THREE from "../libs/three.js/build/three.module.js"
 import JSON5 from "../libs/json5-2.1.3/json5.mjs";
 
@@ -82,7 +81,10 @@ export function convert_17(inputPaths, chosenPath, pointcloudName){
 
        const { spawn } = require('child_process');
 
-       let exe = './libs/PotreeConverter/PotreeConverter.exe';
+       let exe = './libs/PotreeConverter/PotreeConverter';
+       if(process.platform === 'win32'){
+               exe += '.exe';
+       }
        let parameters = [
                ...inputPaths,
                "-o", chosenPath,
@@ -179,7 +181,10 @@ export function convert_20(inputPaths, chosenPath, pointcloudName){
 
        const { spawn, fork, execFile } = require('child_process');
 
-       let exe = './libs/PotreeConverter2/PotreeConverter.exe';
+       let exe = './libs/PotreeConverter2/PotreeConverter';
+       if(process.platform === 'win32'){
+               exe += '.exe';
+       }
        let parameters = [
                ...inputPaths,
                "-o", chosenPath

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants