We use cookies to ensure that we give you the best experience on our website. If you continue to use this site we will assume that you are happy with it.

Objects that don’t scale based on distance

Home Forums Puzzles Objects that don’t scale based on distance

Viewing 15 posts - 1 through 15 (of 15 total)
  • Author
    Posts
  • #51347
    yogyog
    Participant

    So, I’m creating a Verge3D scene where you navigate around a train-cab via hotspots. These hotsopts are little circles that point towards the camera using a Track To constraint (for some reason copy rotation dnt work for me) and I used the puzzle logic below to keep them the same size on screen no matter how far away from the camera.

    The probelm is – at the edge of the screen they get larger. By quite a bit. The camera is quite wide angle as it’s a cramped enviroment.

    Is there a way round this? I actually solved this in drivers https://www.youtube.com/watch?v=iq2l8EAiGvg&t=989s but its kind of a clunky solution which probably wont work in verge 3D and I currently have 10 hotspots which is a lot of extra empties to control all that.

    Is there a way I can read the screen position of an object?

    Attachments:
    You must be logged in to view attached files.
    #51350

    Create an HTML element with the text and bind it to an empty it’s will be easier. Otherwise you need to do some recalculations to set scale based on distance not only use pure distance as scale.

    Co-founder and lead graphics specialist at Soft8Soft.

    #51352
    yogyog
    Participant

    Cheers. Any tutoirals on how to do that? It’s not text -it’s … well, it’s an object with an animated material that phases between two shades of blue… I’d settle for being able to use a PNG.

    #51358

    Sorry no serious tutorial about thet but here I made a quick video how you can do it. The final project in attachement.

    Attachments:
    You must be logged in to view attached files.

    Co-founder and lead graphics specialist at Soft8Soft.

    #51391
    yogyog
    Participant

    Thank you! I’ll have a look at implementing that soon.

    #51398

    :good:

    Co-founder and lead graphics specialist at Soft8Soft.

    #51443
    yogyog
    Participant

    ………..I’m not getting anything.

    WHile it was really kind of you to upload the video, you uploaded it at 480p, so I’m not totally sure this is right. I’ve uploaded a screenshot of what I have.

    Also – I didn’t have the same options for Modules on the beggining as you. I had:

    Font Converter
    IE 11
    Legacy VR
    Physics

    Could this be a problem? I think I have the latest version.

    Attachments:
    You must be logged in to view attached files.
    #51446
    yogyog
    Participant

    And one more thing? is there a way the image can be centered on the object center rather than it’s top-left pixel being on the object center?

    #51470

    Could this be a problem? I think I have the latest version.

    No.

    And one more thing? is there a way the image can be centered on the object center rather than it’s top-left pixel being on the object center?

    Yes. Just set background-position:center; this is all CSS basics, type CSS in the google for more options.

    Co-founder and lead graphics specialist at Soft8Soft.

    #51472
    yogyog
    Participant

    So…. should my code be working? Cos I’m getting nothing.

    Thanks for your help.

    #51473

    Yes, it’s must work. Share the app I will look what wrong.

    Co-founder and lead graphics specialist at Soft8Soft.

    #51492
    yogyog
    Participant

    Whoops – I just posted this in entirely the wrong thread!

    Thanks for your help :heart:

    #51504

    You need to add . before “al’ in puzzle Create CSS Style, but only there. It’s important because all classes names must be named with ‘.’

    Co-founder and lead graphics specialist at Soft8Soft.

    #51827
    yogyog
    Participant

    OK – thankyou for your help again and again – you’ve gone well beyond when it comes to your help with this, and I hope you don’t mind that I was away for a week, but ….

    I have one more question to ask you.

    It’s about cetering the button in the middle of the object.

    I’ve added the line
    background-position: center;
    but it’s not …. centering it. It’s still with it’s top-left corner on the object centre, not the centre of the png on the object centre.

    #51899

    You need to set Left to half of the width px, and top to half of the height. For example if widht 250px then set “left: 175px;” etc

    Co-founder and lead graphics specialist at Soft8Soft.

Viewing 15 posts - 1 through 15 (of 15 total)
  • You must be logged in to reply to this topic.