Skip to content
This repository has been archived by the owner on Mar 16, 2021. It is now read-only.

BUGFIX: EXC_BAD_ACCESS during CGContextDrawImage #46

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Commits on Jul 1, 2020

  1. BUGFIX: EXC_BAD_ACCESS during CGContextDrawImage

    Why it happened? In my case the image was 500 pixels width but:
    
      NSUInteger width = 500
      NSUInteger bytesPerPixel = 4
      NSUInteger bytesPerRow = 2016
    
    Because the image took 2016 bytes per row instead of 2000 we need
    to allocate more memory for the "imageData" array.
    Alex Malko committed Jul 1, 2020
    Configuration menu
    Copy the full SHA
    9d12af0 View commit details
    Browse the repository at this point in the history