[Addon] Blendshare - Image Sharing

Download: http://www.rymdnisse.net/download/blender-addons/blendshare/

Short Description:
Blendshare is a free addon which allows you to upload renders, screenshots and GIFs, all with the click of a button. When taking screenshots you can also chose to crop and draw over it. Blendshare currently supports Imgur, Dropbox, Google Drive and Twitter.

If you find any bugs or have any suggestions for future updates, I’d love to hear them! :slight_smile:

Thanks, looks really useful and handy.
Surely somewhere it should be put username and password to those sites, right? I guess the first question would be about how safe it is that.
And as feature request, maybe also could support image sharing sites that do not require user and password?:

Maybe someone knows even better sites that those above.

Thanks a bunch! This will be really helpful (And thanks to the source, I finally know how to save a GIF from Python :yes:).

The Imgur feature is free and does not need you to login or authorize the app.

However the rest, Dropbox, Google Drive and Twitter does require accounts in order to upload. The addon uses OAuth2, so Blendshare will never be in contact/be able to read your password. Instead you login through the official site e.g. drobox.com and verify the app for your account there, looks like this: https://i.gyazo.com/e7709e6da7bd0732cf84ab0f03ea7e51.png

Blendshare will then receive an access token which is used connect and upload to your account.

However, even though it can’t read your password it isn’t necessarily safe. Blendshare can still access your files/folders and other personal information such as email, username and name through this access token.
So I guess what it comes down to is how much you trust the app/developer (in this case me). So yeah, if you’re not comfortable allowing Blendshare access to any of your accounts, you can still use the addon with Imgur.

I can’t really provide any proof (except the source code if you feel like going through all that :P), but I can give you my word that it’s not doing anything shady, and will only upload images. The information Blendshare will collect from you when you link your account is:

Dropbox: Your name and email
Google Drive: Your name and email
Twitter: Your Twitter handle

These are collected for display purpose only, to show what account you’ve linked: http://i.imgur.com/01XqlDp.png
This information is stored on your local hard-drive wherever you have the addon installed, in a folder name “user_info”.

Anyway, I could take a look at those other 2 sites you sent me as well, see if they have any advantages over Imgur :slight_smile:

Best Regards,
Nils Söderman

Awesome, hopefully you where able to make some sense out of my code, I didn’t leave many comments and it’s a bit messy :stuck_out_tongue:
But yeah, I used the library imageio: https://pypi.python.org/pypi/imageio
A bit slow at stitching together longer GIFs, but quite handy otherwise :slight_smile:

awesome stuff man ,
and we do not have to do that access token thing if dropbox app is installed , and i like that ,

now uploading images to paste all would be a better a idea too

other then that … you can add ability to create post for blender artist’s threads directly from blender haha :slight_smile:

awesome job man keep it up

@rymdnisse, thanks for the detailed answer.
I did not know about that Imgur not require login.

Actually those two sites I had mentioned are quite limited, I only was giving as an example. I’ll try Imgur.

Thank you.

I’m getting the following error in Kubuntu Linux 14.04 when I click button “stop recording” (gif):

Traceback (most recent call last):
  File "/home/yafu/.config/blender/2.77/scripts/addons/Blendshare/source.py", line 1397, in execute
    GIF_stop_recording(self, context)
  File "/home/yafu/.config/blender/2.77/scripts/addons/Blendshare/source.py", line 1354, in GIF_stop_recording
    images.append(imageio.imread(os.path.join(screencastdir, filename)))
  File "/home/yafu/.config/blender/2.77/scripts/addons/Blendshare/imageio/core/functions.py", line 181, in imread
    reader = read(uri, format, 'i', **kwargs)
  File "/home/yafu/.config/blender/2.77/scripts/addons/Blendshare/imageio/core/functions.py", line 111, in get_reader
    return format.get_reader(request)
  File "/home/yafu/.config/blender/2.77/scripts/addons/Blendshare/imageio/core/format.py", line 158, in get_reader
    return self.Reader(self, request)
  File "/home/yafu/.config/blender/2.77/scripts/addons/Blendshare/imageio/core/format.py", line 207, in __init__
  File "/home/yafu/.config/blender/2.77/scripts/addons/Blendshare/imageio/plugins/freeimage.py", line 281, in _open
    return FreeimageFormat.Reader._open(self, flags)
  File "/home/yafu/.config/blender/2.77/scripts/addons/Blendshare/imageio/plugins/freeimage.py", line 80, in _open
  File "/home/yafu/.config/blender/2.77/scripts/addons/Blendshare/imageio/plugins/_freeimage.py", line 811, in load_from_filename
ValueError: Could not load bitmap "/tmp/Blendshare_Screencast/frame0014.jpg": Wrong JPEG library version: library is 62, caller expects 80

location: <unknown location>:-1

and then blender automatically toggle to full screen.
I have installed libjpeg62 and a package called libjpeg-turbo8 that install libjpeg.so.8 and libjpeg.so.8.0.2

I am excited to try your add-on, rymdnisse!

I havn’t already make the same type of add-on here: LINK

Useful plugin!
Thank you!
Can you upload your code to github?

@ YAFU I would install libfreeimage using Synaptic and change line in script to reflect the library which i have on my system.
This page mentions error is caused by library mismatch. You might have programs which still use old libjpeg; good if there is backwards compatibility, if not, remove as suggested there might break things up.

Thanks eppo.
That has not worked for me, I do not know if I’ve done something wrong. I even uninstalled libjpeg62 but Blender continues giving the same error message.