Jump to content




OpenPeripheral Terminal Glasses Colors


3 replies to this topic

#1 houseofkraft

  • Members
  • 170 posts
  • LocationUSA

Posted 31 March 2017 - 07:22 PM

Hello!

I am currently trying to make VR with Terminal Glasses and the colors are messed up.

If I try to do 0x80 (gray) the wrong color appears (blue)! I do 0x777777 and gray appears but the problem is if i want 0xAAAAAA (green) it wont work because it's a letter.

please help

thanks

#2 FuzzyLitchi

  • Members
  • 34 posts

Posted 31 March 2017 - 07:38 PM

<snip>

Edited by FuzzyLitchi, 31 March 2017 - 09:38 PM.


#3 blunty666

  • Members
  • 79 posts

Posted 31 March 2017 - 07:54 PM

The colour needs to be a full hex triplet to work properly, by putting 0x80 you are only setting the last byte of the triplet which is the blue byte, hence the blue colour. Try 0x808080 to get grey.

Can't be sure without loading up an instance, but it might be that the letters need to be lower case (though I would expect upper case to work). That being said 0xaaaaaa would be grey, to get green you need to set the middle byte of the hex triplet, so 0x00ff00 would give you solid green.

Hope that makes sense!

#4 Bomb Bloke

    Hobbyist Coder

  • Moderators
  • 7,099 posts
  • LocationTasmania (AU)

Posted 01 April 2017 - 09:46 AM

View Posthouseofkraft, on 31 March 2017 - 07:22 PM, said:

... it wont work because it's a letter.

0xAAAAAA is indeed a number. If you think it's causing problems, then show us your code, and show us your error.

Edited by Bomb Bloke, 01 April 2017 - 09:48 AM.






1 user(s) are reading this topic

0 members, 1 guests, 0 anonymous users