Skip to content

Commit

Permalink
Fix trimming from the start (#177)
Browse files Browse the repository at this point in the history
  • Loading branch information
sindresorhus authored Feb 5, 2020
1 parent d884f3d commit b0932b4
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion Gifski/Gifski.swift
Original file line number Diff line number Diff line change
Expand Up @@ -253,7 +253,7 @@ final class Gifski {
bytesPerRow: UInt32(image.bytesPerRow),
height: UInt32(image.height),
pixels: buffer,
presentationTimestamp: result.actualTime.seconds
presentationTimestamp: max(0, result.actualTime.seconds - startTime)
)
} catch {
completionHandlerOnce(.failure(.addFrameFailed(error)))
Expand Down

0 comments on commit b0932b4

Please # to comment.