Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6817137
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 26, 20262026-05-26T21:00:43+00:00 2026-05-26T21:00:43+00:00

I have an ogg vorbis file and I have to do two operations with

  • 0

I have an ogg vorbis file and I have to do two operations with it:

  1. Cutting a part of a file from one position to another
  2. Merging another file with existing one

How can I do these two operations in C#?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-26T21:00:44+00:00Added an answer on May 26, 2026 at 9:00 pm

    I’d look into the c documentation for libogg, and figure out how to do this with c. And then write almost the same code in C# using a wrapper over libogg.

    I’ve created a low level wrapper over libogg and libvorbis using the interop assistant:
    https://github.com/CodesInChaos/Xiph/blob/master/LowLevel.cs

    That project also contains some higher level constructs, but I don’t think they’ll be useful for what you’re doing.

    BTW if the stream IDs between the files differ, you can simply append a file to another creating a valid file that plays both streams in sequence.

    You probably need to read the input files packet wise using the decoding API, and then write the combined data out packet wise. Possibly replacing the stream ID and granulepos in between.

    StreamID is an integer that identifies substreams in an ogg file. To append multiple such substreams you can simply ensure that they have a different ID and then write the data.

    Splitting is a bit more annoying, since granulepos is a codec dependent timestamp, and I don’t remember how it is defined for vorbis. Another problem here is that you can’t simply split in the middle of a packet without reencoding.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have an ogg vorbis video. It plays fine in totem and mplayer. I
I want to convert .au file to .ogg file using shell. I have found
I have <video src=someServlet> where I write in servletOutputStream bytes from some video file,
I have a mkv file with webm video and ogg audio an ogg audio
I am looking for specifications for the ogg vorbis header packet format. I have
I have a terminal command which can display video frames from web camera as
I have two custom QML elements for audio, one for playing music (and extends
I am working in C++ with ogg/vorbis I have an array with raw PCM
I have to play an ogg audio file in the background when the user
I have .ogg files in res/raw, I have implemented a feature to save file

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.