Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Screen content is distorted (too wide)

in Bugs Posts: 13

Hello,

when I start the app in the simulator (Xcode 6.2), since version 3.2 the screen content is distorted (too wide). After rotation of the ipad the content is displayed correctly. Until version 2.2 everything is displayed correctly. When I run the code in Codea everything works fine. The app is set as portrait_any.

Code:
supportedOrientations(PORTRAIT_ANY)

function setup() ...

Has someone the same problem?
greetings schuju

Comments

  • Posts: 7

    Hi, same problem here. It happens with all projects, including the examples. I am using Xcode 6.1 and Codea 2.3 (the problem began after update). For illustrate, I have made this little test:

    -- Prueba
    
    -- Use this function to perform your initial setup
    function setup()
        --print("Hello World!")
        displayMode(FULLSCREEN)
    end
    
    -- This function gets called once every frame
    function draw()
        -- This sets a dark background color 
        background(40, 40, 50)
    
        -- This sets the line thickness
        strokeWidth(5)
    
        -- Do your drawing here
        ellipse(WIDTH/2, HEIGHT/2, 64*4)
        line(0, HEIGHT/2, WIDTH, HEIGHT/2)
        line(WIDTH/2, 0, WIDTH/2, HEIGHT)
        for i = 0, 12 do
            ellipse(i*64, HEIGHT/2, 20)
        end
        for i = 0, 16 do
            ellipse(WIDTH/2, i*64, 20)
        end
    end
    

    Inside Codea environment the circle appears correctly, but after export to Xcode it seems a ellipse until reset button is pressed or the iPad is rotated. This happens both in the simulator as in the real device. Here you may view the images:

    Before reset
    After reset

    Hey, schuju, are you find some solution or workaround for this? Are we the only Codea users with the problem?

    Thanks!

  • Posts: 2,049

    This is something @dave1707 noticed in the beta that was fixed.. @Simeon is it possible the bug is fixed in Codea but not in the Xcode export?

  • SimeonSimeon Admin Mod
    Posts: 5,657

    Thank you for the detailed report, @rodoval, @schuju. Could you log it on the issue tracker? I should be able to resolve it fairly soon.

  • SimeonSimeon Admin Mod
    edited April 2015 Posts: 5,657

    @rodoval @schuju

    Please go into your "Libs" folder within your exported project and delete the libcodea.a and libtools.a files. Then rebuild your project in Xcode.

    The issue should be fixed. Please let me know if it isn't.

  • Posts: 13

    Hello rodoval,
    put the statement "displayMode(FULLSCREEN)" above the setup function:

    displayMode(FULLSCREEN)
    ...

    function setup ()
    ...
    end

    That works for me.

    Greetings schuju

  • Posts: 7

    @Simeon

    I have tried to follow your indications, but:

    -After uncompress the zip archive generated by Codea, there aren't libcodea.a or libtools.a in the Libs folder.

    -When Xcode opens the project the files appear in the folder. The project can be executed in the simulator, now without distortion (!?). But a try of testing in the real device produces a linker error.
    I am really confused about this.

    @schuju

    It works! Simply changing the code in the standalone app makes it starts without distortion.

    Thanks to both of you.

Sign In or Register to comment.