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

UndefVarError bits_per_pixel when transforming to gray during decoding #313

Closed
Octogonapus opened this issue Apr 7, 2021 · 0 comments · Fixed by #314
Closed

UndefVarError bits_per_pixel when transforming to gray during decoding #313

Octogonapus opened this issue Apr 7, 2021 · 0 comments · Fixed by #314

Comments

@Octogonapus
Copy link

Octogonapus commented Apr 7, 2021

When opening a raw Gray video in Gray color space, the Gray transform block of VideoReader results in an UndefVarError:

ERROR: LoadError: UndefVarError: bits_per_pixel not defined
Stacktrace:
 [1] VideoIO.VideoReader(avin::VideoIO.AVInput{String}, video_stream::Int64; transcode::Bool, target_format::Int32, pix_fmt_loss_flags::Int64, target_colorspace_details::Nothing, allow_vio_gray_transform::Bool, swscale_options::NamedTuple{(), Tuple{}}, sws_color_options::NamedTuple{(), Tuple{}})
   @ VideoIO ~/.julia/packages/VideoIO/B6VOI/src/avio.jl:311
 [2] #VideoReader#19
   @ ~/.julia/packages/VideoIO/B6VOI/src/avio.jl:339 [inlined]
 [3] #openvideo#20
   @ ~/.julia/packages/VideoIO/B6VOI/src/avio.jl:588 [inlined]

The video is opened in this way:

VideoIO.openvideo(video_path, target_format = VideoIO.AV_PIX_FMT_GRAY8)

Video description from ffmpeg:

Input #0, avi, from 'video.avi':
  Metadata:
    encoder         : Lavf54.35.100
  Duration: 00:00:26.52, start: 0.000000, bitrate: 629158 kb/s
    Stream #0:0: Video: rawvideo (Y800 / 0x30303859), gray, 1280x1024, 629541 kb/s, 60 fps, 60 tbr, 60 tbn, 60 tbc

I am using VideoIO v0.9.1 and Julia v1.6.0.

This was referenced Apr 7, 2021
@Octogonapus Octogonapus changed the title UndefVarError bits_per_pixel when transforming from color to gray during decoding UndefVarError bits_per_pixel when transforming to gray during decoding Apr 7, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant