VirtualBox

Changeset 75391 in vbox


Ignore:
Timestamp:
Nov 12, 2018 9:22:42 AM (6 years ago)
Author:
vboxsync
svn:sync-xref-src-repo-rev:
126526
Message:

Recording/Main: Logging.

Location:
trunk/src/VBox/Main/src-client
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Main/src-client/Recording.cpp

    r75361 r75391  
    145145
    146146        if (RT_FAILURE(rc))
    147             LogRel(("Recording: Encoding thread failed with rc=%Rrc\n", rc));
     147            LogRel(("Recording: Encoding thread failed (%Rrc)\n", rc));
    148148
    149149        /* Keep going in case of errors. */
     
    238238    if (RT_SUCCESS(rc))
    239239    {
     240        LogRel(("Recording: Started\n"));
    240241        this->enmState = RECORDINGSTS_STARTED;
    241242    }
     243    else
     244        Log(("Recording: Failed to start (%Rrc)\n", rc));
    242245
    243246    return rc;
     
    261264    if (RT_SUCCESS(rc))
    262265    {
     266        LogRel(("Recording: Stopped\n"));
    263267        this->enmState = RECORDINGSTS_CREATED;
    264268    }
     269    else
     270        Log(("Recording: Failed to stop (%Rrc)\n", rc));
    265271
    266272    LogFlowThisFunc(("%Rrc\n", rc));
  • trunk/src/VBox/Main/src-client/RecordingStream.cpp

    r75361 r75391  
    200200            else
    201201            {
    202                 LogRel(("Recording: Setting encoder deadline to '%s'\n", value.c_str()));
    203202                this->Video.Codec.VPX.uEncoderDeadline = value.toUInt32();
    204203#endif
     
    208207        {
    209208            if (value.compare("false", Utf8Str::CaseInsensitive) == 0)
    210             {
    211209                this->ScreenSettings.featureMap[RecordingFeature_Video] = false;
    212 #ifdef VBOX_WITH_AUDIO_RECORDING
    213                 LogRel(("Recording: Only audio will be recorded\n"));
    214 #endif
    215             }
    216210        }
    217211        else if (key.compare("ac_enabled", Utf8Str::CaseInsensitive) == 0)
     
    219213#ifdef VBOX_WITH_AUDIO_RECORDING
    220214            if (value.compare("true", Utf8Str::CaseInsensitive) == 0)
    221             {
    222215                this->ScreenSettings.featureMap[RecordingFeature_Audio] = true;
    223             }
    224             else
    225                 LogRel(("Recording: Only video will be recorded\n"));
    226216#endif
    227217        }
     
    692682
    693683    if (fVideoEnabled)
     684    {
    694685        rc = initVideo();
     686        if (RT_FAILURE(rc))
     687            return rc;
     688    }
    695689
    696690    if (fAudioEnabled)
     691    {
    697692        rc = initAudio();
     693        if (RT_FAILURE(rc))
     694            return rc;
     695    }
    698696
    699697    switch (this->ScreenSettings.enmDest)
     
    715713            if (RT_FAILURE(rc))
    716714            {
    717                 LogRel(("Recording: Failed to create the capture output file '%s' (%Rrc)\n", pszFile, rc));
     715                LogRel(("Recording: Failed to create output file '%s' (%Rrc)\n", pszFile, rc));
    718716                break;
    719717            }
     
    745743                }
    746744
    747                 LogRel(("Recording: Recording audio in %RU16Hz, %RU8 bit, %RU8 %s (track #%RU8)\n",
    748                         Settings.Audio.uHz, Settings.Audio.cBits, Settings.Audio.cChannels,
     745                LogRel(("Recording: Recording audio of screen #%u in %RU16Hz, %RU8 bit, %RU8 %s (track #%RU8)\n",
     746                        this->uScreenID, Settings.Audio.uHz, Settings.Audio.cBits, Settings.Audio.cChannels,
    749747                        Settings.Audio.cChannels ? "channels" : "channel", this->uTrackAudio));
    750748            }
     
    768766                }
    769767#endif
    770                 LogRel(("Recording: Recording %s to '%s'\n", szWhat, pszFile));
     768                LogRel(("Recording: Recording %s of screen #%u to '%s'\n", szWhat, this->uScreenID, pszFile));
    771769            }
    772770
     
    956954    this->Video.uDelayMs = RT_MS_1SEC / this->ScreenSettings.Video.ulFPS;
    957955
     956    int rc;
     957
    958958#ifdef VBOX_WITH_LIBVPX
    959959    /* At the moment we only have VPX. */
    960     return initVideoVPX();
     960    rc = initVideoVPX();
    961961#else
    962     return VINF_SUCCESS;
    963 #endif
     962    rc = VINF_SUCCESS;
     963#endif
     964
     965    if (RT_FAILURE(rc))
     966        LogRel(("Recording: Failed to initialize video encoding (%Rrc)\n", rc));
     967
     968    return rc;
    964969}
    965970
Note: See TracChangeset for help on using the changeset viewer.

© 2025 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette