Jump to content

Yaron

Members
  • Content Count

    219
  • Joined

  • Last visited

  • Days Won

    1

Yaron last won the day on November 13 2018

Yaron had the most liked content!

Community Reputation

38 Excellent

Technical Information

  • Delphi-Version
    Delphi 10.3 Rio

Recent Profile Visitors

The recent visitors block is disabled and is not being shown to other users.

  1. @Dave Nottage Yes, I am working with the same "SEND" action. I read the article you linked to, but didn't see any mention regarding the same action used more than once. I did get an answer on stackoverflow that I should use an Activity Alias, but haven't had time to test it yet and I haven't figured out yet (mainly due to lack of time) how to do this in delphi : if (intent.component.className.endsWith(".Queue"){ // putting data in the queue... } else { // playing requested data... }
  2. I tried modifying the manifest file to include two entries with different labels: <intent-filter android:label="Play in XX"> <action android:name="android.intent.action.SEND" /> <category android:name="android.intent.category.DEFAULT" /> <data android:mimeType="text/plain" /> </intent-filter> <intent-filter android:label="Queue in XX"> <action android:name="android.intent.action.SEND" /> <category android:name="android.intent.category.DEFAULT" /> <data android:mimeType="text/plain" /> </intent-filter> However, only the first entry shows up in YouTube and on top of that I'm not even sure how to read the label value from my Delphi code so I can distinguish between the two call even if YouTube did list them.
  3. I don't see the mechanism that would allow me to distinguish between multiple intents. I don't understand how calling "MainActivity.registerIntentAction(TJIntent.JavaClass.ACTION_SEND);" again would help.
  4. I am trying to write Android intent code so when a user chooses to share text with another application, my app will appear twice as an option, each with a different label and a mechanism I can distinguish between the two intents. Basically, I'm trying to have "Play" and "Queue" options for URLs shared from the YouTube app. I have no issues with just one intent, defining in "AndroidManifest.template.xml" <intent-filter> <action android:name="android.intent.action.SEND" /> <category android:name="android.intent.category.DEFAULT" /> <data android:mimeType="text/plain" /> </intent-filter> And in code: // Register the type of intent action that we want to be able to receive. // Note: A corresponding <action> tag must also exist in the <intent-filter> section of AndroidManifest.template.xml. MainActivity.registerIntentAction(TJIntent.JavaClass.ACTION_SEND); TMessageManager.DefaultManager.SubscribeToMessage(TMessageReceivedNotification, HandleActivityMessage); procedure TMainForm.HandleActivityMessage(const Sender: TObject; const M: TMessage); begin if M is TMessageReceivedNotification then HandleIntentAction(TMessageReceivedNotification(M).Value); end; function TMainForm.HandleIntentAction(const Data: JIntent): Boolean; var Extras : JBundle; sURL : String; begin Result := False; if Data <> nil then begin Extras := Data.getExtras; if Extras <> nil then Begin sURL := JStringToString(Extras.getString(TJIntent.JavaClass.EXTRA_TEXT)); {$IFDEF TRACEDEBUG}AddDebugEntry('Intent string "'+sURL+'"');{$ENDIF} Extras := nil; End end end; How can I add a second intent?
  5. You are not very clear, I believe mars translates everything to unicode, I have no issues with UTF8 encoded content.
  6. Yaron

    [Source code for sale] Automated Whatsapp server

    It looks like you're hooking into the browser version of whatsapp, which browser interface are you using (explorer, chrome?) And since you're not using the API, wouldn't your code stop working as soon as whatsapp changes something in their browser implementation?
  7. Any reason you're looking to pass this information in the path instead of perhaps using a form POST that contains the relevant information?
  8. I'm using AJAX forms with javascript's "history.pushState" to preserve the browser's "back" button functionality. So if my entry point is "https://myserver.com/v/site/", clicking on a link would look like "https://myserver.com/v/site/page1/" without any actual page being loaded (only part of the page). My problem is that when the user tries to refresh the page, MARS won't recognize the "https://myserver.com/v/site/page1/" path. In reality, I would like to redirect such URLs back to "https://myserver.com/v/site/". I tried registering the InvokeError procedure like this: TMARSActivation.RegisterInvokeError( procedure (const AActivation: IMARSActivation; const AException: Exception; var AHandled: Boolean) begin ShowMessage(AActivation.Request.URL); AHandled := True; end ); Which is triggered, but "AActivation.Request.URL" returns an empty string and I'm not sure how to perform the redirect... can you help?
  9. I need to temporarily disable HDR to display a menu system when an HDR video is playing. It's been a bit of a chase finding out this is done, so I thought I'll share. There's documentation of how to do it with C++ here: https://stackoverflow.com/questions/53517128/query-if-hdr-is-active-on-windows But even Delphi 10.3.3 is missing "Winapi.DXGI1_6.pas". However, Searching for this file led me to MfPack (https://sourceforge.net/projects/mfpack/), which does carry up to date header conversions.
  10. @eivindbakkestuen: I have a 4 Core/8 Thread GPU and the CPU is not really tasked, I believe it's mostly disk I/O. @Fr0sT.Brutal: You missed the bit where I wrote that the mediainfo data is synched with a central scrape-coordination thread, so the main UI is only disturbed when all the data has been scraped. And yes, it can be analyzing 100's (even 1000's) of files, trying to do so for about 4 concurrently.
  11. @Remy Lebeau Debugging multiple threads is very difficult (at least in D7) as the run-point seems to jump between the threads each time you advance one line (unless there's something I'm missing?) This is why I use a lot of debug log entries. I believe the code I pasted above doesn't synchronize anything with the main thread, it's passing data to another (scraping) thread which works (synchronizes) just fine when doing other heavy work unrelated to mediainfo.
  12. Here are more details (it's somewhat big, but may help others in the future): 1. I have an Idle priority information-scraping thread so the UI won't be affected by the scraping process. 2. The scraping thread pre-creates & uses an idle priority TMediaInfoThread thread (see below). 3. The scraping activates the mediainfo thread. 4. This is the mediainfo's DLL pascal header file : https://github.com/MediaArea/MediaInfoLib/blob/master/Source/MediaInfoDLL/MediaInfoDLL.pas 5. And you can download the DLL here https://mediaarea.net/en/MediaInfo/Download/Windows Code used to activate MediaInfo data gathering thread: MediaInfoThread.MediaName := MediaName; MediaInfoThread.ScrapeType := niVideo; MediaInfoThread.ResumeThread; // do other scraping related meta-data gathering (e.g. online DB lookup) while mediainfo is processing to maximize concurrently/performance. While MediaInfoThread.IsSuspended = False do Sleep(1); If MediaInfoThread.miResult = True then The MediaInfo thread code: Type TMediaInfoThread = Class(TThread) procedure execute; override; private FEvent : THandle; public ScraperThreadIndex : Integer; IsSuspended : Boolean; ScrapeType : Integer; MediaName : WideString; miResult : Boolean; miWidth : Integer; miHeight : Integer; miDuration : Double; miIcons : WideString; miMediaTAGs : TZPTAGRec; Closed : PBoolean; procedure ResumeThread; end; procedure TMediaInfoThread.Execute; begin {$IFDEF LOCALTRACE}DebugMsgFT('c:\log\MediaInfoThread_'+IntToStr(ScraperThreadIndex)+'.txt','Thread Created, ID #'+IntToStr(ThreadID));{$ENDIF} FEvent := CreateEvent(nil, False, // auto reset False, // initial state = not signaled nil); ResetTagData(miMediaTAGs); ScrapeType := niVideo; IsSuspended := True; {$IFDEF LOCALTRACE}DebugMsgFT('c:\log\MediaInfoThread_'+IntToStr(ScraperThreadIndex)+'.txt','Thread Initially Suspended');{$ENDIF} WaitForSingleObject(FEvent, INFINITE); // Wait to start processing {$IFDEF LOC1ALTRACE} DebugMsgFT('c:\log\MediaInfoThread_'+IntToStr(ScraperThreadIndex)+'.txt','Thread Initially Resumed'+CRLF); {$ENDIF} While (Terminated = False) do Begin {$IFDEF LOCALTRACE}DebugMsgFT('c:\log\MediaInfoThread_'+IntToStr(ScraperThreadIndex)+'.txt','MediaInfo on "'+MediaName+'" (before)');{$ENDIF} miResult := MediaInfo_GetMediaInfoCache(MediaName,ScrapeType,miIcons,miWidth,miHeight,miDuration,@miMediaTAGs,ScraperThreadIndex); {$IFDEF LOCALTRACE}DebugMsgFT('c:\log\MediaInfoThread_'+IntToStr(ScraperThreadIndex)+'.txt','MediaInfo on "'+MediaName+'" (after)');{$ENDIF} If Terminated = False then Begin IsSuspended := True; {$IFDEF LOCALTRACE}DebugMsgFT('c:\log\MediaInfoThread_'+IntToStr(ScraperThreadIndex)+'.txt','MediaInfo complete, Thread Suspended'+CRLF);{$ENDIF} WaitForSingleObject(FEvent, INFINITE); // No more Work {$IFDEF LOCALTRACE}DebugMsgFT('c:\log\MediaInfoThread_'+IntToStr(ScraperThreadIndex)+'.txt','Thread Resumed');{$ENDIF} If Terminated = False then ResetTagData(miMediaTAGs); End; End; {$IFDEF LOCALTRACE}DebugMsgFT('c:\log\MediaInfoThread_'+IntToStr(ScraperThreadIndex)+'.txt','Close event handle');{$ENDIF} CloseHandle(fEvent); If @Closed <> nil then Closed^ := True; {$IFDEF LOCALTRACE}DebugMsgFT('c:\log\MediaInfoThread_'+IntToStr(ScraperThreadIndex)+'.txt','Thread Terminated');{$ENDIF} end; procedure TMediaInfoThread.ResumeThread; begin SetEvent(FEvent); IsSuspended := False; end; function MediaInfo_GetMediaInfo(FileName : WideString; ScrapeType : Integer; miData : PMediaInfoDataRecord; grabThreadID : Integer) : Boolean; var miHandle : Cardinal; sFormat : WideString; sFormatVersion : WideString; sFormatString : WideString; sProfile : WideString; sCodecID : WideString; sScanType : WideString; sDuration : WideString; aCount : Integer; vCount : Integer; I : Integer; mWidth : Integer; mHeight : Integer; mChannels : Integer; iWidth : Integer; iHeight : Integer; iChannels : Integer; iCodec : Integer; S : String; begin {$IFDEF LOCALTRACE}DebugMsgFT('c:\log\MediaInfoThread_'+IntToStr(grabThreadID)+'.txt','MediaInfo_GetMediaInfo (before)');{$ENDIF} Result := False; With miData^ do Begin iconFormat := niNone; iconResolution := niNone; iconVideo := niNone; iconAudio := niNone; iconChannels := niNone; ResetTagData(TAGs); If MediaInfoLoaded = True then Begin {$IFDEF LOCALTRACE}DebugMsgFT('c:\log\MediaInfoThread_'+IntToStr(grabThreadID)+'.txt','MediaInfoLoaded = True');{$ENDIF} miHandle := MediaInfo_New; {$IFDEF LOCALTRACE}DebugMsgFT('c:\log\MediaInfoThread_'+IntToStr(grabThreadID)+'.txt','MediaInfo Handle : '+IntToHex(miHandle,8));{$ENDIF} If MediaInfo_Open(miHandle, PWideChar(FileName)) = 1 then Begin {$IFDEF LOCALTRACE}DebugMsgFT('c:\log\MediaInfoThread_'+IntToStr(grabThreadID)+'.txt','Open successful');{$ENDIF} Result := True; // Duration sDuration := MediaInfo_Get(miHandle, Stream_General, 0, 'Duration' , Info_Text, Info_Name); mediaDuration := StrToFloatDef(sDuration,0) / 1000; {$IFDEF LOCALTRACE}DebugMsgFT('c:\log\MediaInfoThread_'+IntToStr(grabThreadID)+'.txt','Duration : '+sDuration);{$ENDIF} // File format {$IFDEF LOCALTRACE}DebugMsgFT('c:\log\MediaInfoThread_'+IntToStr(grabThreadID)+'.txt','*** File Format ');{$ENDIF} sFormat := MediaInfo_Get(miHandle, Stream_General, 0, 'Format' , Info_Text, Info_Name); {$IFDEF LOCALTRACE}DebugMsgFT('c:\log\MediaInfoThread_'+IntToStr(grabThreadID)+'.txt','Format : '+sFormat);{$ENDIF} sFormatVersion := MediaInfo_Get(miHandle, Stream_General, 0, 'Format_Version', Info_Text, Info_Name); {$IFDEF LOCALTRACE}DebugMsgFT('c:\log\MediaInfoThread_'+IntToStr(grabThreadID)+'.txt','FormatVersion : '+sFormatVersion);{$ENDIF} sProfile := MediaInfo_Get(miHandle, Stream_General, 0, 'Format_Profile', Info_Text, Info_Name); {$IFDEF LOCALTRACE}DebugMsgFT('c:\log\MediaInfoThread_'+IntToStr(grabThreadID)+'.txt','Profile : '+sProfile);{$ENDIF} iconFormat := MediaInfo_FormatToNavIcon(sFormat,sFormatVersion,sProfile); If ScrapeType = niVideo then Begin // Video Codec & Resolution {$IFDEF LOCALTRACE}DebugMsgFT('c:\log\MediaInfoThread_'+IntToStr(grabThreadID)+'.txt','*** Video Codec & Resolution');{$ENDIF} mWidth := -1; mHeight := -1; vCount := MediaInfo_Count_Get(miHandle, Stream_Video, -1); {$IFDEF LOCALTRACE}DebugMsgFT('c:\log\MediaInfoThread_'+IntToStr(grabThreadID)+'.txt','Video Streams : '+IntToStr(vCount));{$ENDIF} For I := 0 to vCount-1 do Begin iWidth := StrToIntDef(MediaInfo_Get(miHandle, Stream_Video, I, 'Width' , Info_Text, Info_Name),-1); iHeight := StrToIntDef(MediaInfo_Get(miHandle, Stream_Video, I, 'Height', Info_Text, Info_Name),-1); If (iWidth > mWidth) or (iHeight > mHeight) then Begin {$IFDEF LOCALTRACE}DebugMsgFT('c:\log\MediaInfoThread_'+IntToStr(grabThreadID)+'.txt',IntToStr(I)+'. Video Resolution : '+IntToStr(iWidth)+'x'+IntToStr(iHeight));{$ENDIF} mWidth := iWidth; mHeight := iHeight; sFormat := MediaInfo_Get(miHandle, Stream_Video, I, 'Format' , Info_Text, Info_Name); {$IFDEF LOCALTRACE}DebugMsgFT('c:\log\MediaInfoThread_'+IntToStr(grabThreadID)+'.txt',IntToStr(I)+'. Format : '+sFormat);{$ENDIF} sFormatVersion := MediaInfo_Get(miHandle, Stream_Video, I, 'Format_Version', Info_Text, Info_Name); {$IFDEF LOCALTRACE}DebugMsgFT('c:\log\MediaInfoThread_'+IntToStr(grabThreadID)+'.txt',IntToStr(I)+'. FormatVersion : '+sFormatVersion);{$ENDIF} sProfile := MediaInfo_Get(miHandle, Stream_Video, I, 'Format_Profile', Info_Text, Info_Name); {$IFDEF LOCALTRACE}DebugMsgFT('c:\log\MediaInfoThread_'+IntToStr(grabThreadID)+'.txt',IntToStr(I)+'. Profile : '+sProfile);{$ENDIF} sScanType := TNT_WideLowercase(MediaInfo_Get(miHandle, Stream_Video, I, 'ScanType', Info_Text, Info_Name)); {$IFDEF LOCALTRACE}DebugMsgFT('c:\log\MediaInfoThread_'+IntToStr(grabThreadID)+'.txt',IntToStr(I)+'. ScanType : '+sScanType);{$ENDIF} sCodecID := MediaInfo_Get(miHandle, Stream_Video, I, 'CodecID' , Info_Text, Info_Name); {$IFDEF LOCALTRACE}DebugMsgFT('c:\log\MediaInfoThread_'+IntToStr(grabThreadID)+'.txt',IntToStr(I)+'. CodecID : '+sCodecID);{$ENDIF} iconResolution := MediaInfo_ResolutionToNavIcon(mWidth,mHeight,sScanType); iconVideo := MediaInfo_VideoCodecToNavIcon(sFormat,sFormatVersion,sCodecID,sProfile); mediaWidth := mWidth; mediaHeight := mHeight; End; End; End else Begin // Audio TAGs TAGs.tgTitle := UTF8Decode(MediaInfo_Get(miHandle, Stream_General, 0, 'Track' , Info_Text, Info_Name)); TAGs.tgGenre := UTF8Decode(MediaInfo_Get(miHandle, Stream_General, 0, 'Genre' , Info_Text, Info_Name)); TAGs.tgTrack := UTF8Decode(MediaInfo_Get(miHandle, Stream_General, 0, 'Track/Position' , Info_Text, Info_Name)); TAGs.tgArtist := UTF8Decode(MediaInfo_Get(miHandle, Stream_General, 0, 'Performer' , Info_Text, Info_Name)); TAGs.tgAlbum := UTF8Decode(MediaInfo_Get(miHandle, Stream_General, 0, 'Album' , Info_Text, Info_Name)); TAGs.tgYear := UTF8Decode(MediaInfo_Get(miHandle, Stream_General, 0, 'Recorded_Date' , Info_Text, Info_Name)); TAGs.tgAuthor := UTF8Decode(MediaInfo_Get(miHandle, Stream_General, 0, 'WrittenBy' , Info_Text, Info_Name)); TAGs.tgComment := UTF8Decode(MediaInfo_Get(miHandle, Stream_General, 0, 'Comment' , Info_Text, Info_Name)); TAGs.tgURL := UTF8Decode(MediaInfo_Get(miHandle, Stream_General, 0, 'Track/Url' , Info_Text, Info_Name)); TAGs.tgCopyright := UTF8Decode(MediaInfo_Get(miHandle, Stream_General, 0, 'Copyright' , Info_Text, Info_Name)); S := MediaInfo_Get(miHandle, Stream_General, 0, 'Encoded_Application', Info_Text, Info_Name); If S = '' then S := MediaInfo_Get(miHandle, Stream_General, 0, 'Encoded_Library' , Info_Text, Info_Name); TAGs.tgAuthor := UTF8Decode(S); End; // Audio Codec & Channels {$IFDEF LOCALTRACE}DebugMsgFT('c:\log\MediaInfoThread_'+IntToStr(grabThreadID)+'.txt','*** Audio Codec & Channels');{$ENDIF} mChannels := -1; aCount := MediaInfo_Count_Get(miHandle, Stream_Audio, -1); {$IFDEF LOCALTRACE}DebugMsgFT('c:\log\MediaInfoThread_'+IntToStr(grabThreadID)+'.txt','Audio Streams : '+IntToStr(aCount));{$ENDIF} For I := 0 to aCount-1 do Begin {$IFDEF LOCALTRACE}DebugMsgFT('c:\log\MediaInfoThread_'+IntToStr(grabThreadID)+'.txt',IntToStr(I)+'. Audio Stream');{$ENDIF} iCodec := -1; //sCommercialName := MediaInfo_Get(miHandle, Stream_Audio, I, 'Format_Commercial_IfAny', Info_Text, Info_Name); sFormatString := MediaInfo_Get(miHandle, Stream_Audio, I, 'Format/String' , Info_Text, Info_Name); {$IFDEF LOCALTRACE}DebugMsgFT('c:\log\MediaInfoThread_'+IntToStr(grabThreadID)+'.txt',IntToStr(I)+'. Format String : '+sFormatString);{$ENDIF} sFormat := MediaInfo_Get(miHandle, Stream_Audio, I, 'Format' , Info_Text, Info_Name); {$IFDEF LOCALTRACE}DebugMsgFT('c:\log\MediaInfoThread_'+IntToStr(grabThreadID)+'.txt',IntToStr(I)+'. Format : '+sFormat);{$ENDIF} sProfile := MediaInfo_Get(miHandle, Stream_Audio, I, 'Format_Profile', Info_Text, Info_Name); {$IFDEF LOCALTRACE}DebugMsgFT('c:\log\MediaInfoThread_'+IntToStr(grabThreadID)+'.txt',IntToStr(I)+'. Profile : '+sProfile);{$ENDIF} iChannels := MediaInfo_AudioChannelCount(MediaInfo_Get(miHandle, Stream_Audio, I, 'Channel(s)', Info_Text, Info_Name)); {$IFDEF LOCALTRACE}DebugMsgFT('c:\log\MediaInfoThread_'+IntToStr(grabThreadID)+'.txt',IntToStr(I)+'. Channels : '+IntToStr(iChannels));{$ENDIF} iCodec := MediaInfo_AudioCodecToNavIcon(sFormat,sProfile,sFormatString); If (iChannels > mChannels) or ((iconAudio = ni_codecDD ) and (iCodec in [ni_codecDTS,ni_codecDTS_ES,ni_codecDTS_HD_MA,ni_codecDD_TrueHD] = True)) or ((iconAudio = ni_codecDTS ) and (iCodec in [ni_codecDTS_ES,ni_codecDTS_HD_MA,ni_codecDD_TrueHD] = True)) or ((iconAudio = ni_codecDTS_ES ) and (iCodec in [ni_codecDTS_HD_MA,ni_codecDD_TrueHD] = True)) or ((iconAudio = ni_codecDD_TrueHD) and (iCodec in [ni_codecDTS_HD_MA] = True)) then Begin mChannels := iChannels; iconChannels := MediaInfo_AudioChannelsToNavIcon(mChannels); iconAudio := MediaInfo_AudioCodecToNavIcon(sFormat,sProfile,sFormatString); End; End; End; {$IFDEF LOCALTRACE}DebugMsgFT('c:\log\MediaInfoThread_'+IntToStr(grabThreadID)+'.txt','Close Handle');{$ENDIF} MediaInfo_Close(miHandle); End; End; {$IFDEF LOCALTRACE}DebugMsgFT('c:\log\MediaInfoThread_'+IntToStr(grabThreadID)+'.txt','MediaInfo_GetMediaInfo (after)'+CRLF);{$ENDIF} end; function MediaInfo_ProccessTAGdata(FileName : WideString; mRec : TZPFileClass; var albumArt : TBitmap) : Boolean; var miHandle : Cardinal; sImage : String; sDecoded : String; fStream : TMemoryStream; S : String; begin Result := False; If MediaInfoLoaded = True then Begin miHandle := MediaInfo_New; If MediaInfo_Open(miHandle, PWideChar(FileName)) = 1 then Begin sImage := MediaInfo_Get(miHandle, Stream_General, 0, 'Cover_Data' , Info_Text, Info_Name); If sImage <> '' then Begin sDecoded := Base64DecodeString(sImage); Result := True; fStream := TMemoryStream.Create; fStream.Write(sDecoded[1],Length(sDecoded)); fStream.Position := 0; LoadDetectedImage(fStream,albumArt); fStream.Free; End; S := MediaInfo_Get(miHandle, Stream_General, 0, 'Track' , Info_Text, Info_Name); If S = '' then S := MediaInfo_Get(miHandle, Stream_General, 0, 'Movie' , Info_Text, Info_Name); If mRec.zplTAG.tgTitle = '' then Begin If S = '' then mRec.zplTAG.tgTitle := mRec.zplName else mRec.zplTAG.tgTitle := UTF8Decode(S); End; S := MediaInfo_Get(miHandle, Stream_General, 0, 'Genre' , Info_Text, Info_Name); If (S <> '') and (mRec.zplTAG.tgGenre = '') then mRec.zplTAG.tgGenre := UTF8Decode(S); S := MediaInfo_Get(miHandle, Stream_General, 0, 'Track/Position' , Info_Text, Info_Name); If (S <> '') and (mRec.zplTAG.tgTrack = '') then mRec.zplTAG.tgTrack := FillZero(S,2); S := MediaInfo_Get(miHandle, Stream_General, 0, 'Performer' , Info_Text, Info_Name); If (S <> '') and (mRec.zplTAG.tgArtist = '') then mRec.zplTAG.tgArtist := UTF8Decode(S); S := MediaInfo_Get(miHandle, Stream_General, 0, 'Album' , Info_Text, Info_Name); If (S <> '') and (mRec.zplTAG.tgAlbum = '') then mRec.zplTAG.tgAlbum := UTF8Decode(S); S := MediaInfo_Get(miHandle, Stream_General, 0, 'Recorded_Date' , Info_Text, Info_Name); If (S <> '') and (mRec.zplTAG.tgYear = '') then mRec.zplTAG.tgYear := UTF8Decode(S); S := MediaInfo_Get(miHandle, Stream_General, 0, 'WrittenBy' , Info_Text, Info_Name); If (S <> '') and (mRec.zplTAG.tgAuthor = '') then mRec.zplTAG.tgAuthor := UTF8Decode(S); S := MediaInfo_Get(miHandle, Stream_General, 0, 'Encoded_Application', Info_Text, Info_Name); If S = '' then S := MediaInfo_Get(miHandle, Stream_General, 0, 'Encoded_Library' , Info_Text, Info_Name); If (S <> '') and (mRec.zplTAG.tgEncoder = '') then mRec.zplTAG.tgEncoder := UTF8Decode(S); S := MediaInfo_Get(miHandle, Stream_General, 0, 'Comment' , Info_Text, Info_Name); If (S <> '') and (mRec.zplTAG.tgComment = '') then mRec.zplTAG.tgComment := UTF8Decode(S); S := MediaInfo_Get(miHandle, Stream_General, 0, 'Track/Url' , Info_Text, Info_Name); If (S <> '') and (mRec.zplTAG.tgURL = '') then mRec.zplTAG.tgURL := UTF8Decode(S); S := MediaInfo_Get(miHandle, Stream_General, 0, 'Copyright' , Info_Text, Info_Name); If (S <> '') and (mRec.zplTAG.tgCopyright = '') then mRec.zplTAG.tgCopyright := UTF8Decode(S); SendLCDs(2400,strNoMoreData); End; MediaInfo_Close(miHandle); End; end;
  13. I'm the author of Zoom Player a Windows media player/home theater application. One of Zoom Player's features is that it scrapes information on the video file using multiple mechanism. Two of these mechanisms are somehow severely lagging my user interface even though I'm running the code in separate threads with Idle priority: 1. Running MediaInfo.dll on the media file. 2. Using a non-visual background directshow graph using LAV Filters (directshow filters) to extract a video frame from the video. Other than moving this functionality to completely separate processes, is there a method to ensure my UI (running in the main thread) remains responsive?
  14. Yaron

    Could not load OpenSSL library.

    I placed another copy of the DLLs under "Windows/SysWow64" and now it seems to find the DLLs. It would help debugging if calling "WhichFailedToLoad" or possibly the InnerException would return the GetLastError value from the LoadLibrary function.
  15. Yaron

    Could not load OpenSSL library.

    Running the same code on the server, GetLastError returns #126 "ERROR_MOD_NOT_FOUND", however the OpenSSL DLLs are both in the same path as the running DLL and in the Windows/System32 folder.
×