Well the 6 hours would be with no traffic going out of LA and that really depends on the day you would be leaving LA and the time.
I have driven from Disneyland to my house in Fresno (where you would be driving through) in four hours. And I know it is 2 hours to Yosemite from my house. However, many times it has taken me 5 hours or so to get home from Disneyland because of traffic.
And I am talking
2 hours from my house to the Valley floor, which is an important distinction. Because the gates to Yosemite are only an hour away from me. It takes an hour to get from the gates to the Valley floor.
I don't think you would really save that much time by flying into San Francisco or San Jose. As others have said, it is still a 4 hour drive anyway from there and then add on the flying time, time to get to the airport, baggage, and rental counter
.
I would leave Disneyland on a Sunday if at all possible (least amount of traffic in my experience). If you can't do Sunday, then avoid any proximity to rush hour. Once you get out of the LA area, the freeway is very fast (70 mph speed limit). I know a lot of people hate the drive, but since I grew up in the Central Valley, I kind of like driving in the ag areas. And Yosemite is totally worth it!
Seriously, I have taken people who are not even "nature people" and they can't believe the beauty. If you can make it work, do it!
Feel free to PM if you would like dinner/lunch recos in Fresno. It is also a good place to stop if you need to get food, etc if you are camping. They really do scalp the tourists the further up the hills you go.