Introduction to my answer
The subject of PTSD and its triggers is huge, and this answer is not an alternative, but an addition to @Fizz's good answer to this question.
The causes of PTSD @Fizz talked about are through prolonged timeframes of trauma (sensitisation through fear conditioning coming into play over a long period of time). This can involve soldiers who have been in combat situations whereby they have constantly witnessed attrocities, but not necessarily.
PTSD can also occur with hypersensitisation caused by a single instance of an initial sensitising event (ISE), again such as a particular event in combat, or through other physical violence with perceived or actual threat to life or physical wellbeing.
Desensitisation will be the process involved to resolve the hypersensitisation effects caused by the ISE and subsequent neurological and biological reactions to the ISE.
So to your question in summary
What determines whether repeated exposure to something sensitizes someone or desensitizes them?
Sensitisation doesn't just involve trauma leading to fear, but it can involve an ISE, or prolonged exposure to situations which leads to any irrational emotion. Disgust is one other example.
Desensitisation is the complete opposite. Desensitisation is where an event, or series of events, lowers inhibition towards something which would normally raise feelings of fear, disgust etc.
More detail on what I am talking about
Examples of single instances of ISE
Take a soldier in combat who is under constant heavy gunfire and "hell is raining down on everyone around them". Fellow soldiers in their troops are killed in the process, and maybe they have come close themselves. Maybe they have lost a limb from a mortar bomb explosion. This can be one ISE which on its own causes PTSD.
Take a man/woman who is threatened with their life and raped at knife/gunpoint. Again, this ISE alone can cause PTSD.
Initial Sensitising Events (ISEs)
The science behind ISEs is as follows
As a therapist I consider not only the how the memory (or gestalt) was encoded during a Initial Sensitizing Event (ISE), but what effect that the event had and has on the person both physiologically and mentally. If the event is traumatic enough to cause stress, the fight and flight defense mechanism will lead to increased cortisol flow, IL-6 fluctuations, and eventual adrenal fatigue. Mentally/Neurologically, dominant "brain maps" may be created, which perpetuate an overactive anterior cingulate (ACG), result in a continual looping (such as in PSTD) and create further mental dysfunction as the ACG will compete for energy resources (hemoglobin and oxygen, specifically).
Let's have a breakdown of what was said in the quote
The fight and flight mechanism
A more in depth rundown on this (what I call the 5F response — fright/flight/fight/freeze/fawn) can be found in my answer to Understanding fear as a response in classical conditioning, but in short, the 5F response is an unconscious reflex to perceived threats, initiated from Threat → Brain Receiving Signals → Brain Reacts (Fright) → Cortisol and Adrenaline is released → Physical Reactions occur from the release of hormones → Bodily response (Fight, Flight, Freeze or Fawn)

(Source: Wikipedia)
Adrenaline and Cortisol Release
As you can see within the infographic above, the brain initially processes the threat signal in the amygdala and then the hypothalamus and the pituitary gland secretes adrenocortictropic hormone (ACTH) which leads to cortisol and adrenaline release to enable a speedy escape if chosen.
Based on the Wikipedia link I provided, the epigenetic effects of IL-6 have been implicated in the pathology of depression. The effects of IL-6 on depression are mediated through the repression of brain-derived neurotrophic factor (BDNF) expression in the brain; DNMT1 (DNA (cytosine-5)-methyltransferase 1) hypermethylates the BDNF promoter and reduces BDNF levels (Sharma, et al. 2008). Altered BDNF function has been implicated in depression (Hwang, et al. 2006), which is likely due to epigenetic modification following IL-6 upregulation (Sharma, et al. 2008).
The Anterior Cingulate Cortex (ACG)
The ACG is responsible for detecting incongruences between expectation and perceived experience (Somerville, et al. 2006). Altered connectivity of the anterior cingulate cortex in depression, therefore, may cause altered emotions following certain experiences, leading to depressive reactions (Somerville, et al. 2006). This altered connectivity is mediated by IL-6 and its effect on epigenetic regulation of BDNF (Sharma, et al. 2008).
Desensitisation
This will be a slow process. As @Fizz quoted,
Desensitization is generally described as a process by which the active pairing of a positive reinforcer with a negative event causes the negative event to slowly lose its ability to adversely influence behavior (Chance, P., 2003).
also called counter-conditioning.
Desensitisation for PTSD whether caused through trauma over prolonged timeframes or one single instance of ISE, can be obtained through therapy of many different types. Therapy may also be supported through medication to alleviate symptoms such as anxiety and depression.
CBT has been the go-to form of therapy within services linked to the program called Improving Access to Psychological Therapies (IAPT), but it does have its limitations. Whatever method of therapy is employed (CBT, REBT, Person Centred Therapy...), the therapy at some point will have to enable the person who is suffering from PTSD to re-evaluate their perceptions of what constitutes a threat to their personal safety.
Initially, they will have to look at what startles them (what are their triggers), evaluate where those triggers came from and look at how they can form rational thought patterns when they arise again.
Take for example, a veteran of war. When carying out routine patrols of hostile areas, they will have had to have a constant awareness of their surroundings, assessing who or what could consitute a threat. Once they are suffering the severe effects of war, they could have a hightened sense of alertness which carries forward into civilian life at home outside of war. If there is a sound of a car backfiring, in extreme cases, this can lead to a sudden reaction which can leave that person feeling very vulnerable.
This war veteran will need to be able to immediately determine that they are not in a hostile situation and in fact the loud bang was just a car backfiring (desensitising against loud bangs to a safe and rational level). It is likely that these situations (loud bangs) will not be the only trigger, and the others will need identifying and resolving.
References
Chance, P. (2003). Learning and behavior, Fifth Edition. CA:Wadsworth Publishing.
Hwang, J. P., Tsai, S. J., Hong, C. J., Yang, C. H., Lirng, J. F., & Yang, Y. M. (2006). The Val66Met polymorphism of the brain-derived neurotrophic-factor gene is associated with geriatric depression. Neurobiology of aging, 27(12), 1834-1837. doi: 10.1016/j.neurobiolaging.2005.10.013
Sharma, R. P., Tun, N., & Grayson, D. R. (2008). Depolarization induces downregulation of DNMT1 and DNMT3 in primary cortical cultures. Epigenetics, 3(2), 74-80. doi: 10.4161/epi.3.2.6103
Somerville, L. H., Heatherton, T. F., & Kelley, W. M. (2006). Anterior cingulate cortex responds differentially to expectancy violation and social rejection. Nature neuroscience, 9(8), 1007. doi: 10.1038/nn1728