Skip to content

Commit

Permalink
More sync
Browse files Browse the repository at this point in the history
  • Loading branch information
SharkHunter committed Oct 19, 2013
1 parent 6019906 commit 791b0e6
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 4 deletions.
2 changes: 1 addition & 1 deletion src/com/sharkhunter/channel/ChannelMediaStream.java
Original file line number Diff line number Diff line change
Expand Up @@ -680,7 +680,7 @@ private void fixStuff(String str,boolean subs) {
} catch (FileNotFoundException e) {
return;
}
sub.setId(1);
sub.setId(101);
sub.setLang("und");
sub.setType(SubtitleType.SUBRIP);
media.container="unknown"; // avoid bug in mencvid
Expand Down
2 changes: 2 additions & 0 deletions src/com/sharkhunter/channel/ChannelNaviXProc.java
Original file line number Diff line number Diff line change
Expand Up @@ -812,6 +812,8 @@ public static String simple(String str,ArrayList<String> script,HashMap<String,S
if(script==null)
return str;
HashMap<String,String> res=lite(str,script,initStash,ch);
if(res == null)
return null;
return res.get("url");
}
}
2 changes: 1 addition & 1 deletion src/com/sharkhunter/channel/ChannelSubs.java
Original file line number Diff line number Diff line change
Expand Up @@ -482,7 +482,7 @@ public boolean langSupported() {
public String langPrefered() {
if(lang==null)
return null;
String[] langCode=PMS.getConfiguration().getMencoderSubLanguages().split(",");
String[] langCode=PMS.getConfiguration().getSubtitlesLanguages().split(",");
if(lang[0].equals("all"))
return langCode[0];
for(int j=0;j<langCode.length;j++)
Expand Down
4 changes: 2 additions & 2 deletions src/com/sharkhunter/channel/ChannelUtil.java
Original file line number Diff line number Diff line change
Expand Up @@ -191,7 +191,7 @@ public static boolean cookieContains(String cookie1,String cookie0) {
public static boolean downloadText(InputStream in,File f) throws Exception {
PmsConfiguration configuration=PMS.getConfiguration();
//String subtitleQuality = config.getMencoderVobsubSubtitleQuality();
String subcp=configuration.getMencoderSubCp();
String subcp=configuration.getSubtitlesCodepage();
OutputStreamWriter out=new OutputStreamWriter(new FileOutputStream(f),subcp);
InputStreamReader inn=new InputStreamReader(in);
char[] buf=new char[4096];
Expand Down Expand Up @@ -498,7 +498,7 @@ private static String addSubs(String rUrl,String sub,Channel ch,
//-spuaa 3 -subcp ISO-8859-10 -subfont C:\Windows\Fonts\Arial.ttf -subfont-text-scale 2 -subfont-outline 1 -subfont-blur 1 -subpos 90 -quiet -quiet -sid 100 -fps 25 -ofps 25 -sub C:\downloads\Kings Speech.srt -lavdopts fast -mc 0 -noskip -af lavcresample=48000 -srate 48000 -o \\.\pipe\mencoder1299956406082
PmsConfiguration configuration=PMS.getConfiguration();
//String subtitleQuality = config.getMencoderVobsubSubtitleQuality();
String subcp=configuration.getMencoderSubCp();
String subcp=configuration.getSubtitlesCodepage();
rUrl=append(rUrl,"&subcp=",escape(subcp));
rUrl=append(rUrl,"&subtext=",escape(configuration.getMencoderNoAssScale()));
rUrl=append(rUrl,"&subout=",escape(configuration.getMencoderNoAssOutline()));
Expand Down

0 comments on commit 791b0e6

Please sign in to comment.