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

changing image.format to (pjpeg) and saving creates an Segmentation fault #150

Closed
nbari opened this issue Sep 12, 2013 · 1 comment
Closed
Labels

Comments

@nbari
Copy link

nbari commented Sep 12, 2013

While using the following code and trying to save the image as an progressive jpg i get a Segmentation fault (core dumped)

from wand.image import Image
from wand.color import Color


gw = 1280
gh = 720
color = '#000000'

img_file = 'tiger_hd-1920x1080.jpg'

with Image(background=Color('black'), width=gw, height=gh) as bg_image:
    with Image(filename=img_file) as image:
        s = image.size
        print 'w: %s, h: %s' % (s[0], s[1])
        image.transform(resize='1280x720>')
        bg_image.composite(
            image,
            (bg_image.width - image.width) / 2,
            (bg_image.height - image.height) / 2)
        bg_image.format = 'pjpeg'
        with open('out.jpg', 'wb') as f:
            bg_image.save(file=f)

tiger_hd-1920x1080

@dahlia dahlia closed this as completed in 28872ae Sep 12, 2013
@dahlia
Copy link
Collaborator

dahlia commented Sep 12, 2013

Okay, it’s just fixed, and I also released Wand 0.3.5 which contains a quickfix for this.

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

No branches or pull requests

2 participants