The LG is a DLNA DMR (digital media renderer) if it's one of the newer models, you might have to activate the feature in the settings.
The problem with Allshare is it's a hacked version of DLNA designed to only work with Samsung's version of it. DLNA digital media controllers (the actual term) for PC's are rare and don't work very well.
The easiest way is to have Windows 8 or 7 on your PC and use the Windows Play To feature which is a DLNA DMC to DLNA DMR so you can plays files that way to the LG TV however only media compatible with Windows media player will work with this feature so other files wont e.g mkv
The latest nightly builds of XBMC have UPnP Play To feature you must activate it in the UPnP settings of XBMC then right click on a file and select the player but it's very unstable.