Compare commits

..

No commits in common. "c05d0bbb44b054957cc9ee538202daec90157b6a" and "f139ab79e2e51d947168ff507c4ae772cd8d1c1b" have entirely different histories.

3 changed files with 10 additions and 13 deletions

View file

@ -155,7 +155,7 @@ async function loadEdit(id, args) {
} else {
var video = {}
var oshash = clip.streams[idx]
video.src = getVideoURL(clip.item, pandora.resolution, idx+1, '', oshash)
video.src = getVideoURL(clip.item, 480, idx+1, '', oshash)
/*
if (clip['in'] && clip.out) {
video.src += `#t=${clip['in']},${clip.out}`
@ -255,9 +255,9 @@ async function loadEdit(id, args) {
poster = getClip(data.edit, parseDuration(args.parts[2]))
}
if (poster && poster.item) {
data.poster = `${pandora.proto}://${data.site}/${poster.item}/${pandora.resolution}${poster.position.toFixed(3)}.jpg`
data.poster = `${pandora.proto}://${data.site}/${poster.item}/480p${poster.position}.jpg`
} else {
data.poster = data.videos[0].src.split('/48')[0] + `/${pandora.resolution}p${data.videos[0].in.toFixed(3)}.jpg`
data.poster = data.videos[0].src.split('/48')[0] + `/480p${data.videos[0].in}.jpg`
}
data.aspectratio = data.edit.clips[0].videoRatio
data.duration = data.edit.duration

View file

@ -106,7 +106,7 @@ async function loadData(id, args) {
data.videos = []
data.item.durations.forEach((duration, idx) => {
var oshash = data.item.streams[idx]
var url = getVideoURL(data.item.id, pandora.resolution, idx+1, '', oshash)
var url = getVideoURL(data.item.id, 480, idx+1, '', oshash)
data.videos.push({
src: url,
duration: duration
@ -130,13 +130,11 @@ async function loadData(id, args) {
${layerData.title}
</h3>`)
data.layers[layer].forEach(annotation => {
if (pandora.url) {
annotation.value = annotation.value.replace(
/src="\//g, `src="${pandora.url.origin}/`
).replace(
/href="\//g, `href="${pandora.url.origin}/`
)
}
annotation.value = annotation.value.replace(
/src="\//g, `src="${pandora.url.origin}/`
).replace(
/href="\//g, `href="${pandora.url.origin}/`
)
html.push(`
<div class="annotation ${layerData.type}" data-in="${annotation.in}" data-out="${annotation.out}">
${annotation.value}
@ -163,7 +161,7 @@ async function loadData(id, args) {
data.byline += ' (' + data.item.date.split('-')[0] + ')'
}
data.link = `${pandora.proto}://${data.site}/${data.item.id}/${data["in"]},${data.out}`
data.poster = `${pandora.proto}://${data.site}/${data.item.id}/${pandora.resolution}p${data["in"]}.jpg`
data.poster = `${pandora.proto}://${data.site}/${data.item.id}/480p${data["in"]}.jpg`
data.aspectratio = data.item.videoRatio
if (data['in'] == data['out']) {
data['out'] += 0.04

View file

@ -100,7 +100,6 @@ pandoraAPI("init").then(response => {
...response.data
}
pandora.proto = pandora.site.site.https ? 'https' : 'http'
pandora.resolution = Math.max.apply(null, pandora.site.video.resolutions)
if (pandora.site.site.videoprefix.startsWith('//')) {
pandora.site.site.videoprefix = pandora.proto + ':' + pandora.site.site.videoprefix
}