Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Height is expressed as a Rate #67

Closed
greg0ire opened this issue Jan 16, 2017 · 3 comments
Closed

Height is expressed as a Rate #67

greg0ire opened this issue Jan 16, 2017 · 3 comments

Comments

@greg0ire
Copy link
Contributor

greg0ire commented Jan 16, 2017

The absolute value for a rate is a float, and for a height, I would expect an integer rather than a float. Not sure if this can be fixed though.

@mhor
Copy link
Owner

mhor commented Jan 16, 2017

Actually I cast absoluteValue to float because attribute display_aspect_ratio is a float type.
Example:

        object(Mhor\MediaInfo\Attribute\Rate)#39 (2) {
          ["absoluteValue":"Mhor\MediaInfo\Attribute\Rate":private]=>
          float(2.353)
          ["textValue":"Mhor\MediaInfo\Attribute\Rate":private]=>
          string(6) "2.35:1"
        }

To solve Rate::absoluteValue type I proposed to:

  • add a new attribute type Ratio with properties absoluteValue (float type) and textValue (string type)
  • cast Rate::absoluteValue to int
  • release a 3.0.0 due to BC break

@greg0ire
Copy link
Contributor Author

Sounds good!

@mhor mhor mentioned this issue Jan 17, 2017
4 tasks
@mhor mhor closed this as completed in a16bad2 Jan 17, 2017
@mhor
Copy link
Owner

mhor commented Jan 17, 2017

Thank you @greg0ire , #68 is now merged and realeased as 3.0.0

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants