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

Is there any way to tell where in the file the reader is ? #456

Open
JulianDicken opened this issue Nov 27, 2024 · 0 comments
Open

Is there any way to tell where in the file the reader is ? #456

JulianDicken opened this issue Nov 27, 2024 · 0 comments

Comments

@JulianDicken
Copy link

JulianDicken commented Nov 27, 2024

Title basically is the question. I need a way to know where in the file the reader is. Ideally id want the file offset (in bytes) of the current record, as well as where that record "ends". I have not found a way of doing this with the high level record reader but I think I have found a way to do this with the lower level htslib module via the htslib::bgzf_utell function. With this function I do manage to get a buffer of the record's data out but I dont know how to decompress that buffer (if it is compressed that is, if it isn't I am getting garbage out).

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

No branches or pull requests

1 participant