• Benny Siegert's avatar
    image/tiff: decoder optimization. · 64c9c7f5
    Benny Siegert authored
    Write to image.*.Pix directly in the case of RGB, RGBA and NRGBA
    images. For the latter two, the file format matches the memory layout
    so a simple copy can be used.
    
    RGB image before/after:
    tiff.BenchmarkDecoder	748137 ns/op (62.39 MB/s)	251256 ns/op (185.76 MB/s)	x3.0
    
    NRGBA image before/after:
    tiff.BenchmarkDecoder	775540 ns/op (80.12 MB/s)	116721 ns/op (532.34 MB/s)	x6.6
    
    R=nigeltao
    CC=golang-dev
    https://golang.org/cl/4929046
    64c9c7f5
Name
Last commit
Last update
..
testdata Loading commit data...
Makefile Loading commit data...
buffer.go Loading commit data...
buffer_test.go Loading commit data...
consts.go Loading commit data...
reader.go Loading commit data...
reader_test.go Loading commit data...