Permalink
Browse files

Maximizing the stream time limit.

  • Loading branch information...
1 parent a442757 commit a1f9a31a6bd9b172006235e7496fedae59744cf9 @Raptor399 Raptor399 committed Jul 28, 2013
Showing with 11 additions and 1 deletion.
  1. +11 −1 src/main/java/net/pms/dlna/DLNAMediaInfo.java
@@ -19,6 +19,7 @@
package net.pms.dlna;
import com.sun.jna.Platform;
+
import net.coobird.thumbnailator.Thumbnails;
import net.coobird.thumbnailator.Thumbnails.Builder;
import net.coobird.thumbnailator.tasks.UnsupportedFormatException;
@@ -35,6 +36,7 @@
import net.pms.util.FileUtil;
import net.pms.util.MpegUtil;
import net.pms.util.ProcessUtil;
+
import org.apache.sanselan.ImageInfo;
import org.apache.sanselan.Sanselan;
import org.apache.sanselan.common.IImageMetadata;
@@ -51,6 +53,7 @@
import javax.imageio.IIOException;
import javax.imageio.ImageIO;
+
import java.awt.*;
import java.awt.image.BufferedImage;
import java.io.*;
@@ -74,8 +77,15 @@
private static final PmsConfiguration configuration = PMS.getConfiguration();
public static final long ENDFILE_POS = 99999475712L;
- public static final long TRANS_SIZE = 100000000000L;
+ /**
+ * Maximum size of a stream, taking into account that some renderers (like
+ * the PS3) will convert this <code>long</code> to <code>int</code>.
+ * Truncating this value will still return the maximum value that an
+ * <code>int</code> can contain.
+ */
+ public static final long TRANS_SIZE = Long.MAX_VALUE - Integer.MAX_VALUE - 1;
+
// Stored in database
private Double durationSec;

0 comments on commit a1f9a31

Please sign in to comment.