mirror of
https://github.com/processing/processing4.git
synced 2026-05-03 17:35:00 +02:00
Fixed wrong path assignment on Linux and Windows
This commit is contained in:
@@ -680,7 +680,7 @@ public class Movie extends PImage implements PConstants {
|
||||
// which is less fun, so this will crap out.
|
||||
file = new File(parent.dataPath(filename));
|
||||
if (file.exists()) {
|
||||
gplayer = new PlayBin2("GSMovie Player");
|
||||
gplayer = new PlayBin2("Movie Player");
|
||||
gplayer.setInputFile(file);
|
||||
}
|
||||
} catch (Exception e) {
|
||||
@@ -693,23 +693,21 @@ public class Movie extends PImage implements PConstants {
|
||||
try {
|
||||
file = new File(filename);
|
||||
if (file.exists()) {
|
||||
gplayer = new PlayBin2("GSMovie Player");
|
||||
gplayer = new PlayBin2("Movie Player");
|
||||
gplayer.setInputFile(file);
|
||||
}
|
||||
} catch (Exception e) {
|
||||
PApplet.println("Shit coming...");
|
||||
e.printStackTrace();
|
||||
}
|
||||
}
|
||||
|
||||
// Network read...
|
||||
if (gplayer == null) {
|
||||
if (gplayer == null && filename.startsWith("http://")) {
|
||||
try {
|
||||
PApplet.println("network read");
|
||||
gplayer = new PlayBin2("GSMovie Player");
|
||||
gplayer = new PlayBin2("Movie Player");
|
||||
gplayer.setURI(URI.create(filename));
|
||||
} catch (Exception e) {
|
||||
PApplet.println("Shit coming...");
|
||||
e.printStackTrace();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -101,7 +101,8 @@ public class Video implements PConstants {
|
||||
setMacOSXPath();
|
||||
}
|
||||
|
||||
PApplet.println("gstreamerBinPath: " + gstreamerBinPath);
|
||||
System.out.println("gstreamerBinPath: " + gstreamerBinPath);
|
||||
System.out.flush();
|
||||
if (!gstreamerBinPath.equals("")) {
|
||||
System.setProperty("jna.library.path", gstreamerBinPath);
|
||||
}
|
||||
@@ -159,8 +160,8 @@ public class Video implements PConstants {
|
||||
if (localGStreamerPath.equals("")) {
|
||||
LibraryPath libPath = new LibraryPath();
|
||||
String path = libPath.get();
|
||||
gstreamerBinPath = path + "/linux" + bitsJVM;
|
||||
gstreamerPluginsPath = buildGStreamerBinPath(gstreamerBinPath, "/" + localPluginsFolder);
|
||||
gstreamerBinPath = buildGStreamerBinPath(path, "/linux" + bitsJVM);
|
||||
gstreamerPluginsPath = gstreamerBinPath + "/" + localPluginsFolder;
|
||||
} else {
|
||||
gstreamerBinPath = localGStreamerPath;
|
||||
gstreamerPluginsPath = localGStreamerPath + "/" + localPluginsFolder;
|
||||
@@ -177,8 +178,8 @@ public class Video implements PConstants {
|
||||
if (localGStreamerPath.equals("")) {
|
||||
LibraryPath libPath = new LibraryPath();
|
||||
String path = libPath.get();
|
||||
gstreamerBinPath = path + "\\windows" + bitsJVM;
|
||||
gstreamerPluginsPath = buildGStreamerBinPath(gstreamerBinPath , "\\" + localPluginsFolder);
|
||||
gstreamerBinPath = buildGStreamerBinPath(path, "\\windows" + bitsJVM);
|
||||
gstreamerPluginsPath = gstreamerBinPath + "\\" + localPluginsFolder;
|
||||
} else {
|
||||
gstreamerBinPath = localGStreamerPath;
|
||||
gstreamerPluginsPath = localGStreamerPath + "\\" + localPluginsFolder;
|
||||
|
||||
Reference in New Issue
Block a user