Jump to content
LaunchBox Community Forums

Fry

Members
  • Content Count

    86
  • Joined

  • Last visited

Community Reputation

17 Good

About Fry

  • Rank
    16-Bit Artificial Intelligence

Recent Profile Visitors

The recent visitors block is disabled and is not being shown to other users.

  1. These are really great. Do you happen to have the template for these and if so, would you be willing to share it? I'd love to play around with it to add some other games that were not black box games but give a consistent look/feel all the NES library.
  2. Will do, it's getting close on 11.2. I have some work to do to get the voice recognition working in 11.3 and later due to the .net speech recognition changing to an azure function in .net core. It's an online paid service and I'd like to keep it offline and free so I'm going to have to look into some hacky approaches to calling .net framework from .net core.
  3. That works great and helped me avoid checking the big box settings XML file. Thanks again, @C-Beats!
  4. Thanks, I'll give this a shot! The short answer is that I want the dimensions of the monitor where my theme will be running so I can prescale box front images to improve the performance of moving around in my plugin/theme. The long answer is that I am creating a theme that is entirely run by a plug-in. My theme shows game box front images in a row, all scaled to the same height so they fit neatly. I wish I had your game wheel code (haha) because my game wheels were performing pretty poorly. I tried a lot of things but nothing got my wheel performing very well until I found that if I pre-scaled the images to the size that they will ultimately display then WPF doesn't incur the performance hit of scaling them at runtime. So when my plugin starts up, it duplicates all of the box front images that do not exist in my plug-in images folder and scale them to the right height based on the monitor height. Basically, my list of box front images is set to stretch uniformly into a row that takes up 5/18 of the screen so I can use the monitor height to determine the desired image size and then pre-scale the images properly on startup. The result is something like this and should work on any size screen Thanks again for your help!
  5. I think you’re right that there is no API for this and that if there was one, it’d probably do the same thing but the difference in using an approved API is that I don’t have to care how they get the value. They can change the underlying folder structure, XML file structure, or any other change all they want and it won’t break plugins using the API.
  6. I had some trouble with the update to .net core so I’m still running on 11.2 until I can iron those problems out. On 11.2, this gives me the directory with the BigBox executable.
  7. public static class Helpers { public static string ApplicationPath = Path.GetDirectoryName(System.Diagnostics.Process.GetCurrentProcess().MainModule.FileName); public static string BigBoxSettingsFile = $"{ApplicationPath}\\Data\\BigBoxSettings.xml"; public static string GetMonitorIndex() { // get the index from the big box xml file var bigBoxSettingsXmlDocument = XDocument.Load(Helpers.BigBoxSettingsFile); var setting = from xmlElement in bigBoxSettingsXmlDocument.Root.Descendants("BigBoxSettings") select xmlElement.Element("PrimaryMonitorIndex").Value; return setting.FirstOrDefault(); } } I'm doing this for now. I'm not sure if there's a better alternative way to handle it.
  8. Is it possible to get big box settings via the plug-in API? I looked around and couldn't find anything but I wanted to make sure. I'm looking to identify which monitor big box is set to run on from my plug-in. I can query it out of LaunchBox\Data\BigBoxSettings.xml file but wanted to see if I was missing anything like this in the API before doing that since going directly to the file could lead to problems if underlying implementations change. I'm looking to get this setting:
  9. I'm working on a plugin/theme for BigBox that I'm calling Eclipse. It's meant to mimic the look and feel of Netflix. It has a random game and a voice recognition feature that I'm excited to add to my cabinet. It's almost ready for release but I'm still tweaking things here and there. I thought I'd post it in case anyone is interested and I can get some feedback on any improvements that others see. One big improvement is just cleaning up the metadata. Grouping games by anything other than platform is a bit messy since there are so many similar variants in genre, series, play mode, etc... I am trying to decide if there's a programmatic solution to this via a mapping utility or if I just want to go clean up the data in my launchbox installation.
  10. Took me a bit to figure out how to add WPF user controls in a .net core class library project. In case anyone is trying to do the same thing, you'll want to do this. I think just the WindowsDesktop and <UseWPF> part. Targeting netcoreapp3.1 is working fine https://stackoverflow.com/questions/58836149/how-can-i-add-wpf-items-into-a-c-sharp-class-library-project-in-vs2019 Right-click on the class library project, choose "Edit project file" and copy the following contents into the .csproj file: <Project Sdk="Microsoft.NET.Sdk.WindowsDesktop"> <PropertyGroup> <TargetFramework>netcoreapp3.0</TargetFramework> <UseWPF>true</UseWPF> </PropertyGroup> </Project> This should give you the ability to add WPF specific items to the project using the menus.
  11. Great, thank you! I will try porting to .net core, I think they have a system.speech alternative over there
  12. Thanks Jason! Is the BigBox plug-in API supporting plugins created in both .net framework and in .net core? I am considering porting my plug-in to .net core but wasn't sure if it's supported. I think it wasn't supported prior to 11.3.
  13. I did a quick sample WPF application to ensure it's not an environment issue. I'm able to create a standalone WPF application to perform voice recognition functions using system.speech without a problem.
  14. I'm not sure if this belongs here or in the troubleshooting forum. I've been working on a voice recognition plug-in for some time and it seems the 11.3 upgrade has broken the speech recognition functionality. I'm getting the following exception when my code references System.Speech. This is the exception: Could not load file or assembly 'System.Speech, Version=4.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35'. The system cannot find the file specified. Here's the code, it was working in 11.2 so I think the change to .net core has caused this. There's nothing special about the code here and it fails as soon as the method is invoked, before log message on the first line. private bool CreateRecognizer() { try { Helpers.Log("Creating recognizer"); List<string> titleElements = new List<string>(GameTitlePhrases.Keys); // add the distinct phrases to the list of choices Choices choices = new Choices(); choices.Add(titleElements.ToArray()); GrammarBuilder grammarBuilder = new GrammarBuilder(); grammarBuilder.Append(choices); Grammar grammar = new Grammar(grammarBuilder) { Name = "Game title elements" }; // setup the recognizer Recognizer = new SpeechRecognitionEngine(); Recognizer.InitialSilenceTimeout = TimeSpan.FromSeconds(5.0); Recognizer.RecognizeCompleted += new EventHandler<RecognizeCompletedEventArgs>(RecognizeCompleted); Recognizer.LoadGrammarAsync(grammar); Recognizer.SpeechHypothesized += new EventHandler<SpeechHypothesizedEventArgs>(SpeechHypothesized); Recognizer.SetInputToDefaultAudioDevice(); Recognizer.RecognizeAsyncCancel(); } catch(Exception ex) { Helpers.LogException(ex, "CreateRecognizer"); } return (true); } I tried copying System.Speech.dll into the plugins folder alongside my DLL but then I get another error when I load big box: An error occurred while attempting to load the plugin "C:\Users\...\Documents\LaunchBox\Plugins\System.Speech.dll" Could not load the assembly 'System.Speech, Version=4.0.0.0, Culture=neutral, PublicKeyToken=31f3856ad364e35, processorArchitecture=MSIL'. Reference assemblies should not be loaded for execution. They can only be loaded in the Reflection-only loader context. (0x80131058) It appears maybe it's trying to load System.Speech as a plugin? I tried moving the DLL from the plugins folder over to the LaunchBox\Core folder but I was back to the original exception. I'm wondering if anyone has any suggestion. Under .net framework and 11.2, I could reference System.Speech and it just worked. Is there a place where .net framework references should go? Any suggestion is greatly appreciated!
  15. Fry

    BannerBox

    Are you looking in big box or in the community theme creator? If you're in big box, you might need to refresh the image cache first to make the controller image that you added show up. If you're in the theme creator, you won't see it because the controller image is overlaid as part of the theme. Regarding the black box at the bottom, i'm not sure. I had that exact thing happen to me when generating images from a different resolution. Are you seeing the black part at the bottom if you edit the view in the community theme creator? Or is it cropping after you export?
×
×
  • Create New...