CandyFace

Member

Last active 2 months ago

  1. 9 months ago
    Sat Jul 23 12:11:39 2016
    CandyFace posted in LuaPolyCode for Sublime Text 3.

    True but I really have no idea as to how I would do that, it'll just end up like this:
    -image-

    Even though it would probably be better in the long term, should I not keep it up to date, I think I'll just continue doing it manually anyway.

  2. Thu Jul 21 13:53:54 2016

    Package and exporting the game for windows, via the Polycode IDE on OS X.
    The image i've posted just shows what is inside the Polycode.app IDE Resource/Standalone folder, in case you would be wondering if something is missing.

    edit: Ah well I found a workaround, I just make a copy the Win folder from the publish folder (as shown in the image), and replaces the main.polyapp... it just seems weird that it won't do that automatically, as it clearly works for mac and linux, but I guess it's a bug in the released 0.8.4 Polycode IDE.

  3. Thu Jul 21 12:29:50 2016
    CandyFace started the conversation Compiling windows build through lua IDE.

    Hi

    I'm trying to publish my game for mac, linux and PC but for some reason it's not working for windows. I've copied all the necessary Standalone/Publish (taken from the 0.8.4 build) into the folder, and it compiles for Linux and mac, but not windows. the IDE doesn't show any errors, so figuring out how to fix this, is difficult.

    Here's a snippit of my folder structure inside Polycode.app:
    -image-

    Is there something extra I have to do for windows?

  4. Sat Jul 16 17:11:12 2016
    CandyFace posted in Post processing bloom artefacts.

    Ahh so it is the kernel which is to be the fault. I am actually using the shader from the goodbye_cmake branch, so I guess I'll have to mess with the blurring kernel then.. Thanks for the info ;)

  5. Sat Jul 16 15:43:30 2016
    CandyFace started the conversation Post processing bloom artefacts.

    I've finally figured how to add post processing to a camera, but noticed that when you increase the blurH, blurV to a certain size, it creates a lot of artefacts.. looks like tiling.. How do I avoid this?

    I am using the HDRProcessBloom post processing shader.

    -image-

    this is with these parameters:

    scene:getDefaultCamera():getLocalShaderOptions()[2]:addParam(ProgramParam.PARAM_NUMBER, "blurSize"):setNumber(0.006)
    scene:getDefaultCamera():getLocalShaderOptions()[3]:addParam(ProgramParam.PARAM_NUMBER, "blurSize"):setNumber(0.006)
  6. Thu Jul 14 18:26:43 2016
    CandyFace posted in Post Processing Example.

    it doesn't seem like there are any lua bindings anymore for PolyLogger.. The only function I have access to is CoreServices.GetLogger() which returns Logger but that's it.

    I figured it out.. after understanding how to set the parameters inside the shader, it all seemed to work.

    So in the end, this was all I needed to do:

    Services.ResourceManager:addArchive("hdr.pak")
    Services.ResourceManager:addDirResource("hdr", true)
    scene:getDefaultCamera():setPostFilterByName("HDRProcessBloom")
    
    scene:getDefaultCamera():getLocalShaderOptions()[1]:addParam(ProgramParam.PARAM_NUMBER, "brightThreshold"):setNumber(0.1)
    scene:getDefaultCamera():getLocalShaderOptions()[2]:addParam(ProgramParam.PARAM_NUMBER, "blurSize"):setNumber(0.003)
    scene:getDefaultCamera():getLocalShaderOptions()[3]:addParam(ProgramParam.PARAM_NUMBER, "blurSize"):setNumber(0.003)
    scene:getDefaultCamera():getLocalShaderOptions()[4]:addParam(ProgramParam.PARAM_NUMBER, "bloomFactor"):setNumber(1.5)
    scene:getDefaultCamera():getLocalShaderOptions()[4]:addParam(ProgramParam.PARAM_NUMBER, "exposure"):setNumber(0.4)
  7. Thu Jul 14 15:20:32 2016
    CandyFace posted in Post Processing Example.

    Yes I've added the hdr.pak manually although it's not inside a Resources folder. It just lies in my main folder currently, but that shouldn't make any difference, as long as I make sure it's the right path right?

  8. Thu Jul 14 04:28:40 2016
    CandyFace posted in Post Processing Example.

    Hmm that doesn't seem to work either... but yes it's true that the resources folder is added automatically when using lua.

    I added the code like you said but no effect is being applied, nor am I getting any errors.

    Services.ResourceManager:addArchive("hdr.pak")
    Services.ResourceManager:addDirResource("hdr", false)
    scene:getDefaultCamera():setPostFilterByName("HDRProcessBloom");

    in case you want to see my code in context, although with the above not commited yet..
    https://github.com/CandyFace/AsteroidsLua/blob/master/Scripts/Main.lua

    The code block has been inserted between my level scene instance and setting the video mode.

    edit: After a bunch of trial and error... as well as looking at some of the old c++ template code. I've gotten to this so far:

    Services.ResourceManager:addArchive("default.pak")
    Services.ResourceManager:addDirResource("default", true)
    Services.ResourceManager:addArchive("hdr.pak")
    Services.ResourceManager:addDirResource("hdr", true)
    scene:getActiveCamera():setPostFilterByName("HDRProcessBloom");

    If I use the print(scene:getActiveCamera():hasFilterShader())
    then it returns true.. but I still can't see the effect being applied.. at least it's not visible at all. I'm developing on OSX btw.

  9. Wed Jul 13 19:28:17 2016
    CandyFace posted in Post Processing Example.

    I know this thread is old but... would you be able to elaborate on the latter part?
    I have added the Resource dir to the ResourceManager like so:
    Services.ResourceManager:addDirResource("Resources", false)
    and added the HDR filter to my camera, but it still isn't working?
    scene:getDefaultCamera():setPostFilterByName("HDRProcessBloom");

    What else do I need to do?

  10. Tue Jul 5 10:13:23 2016
    CandyFace posted in New Website look.

    Can we get a sneak peek?

View more