Git Product home page Git Product logo

Comments (4)

lmerckx avatar lmerckx commented on August 19, 2024

Indeed, I'm not very proud of this workaround.

As you say, the proper way could be to avoid calling twice the method "vid_update_yuv_overlay" but I didn't find how to do that previously.
Now, it's very far from my memory :)

from hypseus.

vanfanel avatar vanfanel commented on August 19, 2024

@lmerckx @h0tw1r3 What's the game trying to archieve if it calls vid_update_yuv_overlay and does not call vid_blit?

My understanding is that all games should call vid_blit to show something on screen, be it a FMV frame and/or superinposed info like sprites or scoreboards, right?

Maybe I should simply let the games call vid_update_yuv_overlay unconditionally without waiting for a vid_blit call?

Maybe I am misunderstanding the internal architecture of the program here...

@h0tw1r3 I know you are busy but I need your input about this too.

from hypseus.

vanfanel avatar vanfanel commented on August 19, 2024

In other words: there MUST be a "central" function that calls SDL_RenderPresent, and that function is, from my understanding, vid_blit.

A game can update the YUV surface (via vid_update_yuv_overlay) but that doesn't send the YUV surface contents to the screen: that has to be done in vid_blit.

That or I just don't get how hypseus is supposed to present the video.

from hypseus.

vanfanel avatar vanfanel commented on August 19, 2024

Well, in the end I decided to disable waiting for texture updates for now.
If a game wants to update the YUV surface but doesn't want the video to be blit immediately, so be it.
It will prevent the VLDP thread to get stuck, at least. I didn't see any caveats, so here it goes, please merge:
#33

from hypseus.

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.