mirror of
https://github.com/zoriya/Kyoo.git
synced 2025-07-09 03:04:20 -04:00
commit
b0f1dc7721
@ -86,7 +86,7 @@ func (fs *FileStream) GetMaster() string {
|
||||
master += "DEFAULT=YES,"
|
||||
}
|
||||
master += "CHANNELS=\"2\","
|
||||
master += fmt.Sprintf("URI=\"./audio/%d/index.m3u8\"\n", audio.Index)
|
||||
master += fmt.Sprintf("URI=\"audio/%d/index.m3u8\"\n", audio.Index)
|
||||
}
|
||||
master += "\n"
|
||||
|
||||
@ -131,7 +131,7 @@ func (fs *FileStream) GetMaster() string {
|
||||
if video == *def_video {
|
||||
master += "DEFAULT=YES\n"
|
||||
} else {
|
||||
master += fmt.Sprintf("URI=\"./%d/%s/index.m3u8\"\n", video.Index, quality)
|
||||
master += fmt.Sprintf("URI=\"%d/%s/index.m3u8\"\n", video.Index, quality)
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -149,7 +149,7 @@ func (fs *FileStream) GetMaster() string {
|
||||
}
|
||||
master += "AUDIO=\"audio\","
|
||||
master += "CLOSED-CAPTIONS=NONE\n"
|
||||
master += fmt.Sprintf("./%d/%s/index.m3u8\n", def_video.Index, Original)
|
||||
master += fmt.Sprintf("%d/%s/index.m3u8\n", def_video.Index, Original)
|
||||
}
|
||||
|
||||
aspectRatio := float32(def_video.Width) / float32(def_video.Height)
|
||||
@ -167,7 +167,7 @@ func (fs *FileStream) GetMaster() string {
|
||||
master += fmt.Sprintf("CODECS=\"%s\",", strings.Join([]string{transmux_codec, audio_codec}, ","))
|
||||
master += "AUDIO=\"audio\","
|
||||
master += "CLOSED-CAPTIONS=NONE\n"
|
||||
master += fmt.Sprintf("./%d/%s/index.m3u8\n", def_video.Index, quality)
|
||||
master += fmt.Sprintf("%d/%s/index.m3u8\n", def_video.Index, quality)
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -37,7 +37,12 @@ func (kf *Keyframe) Slice(start int32, end int32) []float64 {
|
||||
}
|
||||
kf.info.mutex.RLock()
|
||||
defer kf.info.mutex.RUnlock()
|
||||
|
||||
ref := kf.Keyframes[start:end]
|
||||
if kf.IsDone {
|
||||
return ref
|
||||
}
|
||||
// make a copy since we will continue to mutate the array.
|
||||
ret := make([]float64, end-start)
|
||||
copy(ret, ref)
|
||||
return ret
|
||||
|
@ -83,8 +83,8 @@ func (s *MetadataService) GetMetadata(path string, sha string) (*MediaInfo, erro
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
tx.Exec(`update videos set keyframes = nil where sha = $1`, sha)
|
||||
tx.Exec(`update audios set keyframes = nil where sha = $1`, sha)
|
||||
tx.Exec(`update videos set keyframes = null where sha = $1`, sha)
|
||||
tx.Exec(`update audios set keyframes = null where sha = $1`, sha)
|
||||
tx.Exec(`update info set ver_keyframes = 0 where sha = $1`, sha)
|
||||
err = tx.Commit()
|
||||
if err != nil {
|
||||
|
Loading…
x
Reference in New Issue
Block a user