Skip to content

use stb_image.h's stbi_load func to read Image, the data format is HWC or CHW? #1285

Answered by nothings
zjykzj asked this question in Q&A
Discussion options

You must be logged in to vote

Line 153 of stb_image.h:

// The pixel data consists of *y scanlines of *x pixels,
// with each pixel consisting of N interleaved 8-bit components; the first
// pixel pointed to is top-left-most in the image. There is no padding between
// image scanlines or between pixels, regardless of format.

Replies: 1 comment 2 replies

Comment options

You must be logged in to vote
2 replies
@zjykzj
Comment options

@nothings
Comment options

Answer selected by zjykzj
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants
Converted from issue

This discussion was converted from issue #1284 on February 16, 2022 09:42.