chore(multisrc/pt): Remove CineVision (#1968)
This commit is contained in:
@ -1,4 +0,0 @@
|
||||
dependencies {
|
||||
implementation(project(":lib-streamlare-extractor"))
|
||||
implementation("dev.datlag.jsunpacker:jsunpacker:1.0.1")
|
||||
}
|
Binary file not shown.
Before Width: | Height: | Size: 1.8 KiB |
Binary file not shown.
Before Width: | Height: | Size: 1.3 KiB |
Binary file not shown.
Before Width: | Height: | Size: 3.1 KiB |
Binary file not shown.
Before Width: | Height: | Size: 4.8 KiB |
Binary file not shown.
Before Width: | Height: | Size: 6.6 KiB |
Binary file not shown.
Before Width: | Height: | Size: 21 KiB |
@ -1,82 +0,0 @@
|
||||
package eu.kanade.tachiyomi.animeextension.pt.cinevision
|
||||
|
||||
import eu.kanade.tachiyomi.animeextension.pt.cinevision.extractors.EmbedflixExtractor
|
||||
import eu.kanade.tachiyomi.animeextension.pt.cinevision.extractors.VidmolyExtractor
|
||||
import eu.kanade.tachiyomi.animesource.model.Video
|
||||
import eu.kanade.tachiyomi.lib.streamlareextractor.StreamlareExtractor
|
||||
import eu.kanade.tachiyomi.multisrc.dooplay.DooPlay
|
||||
import eu.kanade.tachiyomi.network.POST
|
||||
import eu.kanade.tachiyomi.util.asJsoup
|
||||
import okhttp3.FormBody
|
||||
import okhttp3.Response
|
||||
import org.jsoup.nodes.Element
|
||||
import uy.kohesive.injekt.api.get
|
||||
|
||||
class CineVision : DooPlay(
|
||||
"pt-BR",
|
||||
"CineVision",
|
||||
"https://cinevisionv3.online",
|
||||
) {
|
||||
// ============================== Popular ===============================
|
||||
override fun popularAnimeSelector(): String = "article.w_item_b > a"
|
||||
|
||||
// =============================== Latest ===============================
|
||||
override val latestUpdatesPath = "episodios"
|
||||
|
||||
override fun latestUpdatesNextPageSelector(): String = "div.resppages > a > span.fa-chevron-right"
|
||||
|
||||
// ============================ Video Links =============================
|
||||
override fun videoListParse(response: Response): List<Video> {
|
||||
val document = response.asJsoup()
|
||||
val players = document.select("ul#playeroptionsul li")
|
||||
return players.flatMap(::getPlayerVideos)
|
||||
}
|
||||
|
||||
private fun getPlayerVideos(player: Element): List<Video> {
|
||||
val name = player.selectFirst("span.title")!!.text()
|
||||
val url = getPlayerUrl(player)
|
||||
return when {
|
||||
"vidmoly.to" in url ->
|
||||
VidmolyExtractor(client).getVideoList(url, name)
|
||||
"streamlare.com" in url ->
|
||||
StreamlareExtractor(client).videosFromUrl(url, name + " -")
|
||||
"embedflix.in" in url ->
|
||||
EmbedflixExtractor(client).videosFromUrl(url)
|
||||
else -> emptyList<Video>()
|
||||
}
|
||||
}
|
||||
|
||||
private fun getPlayerUrl(player: Element): String {
|
||||
val body = FormBody.Builder()
|
||||
.add("action", "doo_player_ajax")
|
||||
.add("post", player.attr("data-post"))
|
||||
.add("nume", player.attr("data-nume"))
|
||||
.add("type", player.attr("data-type"))
|
||||
.build()
|
||||
|
||||
return client.newCall(POST("$baseUrl/wp-admin/admin-ajax.php", headers, body))
|
||||
.execute()
|
||||
.use { response ->
|
||||
response.body.string()
|
||||
.substringAfter("\"embed_url\":\"")
|
||||
.substringBefore("\",")
|
||||
.replace("\\", "")
|
||||
.let { url ->
|
||||
when {
|
||||
url.contains("iframe") -> {
|
||||
url.substringAfter(" src=\"")
|
||||
.substringBefore("\" ")
|
||||
.let { "https:$it" }
|
||||
}
|
||||
|
||||
else -> url
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// ============================= Utilities ==============================
|
||||
override val animeMenuSelector = "div.pag_episodes div.item a[href] i.fa-bars"
|
||||
|
||||
override val genresListMessage = "Categoria"
|
||||
}
|
@ -1,36 +0,0 @@
|
||||
package eu.kanade.tachiyomi.animeextension.pt.cinevision.extractors
|
||||
|
||||
import dev.datlag.jsunpacker.JsUnpacker
|
||||
import eu.kanade.tachiyomi.animesource.model.Video
|
||||
import eu.kanade.tachiyomi.network.GET
|
||||
import eu.kanade.tachiyomi.util.asJsoup
|
||||
import okhttp3.OkHttpClient
|
||||
|
||||
class EmbedflixExtractor(private val client: OkHttpClient) {
|
||||
fun videosFromUrl(url: String): List<Video> {
|
||||
val newUrl = url.replace("/e/", "/api.php?action=getAds&key=0&lang=DUB&s=")
|
||||
val iframeUrl = client.newCall(GET(newUrl)).execute()
|
||||
.use { it.asJsoup() }
|
||||
.selectFirst("iframe")
|
||||
?.attr("src") ?: return emptyList()
|
||||
|
||||
val playerData = client.newCall(GET(iframeUrl)).execute()
|
||||
.use { it.body.string() }
|
||||
.let(JsUnpacker::unpackAndCombine)
|
||||
?: return emptyList()
|
||||
|
||||
val masterUrl = playerData.substringAfter("file:\"").substringBefore('"')
|
||||
|
||||
val playlistData = client.newCall(GET(masterUrl)).execute()
|
||||
.use { it.body.string() }
|
||||
|
||||
val separator = "#EXT-X-STREAM-INF:"
|
||||
return playlistData.substringAfter(separator).split(separator).map {
|
||||
val quality = it.substringAfter("RESOLUTION=")
|
||||
.substringAfter("x")
|
||||
.substringBefore(",") + "p"
|
||||
val videoUrl = it.substringAfter("\n").substringBefore("\n")
|
||||
Video(videoUrl, "EmbedFlix(DUB) - $quality", videoUrl)
|
||||
}
|
||||
}
|
||||
}
|
@ -1,29 +0,0 @@
|
||||
package eu.kanade.tachiyomi.animeextension.pt.cinevision.extractors
|
||||
|
||||
import eu.kanade.tachiyomi.animesource.model.Video
|
||||
import eu.kanade.tachiyomi.network.GET
|
||||
import okhttp3.Headers
|
||||
import okhttp3.OkHttpClient
|
||||
|
||||
class VidmolyExtractor(private val client: OkHttpClient) {
|
||||
|
||||
private val regexPlaylist = Regex("file:\"(\\S+?)\"")
|
||||
|
||||
fun getVideoList(url: String, lang: String): List<Video> {
|
||||
val body = client.newCall(GET(url)).execute()
|
||||
.use { it.body.string() }
|
||||
val playlistUrl = regexPlaylist.find(body)!!.groupValues.get(1)
|
||||
val headers = Headers.headersOf("Referer", "https://vidmoly.to")
|
||||
val playlistData = client.newCall(GET(playlistUrl, headers)).execute()
|
||||
.use { it.body.string() }
|
||||
|
||||
val separator = "#EXT-X-STREAM-INF:"
|
||||
return playlistData.substringAfter(separator).split(separator).map {
|
||||
val quality = it.substringAfter("RESOLUTION=")
|
||||
.substringAfter("x")
|
||||
.substringBefore(",") + "p"
|
||||
val videoUrl = it.substringAfter("\n").substringBefore("\n")
|
||||
Video(videoUrl, "$lang - $quality", videoUrl, headers)
|
||||
}
|
||||
}
|
||||
}
|
@ -19,7 +19,6 @@ class DooPlayGenerator : ThemeSourceGenerator {
|
||||
SingleLang("Animes Grátis", "https://animesgratis.org", "pt-BR", className = "AnimesGratis", isNsfw = false, overrideVersionCode = 1),
|
||||
SingleLang("Animes House", "https://animeshouse.net", "pt-BR", isNsfw = false, overrideVersionCode = 5),
|
||||
SingleLang("Cinemathek", "https://cinemathek.net", "de", isNsfw = true, overrideVersionCode = 13),
|
||||
SingleLang("CineVision", "https://cinevisionv3.online", "pt-BR", isNsfw = true, overrideVersionCode = 5),
|
||||
SingleLang("DonghuaX", "https://donghuax.com", "pt-BR", isNsfw = false),
|
||||
SingleLang("GoAnimes", "https://goanimes.net", "pt-BR", isNsfw = true, overrideVersionCode = 2),
|
||||
SingleLang("JetAnime", "https://ssl.jetanimes.com", "fr", isNsfw = false),
|
||||
|
Reference in New Issue
Block a user