{"action":"created","issue":{"url":"https://api.github.com/repos/gonetz/GLideN64/issues/808","repository_url":"https://api.github.com/repos/gonetz/GLideN64","labels_url":"https://api.github.com/repos/gonetz/GLideN64/issues/808/labels{/name}","comments_url":"https://api.github.com/repos/gonetz/GLideN64/issues/808/comments","events_url":"https://api.github.com/repos/gonetz/GLideN64/issues/808/events","html_url":"https://github.com/gonetz/GLideN64/issues/808","id":118394934,"number":808,"title":"[Feature Request] Add support for frame buffer extension API","user":{"login":"gonetz","id":8983092,"avatar_url":"https://avatars.githubusercontent.com/u/8983092?v=3","gravatar_id":"","url":"https://api.github.com/users/gonetz","html_url":"https://github.com/gonetz","followers_url":"https://api.github.com/users/gonetz/followers","following_url":"https://api.github.com/users/gonetz/following{/other_user}","gists_url":"https://api.github.com/users/gonetz/gists{/gist_id}","starred_url":"https://api.github.com/users/gonetz/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gonetz/subscriptions","organizations_url":"https://api.github.com/users/gonetz/orgs","repos_url":"https://api.github.com/users/gonetz/repos","events_url":"https://api.github.com/users/gonetz/events{/privacy}","received_events_url":"https://api.github.com/users/gonetz/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":148,"created_at":"2015-11-23T14:41:03Z","updated_at":"2016-02-15T06:30:37Z","closed_at":null,"body":"Need to implement the following extension to Zilmar's specs:\r\n\r\n/******************************************************************\r\nFunction: FrameBufferRead\r\nPurpose: This function is called to notify the dll that the\r\nframe buffer memory is beening read at the given address.\r\nDLL should copy content from its render buffer to the frame buffer\r\nin N64 RDRAM\r\nDLL is responsible to maintain its own frame buffer memory addr list\r\nDLL should copy 4KB block content back to RDRAM frame buffer.\r\nEmulator should not call this function again if other memory\r\nis read within the same 4KB range\r\ninput: addr rdram address\r\nval val\r\nsize 1 = wxUint8, 2 = wxUint16, 4 = wxUint32\r\noutput: none\r\n*******************************************************************/\r\nEXPORT void CALL FBRead(wxUint32 addr)\r\n\r\n/******************************************************************\r\nFunction: FrameBufferWriteList\r\nPurpose: This function is called to notify the dll that the\r\nframe buffer has been modified by CPU at the given address.\r\ninput: FrameBufferModifyEntry plist\r\nsize = size of the plist, max = 1024\r\noutput: none\r\n******************************************************************/\r\nEXPORT void CALL FBWList(FrameBufferModifyEntry *plist, wxUint32 size)\r\n\r\n/******************************************************************\r\nFunction: FrameBufferWrite\r\nPurpose: This function is called to notify the dll that the\r\nframe buffer has been modified by CPU at the given address.\r\ninput: addr rdram address\r\nval val\r\nsize 1 = wxUint8, 2 = wxUint16, 4 = wxUint32\r\noutput: none\r\n*******************************************************************/\r\nEXPORT void CALL FBWrite(wxUint32 addr, wxUint32 size)\r\n\r\n/************************************************************************\r\nFunction: FBGetFrameBufferInfo\r\nPurpose: This function is called by the emulator core to retrieve frame\r\nbuffer information from the video plugin in order to be able\r\nto notify the video plugin about CPU frame buffer read/write\r\noperations\r\n\r\nsize:\r\n= 1 byte\r\n= 2 word (16 bit) <-- this is N64 default depth buffer format\r\n= 4 dword (32 bit)\r\n\r\nwhen frame buffer information is not available yet, set all values\r\nin the FrameBufferInfo structure to 0\r\n\r\ninput: FrameBufferInfo pinfo[6]\r\npinfo is pointed to a FrameBufferInfo structure which to be\r\nfilled in by this function\r\noutput: Values are return in the FrameBufferInfo structure\r\nPlugin can return up to 6 frame buffer info\r\n************************************************************************/\r\nEXPORT void CALL FBGetFrameBufferInfo(void *p)\r\n\r\n"},"comment":{"url":"https://api.github.com/repos/gonetz/GLideN64/issues/comments/184080683","html_url":"https://github.com/gonetz/GLideN64/issues/808#issuecomment-184080683","issue_url":"https://api.github.com/repos/gonetz/GLideN64/issues/808","id":184080683,"user":{"login":"gonetz","id":8983092,"avatar_url":"https://avatars.githubusercontent.com/u/8983092?v=3","gravatar_id":"","url":"https://api.github.com/users/gonetz","html_url":"https://github.com/gonetz","followers_url":"https://api.github.com/users/gonetz/followers","following_url":"https://api.github.com/users/gonetz/following{/other_user}","gists_url":"https://api.github.com/users/gonetz/gists{/gist_id}","starred_url":"https://api.github.com/users/gonetz/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gonetz/subscriptions","organizations_url":"https://api.github.com/users/gonetz/orgs","repos_url":"https://api.github.com/users/gonetz/repos","events_url":"https://api.github.com/users/gonetz/events{/privacy}","received_events_url":"https://api.github.com/users/gonetz/received_events","type":"User","site_admin":false},"created_at":"2016-02-15T06:30:37Z","updated_at":"2016-02-15T06:30:37Z","body":"@purplemarshmallow The set of options, which added to solve some particular issues turns the plugin into tangled system of crutches and props.  The same problem plagued  Glide64 development, where any step may cause chain of regressions.\r\nUnfortunately, I don't see a good alternative yet.\r\n\r\n@LegendOfDragoon The rain issue should not depend on CPU emulation method. The problem is on plugin's side: CPU writes rain drops to current buffer. Plugin detects that buffer has changed outside, thus it is invalid and plugin must show the picture written by CPU. The picture contains only rain drops."}}