Code Monkey home page Code Monkey logo

Comments (11)

vancura avatar vancura commented on June 2, 2024

Thanks a lot man. It's a blocker for me :(

from cocossharp.

vancura avatar vancura commented on June 2, 2024

Here's a screenshot from my test:

screen shot 2014-10-15 at 13 26 32

Window and design resolution size are set to 2048x1536 (1024x768 * 2), but as you can see the real space is somewhat smaller. Mind the black space on the edge of the window.

The repo is here: https://github.com/vancura/fracthor/commit/6dccc3fb441618a2c2ff51a917b7e7843f7e5b16

from cocossharp.

vancura avatar vancura commented on June 2, 2024

This is the same thing in Nexus 4 in Android Simulator. Screen height shouldn't be 1185px.

screen shot 2014-10-15 at 13 38 33

from cocossharp.

kjpou1 avatar kjpou1 commented on June 2, 2024

@vancura Can you verify the change committed to see if that fixes this issues. Fingers crossed.

from cocossharp.

vancura avatar vancura commented on June 2, 2024

No, it didn't help, I nearly had a fix when I found out this method of Monogame's Viewport.

There's a lot of floats involved and vector.z is never exactly 1, but it's very very close. It can't be 1, as it's used for 3D projection. Well, 3D projection. The rounding problem could be seen only when CCCameraProjection.Projection3D is used (not 2D).

I don't think we can do anything with that. It's deep in MonoGame and that's how MonoGame works. Wondering how other games do it, if they just gave up on edge to edge rendering.

@kjpou1: I guess you should revert your commit, as we don't know if it doesn't have any other issues.

from cocossharp.

vancura avatar vancura commented on June 2, 2024

That reminds me: we removed 2D projection, right? :(

from cocossharp.

vancura avatar vancura commented on June 2, 2024

@kjpou1: maybe leave the commit there. It's better at least on Nexus 7 in landscape.

from cocossharp.

rtabbara avatar rtabbara commented on June 2, 2024

@kjpou1: I'll take a look at this -- still think it's related to numerical rounding issues from our side. I would prefer to revert this commit for now. I remember when toying around and taking the ceiling or floor of certain values I observed an "improved" bounds calculation but this was just by luck of the particular design resolution I had chosen. When I tried a variety of different resolutions I didn't consistently observe an improvement. So I think we need to find a robust solution to this.

@vancura No, 2D projection is still around but is set at the CCCamera level. We might add a CCLayer constructor so that you can do something like new CCLayer(CCCameraProjection proj) if you think that will make things easier. But either way, we definitely want a fix for the 3D case.

from cocossharp.

rtabbara avatar rtabbara commented on June 2, 2024

@vancura The latest commit (30ce711) has taken a stab at addressing the issue. Please let me know how it goes.

from cocossharp.

vancura avatar vancura commented on June 2, 2024

@rtabbara: Amazing! It really works! Thanks so much!

from cocossharp.

rtabbara avatar rtabbara commented on June 2, 2024

No problem, glad it works.

from cocossharp.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.