private MMC() { prefs = MMC_KEY + '/'; lastEncoderName = Sage.get(prefs + LAST_ENCODER_NAME, ""); featureMaskDisable = Sage.getInt(prefs + FEATURE_MASK_DISABLE, 0); capDevMgrs = new java.util.ArrayList(); globalEncoderMap = new java.util.HashMap(); if (Sage.EMBEDDED) { // Be sure the video format properties are sync'd properly if ("PAL".equals(Sage.get("TV_STANDARD", null)) && isNTSCVideoFormat()) Sage.putInt(prefs + VIDEO_FORMAT_CODE, 8); } }
public boolean isProviderUsed(long providerID) { if (getInputForProvider(providerID) != null) return true; if (Sage.getBoolean("mmc/retain_lineups_for_lost_devices", true)) { // go through all the properties manually and see if there's an encoder using this // provider because that encoder might just be offline for now String[] encoderKeys = Sage.childrenNames(prefs + CaptureDevice.ENCODERS + '/'); for (int i = 0; i < encoderKeys.length; i++) { String[] sourceConfigs = Sage.childrenNames(prefs + CaptureDevice.ENCODERS + '/' + encoderKeys[i] + '/'); for (int j = 0; j < sourceConfigs.length; j++) { String[] crossIndexes = Sage.childrenNames( prefs + CaptureDevice.ENCODERS + '/' + encoderKeys[i] + '/' + sourceConfigs[j] + '/'); for (int k = 0; k < crossIndexes.length; k++) { long testProvider = Sage.getLong( prefs + CaptureDevice.ENCODERS + '/' + encoderKeys[i] + '/' + sourceConfigs[j] + '/' + crossIndexes[k] + "/provider_id", 0); if (testProvider == providerID) return true; } } } } return false; }
public boolean openInputPlugin(SageTVInputCallback callback) { evtRtr = callback; if (!setupPVR150Input(Sage.getInt("linux/ir_input_pvr150", 0))) return false; InputThread = new Thread( new Runnable() { public void run() { PVR150Input.this.PVR150InputThread(Sage.getInt("linux/ir_input_pvr150", 0), evtRtr); } }, "PVR150Input"); InputThread.setDaemon(true); // If this is too low in priority we can miss // the repeat timing of a button press, so we need // accurate timing here to some degree. InputThread.setPriority(Thread.MAX_PRIORITY - 3); InputThread.start(); return true; }
public long getMediaTimeMillis() { return Sage.time(); }
public long seek(long seekTimeMillis) throws PlaybackException { return Sage.time(); }
public boolean useMpeg4InMpeg2() { return Sage.getBoolean(prefs + "enable_mpeg4_timeshifting", true); }
public int getVideoFormatCode() { return Sage.getInt(prefs + VIDEO_FORMAT_CODE, 0); }
public int getCountryCode() { return Sage.getInt(prefs + COUNTRY_CODE, 0); }