You can find the wallpaper location and wallpaper fit in
HKEY_CURRENT_USER\Control Panel\Desktop.
The information about the slideshow is not in the Windows registry. You have to open this path:
%USERPROFILE%\AppData\Roaming\Microsoft\Windows\Themes\
and make sure, that hidden files are visible (you can change that in folder options).
The info is in slideshow.ini. There are tags for root slideshow image and slideshows as ImagesRootPIDL which is uuencoded PCIDLIST_ABSOLUTE struct which you could use to manipulate the location of the folder. I think working with two seperate slideshow.ini files which you exchange seems to be the easier way.
EDIT
The basic process is (no way around due to MS internals to set Wallpaper from one Slideshow to another Slideshow
- Copy the backed up slideshow.ini file back into the theme directory
- Stop-process -name explorer
- Sleep 1 sec, and start up explorer only if it hasn't automatically restarted