Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Can we filter searches by duration/movie length? #50

Open
LucidEye opened this issue Oct 5, 2015 · 4 comments
Open

Can we filter searches by duration/movie length? #50

LucidEye opened this issue Oct 5, 2015 · 4 comments
Labels
enhancement Feature requests

Comments

@LucidEye
Copy link

LucidEye commented Oct 5, 2015

Hello, I don't know if this is the proper place to ask this, could not find any other places to contact the devs of this great addon...

Is there any way of filtering out all the short length clips when I search sites in VideoDevil? I am really not interested in all the 1-5 minute clips that seem to dominate any searches. I want to be able to filter out anything under 20 minutes, OR be able to display search results by longest clip first (length of clip in descending order)
If this is something I can modify in the code somewhere please let me know what it is, because I can not seem to find such a filter option anywhere in the GUI or addon settings.

Thank you.

@mrdougquaid mrdougquaid added the enhancement Feature requests label Jan 8, 2016
@xbmc-adult xbmc-adult deleted a comment from LucidEye May 4, 2018
@mrdougquaid
Copy link
Contributor

This feature request will only be implemented if someone volunteers to do so. I have no interest in implementing this.
I deleted your previous comment as it was not relevant to this issue. Use the forum for questions

@Gujal00
Copy link
Contributor

Gujal00 commented Jan 8, 2019

This depends on the site, some sites provide Sorting based on Longest, most viewd, etc. Cannot be done on all sites. AFAIK It has been done where possible

@LucidEye
Copy link
Author

LucidEye commented Jan 8, 2019 via email

@FAlbanni
Copy link

FAlbanni commented Nov 12, 2019

Beware: I didn't try this and it might not even work at all.

I can totally relate to you, when I want to fap in peace away from the world I experiment the same annoyance as you, all the sites are full of spam-bot videos of 10 seconds or less, is really infuriating!
For that sole reason I wrote this code for you, it should probably work but I didn't test it, actually to say the truth I wrote it on my cellphone in the bathroom, so no warranties of anything.

STEPS

  • open the videodevil.py file

  • search for this "elif m_type.find('video') != -1:"

  • delete the elif statement and replace it with this:

remember to edit this at your convenience, I set it to more than 5 minutes , but you can set it to whatever you want, just modify the value after:
#specify in minutes the minimum length

                elif m_type.find('video') != -1:
                    #specify in minutes the minimum length
                    minlength = 3
                    #don't touch anything else
                    videoLength = re.search('\(([^()]*)\)$', m_title)
                    if(videoLength is not None):
                        videoLength = videoLength.group(1)
                        videoLength = videoLength.split(":")
                    
                        if(int(len(videoLength))>2 or int(videoLength[0])>=minlength):
                            self.addListItem(m_title,
                                            self.currentlist.codeUrl(m, 'videodevil'),
                                            m_icon,
                                            len(self.currentlist.items),
                                            m)
                    else:
                        self.addListItem(m_title,
                                            self.currentlist.codeUrl(m, 'videodevil'),
                                            m_icon,
                                            len(self.currentlist.items),
                                            m)

Let me know if it works, if so thanks me latter and happy fapping!


EDIT

I tried it and it seems to work OK, I also added an option to set the minimum length to a desired value instead of having it hardcoded in the source.

It looks like this:
screenshot001

You can download my modified version (1.7.237) with the feature here:
https://github.com/FAlbanni/videoDevilCustom

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement Feature requests
Projects
None yet
Development

No branches or pull requests

4 participants