How do I filter a view by the results of hook_node_access?
The problem here is that hook_node_access is a PHP function that has nodes passed through it, but Views is doing a database query for the relevant nodes. These two are incompatible, as Views would have to fetch every node in the system from the DB, then pass them all through that function, which would add major overhead.

Drupal's solution to this is the node grants system, which writes a set of grants to the {node_access} table, which can then be used in querying nodes.

To implement a grants system, you'll need to implement hook_node_access_records(), which is called when each node is saved, and sets up a number of rules by which the node being save is allowed to be accessed. Then you implement hook_node_grants(), which generates a set of potential grants for the current user, and tries to match them with the grants created in hook_node_access_records(). When there is a match, the user is granted permission to access, and this will work with DB queries.