How does OpenStreetMap store it's map data?

I'm woking in AutoCAD at work and I'm getting the feeling that if I were to store the OSM map data in AutoCAD it would be a huge file, yet the files I download in CoMaps are small with regards of how much data they contain.

#AskFedi #OSM #OpenStreetMap #AutoCAD #CAD #CoMaps
@spacebug Okay, there’s a lot to unpack here, and it might get lengthy. In short, you’re dealing with very different types of data. AutoCAD DWG (which is clunkier than DXF) isn’t really similar to how GIS information is stored, as it’s more like a JSON set.
@kkavee hum OK. To be fair I don't really know how AutoCAD stores it's data either, but it would seem that the same amount of data would be needed to a be stored?
Like a building or a road must have a few data points (x,y) and then maybe lines with a starting point and an ending point?

@spacebug a simple polyline in DWG is not just “a list of points.” It’s a structured object that stores explicit geometry, plus a ton of extra baggage

If you want none of the entire AutoCAD drawing environment, there is DXF = text-based interchange format. Think of DXF as the “CSV of CAD.”

@kkavee Yeah I've been saving to DXF sometimes for some purposes.
OK I didn't know that a polyline had such overhead, but now that you mention it, yeah it has things like z value, colour and more. I'll play around with it at work tomorrow.
Thanks 😃