جَاءَ طَلْحَةُ — Ṭalḥah came. طَلْحَةُ is the subject fāʿil, nominative with visible ḍamma.
رَأَيْتُ طَلْحَةَ — I saw Ṭalḥah. طَلْحَةَ is the direct object, accusative with visible fatḥa.
مَرَرْتُ بِطَلْحَةَ — I passed by Ṭalḥah. After the preposition بِ, طَلْحَةَ is genitive with fatḥa in place of kasra because it is a diptote.