Begin by preparing the pineapple compote. Drain the pineapple if using canned, reserving 2 tablespoons of the juice. Place the pineapple, the vanilla extract and sugar in a non-reactive pan on low heat. Cook for 30 minutes, stirring occasionally.
Allow the pineapple to cool, then run the compote through a blender or food processor to purée. Cover and refrigerate until ready to serve.
For the mousse, prepare the gelatin by placing the sheets to soak in a bowl of cold water.
Place the raspberries, sugar, lemon juice, yogurt and mascarpone in a food processor or mixer and blend until well mixed. Taste and add more sugar as needed.
Heat the reserved pineapple juice without boiling. Remove from the heat and add the drained gelatine sheets. Stir to combine well.
Meanwhile, in a clean mixing bowl, beat the egg whites until stiff. Mix the gelatin mixture into the raspberry mixture and then delicately fold in the egg whites. Fold only as much as needed to mix. Cover and refrigerate until ready to serve.
To serve, place several spoons of pineapple compote in the bottom of a glass bowl, then top with raspberry mousse.