There's 2 different categories for this, easy to use with limited control over the result or harder to use with full control over everything.
In the easy to use category, you have Megui and handbrake which are the 2 I see most often mentioned and they are pretty good at what they do from what I know of them.
In the harder to use, you have avisynth combined with other software(which is what I personally use), depending on what you want. You have to write a simple script to load your video and/or audio and do the processing you need. There's a ton of plugin to do pretty much anything you want and the quality of most is on par with professional tools, but since it's scripting and you then have to use an encoder which is most likely to be command line only, it's not always the easiest thing to begin with.
My usual work flow is as follow: create a basic avisynth script to load the video, open the script(like if it's were a video file) with virtualdub so I can watch the result and to know which filters I need to apply, encode the video using x264 by using the script as source, then encode the audio to aac by using the same script as source(so it's cut in the right places if I cut some part of the original video) and finally mux the video and audio files(and sometimes also a chapter file that I manually create using a text editor) inside an mkv using mkvtoolnix(or you could use mp4box if you prefer an mp4).
You also have MeguIVit which is a bit in the middle. It's a modified version of Megui(which makes use of avisynth internally) but with presets made specifically for IV and JAV so it's pretty easy to make a very high quality rip using it. You may run into a problem or two to get it started, but once it's set up properly, you're golden.
Here's a recent post with an up-to-date link for the files:
https://www.akiba-online.com/thread...d-encoder-v1-0-1-1.73866/page-50#post-2718024
You'll also want to read the following posts to update the x264 version in it since it's quite dated now and also the first post to learn the basics, the pictorial guide is for an ameliorated version so if something is different between the two, the pictorial guide takes precedence.