UI: Implement transitions and preview/program mode
Implements transitions, and introduces "Studio Mode" which allows live
editing of the same or different scenes while preserving what's
currently being displayed.
Studio Mode offers a number of new features:
- The ability to edit different scenes or the same scene without
modifying what's currently being displayed (of course)
- The ability to set up "quick transitions" with a desired transition
and duration that can be assigned hotkeys
- The option to create full copies of all sources in the program scene
to allow editing of source properties of the same scene live without
modifying the output, or (by default) just use references. (Note
however that certain sources cannot be duplicated, such as capture
sources, media sources, and device sources)
- Swap Mode (enabled by default) which swaps the program scene with
the preview scene when a transition completes
Currently, only non-configurable transitions (transitions without
properties) are listed, and the only transitions available as of this
writing are fade and cut. In future versions more transitions will be
added, such as swipe, stingers, and many other various sort of
transitions, and the UI will support being able to add/configure/remove
those sort of configurable transitions.
2016-01-23 11:19:29 -08:00
|
|
|
/******************************************************************************
|
2023-05-18 17:37:26 -07:00
|
|
|
Copyright (C) 2023 by Lain Bailey <lain@obsproject.com>
|
2025-01-08 17:35:16 +01:00
|
|
|
Zachary Lund <admin@computerquip.com>
|
|
|
|
|
Philippe Groarke <philippe.groarke@gmail.com>
|
UI: Implement transitions and preview/program mode
Implements transitions, and introduces "Studio Mode" which allows live
editing of the same or different scenes while preserving what's
currently being displayed.
Studio Mode offers a number of new features:
- The ability to edit different scenes or the same scene without
modifying what's currently being displayed (of course)
- The ability to set up "quick transitions" with a desired transition
and duration that can be assigned hotkeys
- The option to create full copies of all sources in the program scene
to allow editing of source properties of the same scene live without
modifying the output, or (by default) just use references. (Note
however that certain sources cannot be duplicated, such as capture
sources, media sources, and device sources)
- Swap Mode (enabled by default) which swaps the program scene with
the preview scene when a transition completes
Currently, only non-configurable transitions (transitions without
properties) are listed, and the only transitions available as of this
writing are fade and cut. In future versions more transitions will be
added, such as swipe, stingers, and many other various sort of
transitions, and the UI will support being able to add/configure/remove
those sort of configurable transitions.
2016-01-23 11:19:29 -08:00
|
|
|
|
|
|
|
|
This program is free software: you can redistribute it and/or modify
|
|
|
|
|
it under the terms of the GNU General Public License as published by
|
|
|
|
|
the Free Software Foundation, either version 2 of the License, or
|
|
|
|
|
(at your option) any later version.
|
|
|
|
|
|
|
|
|
|
This program is distributed in the hope that it will be useful,
|
|
|
|
|
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
|
|
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
|
|
|
GNU General Public License for more details.
|
|
|
|
|
|
|
|
|
|
You should have received a copy of the GNU General Public License
|
|
|
|
|
along with this program. If not, see <http://www.gnu.org/licenses/>.
|
|
|
|
|
******************************************************************************/
|
|
|
|
|
|
2025-01-08 17:35:16 +01:00
|
|
|
#include "OBSBasic.hpp"
|
|
|
|
|
#include "OBSProjector.hpp"
|
UI: Implement transitions and preview/program mode
Implements transitions, and introduces "Studio Mode" which allows live
editing of the same or different scenes while preserving what's
currently being displayed.
Studio Mode offers a number of new features:
- The ability to edit different scenes or the same scene without
modifying what's currently being displayed (of course)
- The ability to set up "quick transitions" with a desired transition
and duration that can be assigned hotkeys
- The option to create full copies of all sources in the program scene
to allow editing of source properties of the same scene live without
modifying the output, or (by default) just use references. (Note
however that certain sources cannot be duplicated, such as capture
sources, media sources, and device sources)
- Swap Mode (enabled by default) which swaps the program scene with
the preview scene when a transition completes
Currently, only non-configurable transitions (transitions without
properties) are listed, and the only transitions available as of this
writing are fade and cut. In future versions more transitions will be
added, such as swipe, stingers, and many other various sort of
transitions, and the UI will support being able to add/configure/remove
those sort of configurable transitions.
2016-01-23 11:19:29 -08:00
|
|
|
|
2025-01-08 17:35:16 +01:00
|
|
|
#include <utility/display-helpers.hpp>
|
|
|
|
|
#include <utility/QuickTransition.hpp>
|
2019-10-23 16:11:14 -05:00
|
|
|
|
2025-01-08 17:35:16 +01:00
|
|
|
#include <qt-wrappers.hpp>
|
|
|
|
|
#include <slider-ignorewheel.hpp>
|
2019-10-23 16:11:14 -05:00
|
|
|
|
2025-01-08 17:35:16 +01:00
|
|
|
#include <QToolTip>
|
UI: Implement transitions and preview/program mode
Implements transitions, and introduces "Studio Mode" which allows live
editing of the same or different scenes while preserving what's
currently being displayed.
Studio Mode offers a number of new features:
- The ability to edit different scenes or the same scene without
modifying what's currently being displayed (of course)
- The ability to set up "quick transitions" with a desired transition
and duration that can be assigned hotkeys
- The option to create full copies of all sources in the program scene
to allow editing of source properties of the same scene live without
modifying the output, or (by default) just use references. (Note
however that certain sources cannot be duplicated, such as capture
sources, media sources, and device sources)
- Swap Mode (enabled by default) which swaps the program scene with
the preview scene when a transition completes
Currently, only non-configurable transitions (transitions without
properties) are listed, and the only transitions available as of this
writing are fade and cut. In future versions more transitions will be
added, such as swipe, stingers, and many other various sort of
transitions, and the UI will support being able to add/configure/remove
those sort of configurable transitions.
2016-01-23 11:19:29 -08:00
|
|
|
|
2025-01-08 17:35:16 +01:00
|
|
|
void OBSBasic::CreateProgramDisplay()
|
UI: Implement transitions and preview/program mode
Implements transitions, and introduces "Studio Mode" which allows live
editing of the same or different scenes while preserving what's
currently being displayed.
Studio Mode offers a number of new features:
- The ability to edit different scenes or the same scene without
modifying what's currently being displayed (of course)
- The ability to set up "quick transitions" with a desired transition
and duration that can be assigned hotkeys
- The option to create full copies of all sources in the program scene
to allow editing of source properties of the same scene live without
modifying the output, or (by default) just use references. (Note
however that certain sources cannot be duplicated, such as capture
sources, media sources, and device sources)
- Swap Mode (enabled by default) which swaps the program scene with
the preview scene when a transition completes
Currently, only non-configurable transitions (transitions without
properties) are listed, and the only transitions available as of this
writing are fade and cut. In future versions more transitions will be
added, such as swipe, stingers, and many other various sort of
transitions, and the UI will support being able to add/configure/remove
those sort of configurable transitions.
2016-01-23 11:19:29 -08:00
|
|
|
{
|
2025-01-08 17:35:16 +01:00
|
|
|
program = new OBSQTDisplay();
|
UI: Implement transitions and preview/program mode
Implements transitions, and introduces "Studio Mode" which allows live
editing of the same or different scenes while preserving what's
currently being displayed.
Studio Mode offers a number of new features:
- The ability to edit different scenes or the same scene without
modifying what's currently being displayed (of course)
- The ability to set up "quick transitions" with a desired transition
and duration that can be assigned hotkeys
- The option to create full copies of all sources in the program scene
to allow editing of source properties of the same scene live without
modifying the output, or (by default) just use references. (Note
however that certain sources cannot be duplicated, such as capture
sources, media sources, and device sources)
- Swap Mode (enabled by default) which swaps the program scene with
the preview scene when a transition completes
Currently, only non-configurable transitions (transitions without
properties) are listed, and the only transitions available as of this
writing are fade and cut. In future versions more transitions will be
added, such as swipe, stingers, and many other various sort of
transitions, and the UI will support being able to add/configure/remove
those sort of configurable transitions.
2016-01-23 11:19:29 -08:00
|
|
|
|
2025-01-08 17:35:16 +01:00
|
|
|
program->setContextMenuPolicy(Qt::CustomContextMenu);
|
|
|
|
|
connect(program.data(), &QWidget::customContextMenuRequested, this, &OBSBasic::ProgramViewContextMenuRequested);
|
UI: Implement transitions and preview/program mode
Implements transitions, and introduces "Studio Mode" which allows live
editing of the same or different scenes while preserving what's
currently being displayed.
Studio Mode offers a number of new features:
- The ability to edit different scenes or the same scene without
modifying what's currently being displayed (of course)
- The ability to set up "quick transitions" with a desired transition
and duration that can be assigned hotkeys
- The option to create full copies of all sources in the program scene
to allow editing of source properties of the same scene live without
modifying the output, or (by default) just use references. (Note
however that certain sources cannot be duplicated, such as capture
sources, media sources, and device sources)
- Swap Mode (enabled by default) which swaps the program scene with
the preview scene when a transition completes
Currently, only non-configurable transitions (transitions without
properties) are listed, and the only transitions available as of this
writing are fade and cut. In future versions more transitions will be
added, such as swipe, stingers, and many other various sort of
transitions, and the UI will support being able to add/configure/remove
those sort of configurable transitions.
2016-01-23 11:19:29 -08:00
|
|
|
|
2025-01-08 17:35:16 +01:00
|
|
|
auto displayResize = [this]() {
|
|
|
|
|
struct obs_video_info ovi;
|
UI: Implement transitions and preview/program mode
Implements transitions, and introduces "Studio Mode" which allows live
editing of the same or different scenes while preserving what's
currently being displayed.
Studio Mode offers a number of new features:
- The ability to edit different scenes or the same scene without
modifying what's currently being displayed (of course)
- The ability to set up "quick transitions" with a desired transition
and duration that can be assigned hotkeys
- The option to create full copies of all sources in the program scene
to allow editing of source properties of the same scene live without
modifying the output, or (by default) just use references. (Note
however that certain sources cannot be duplicated, such as capture
sources, media sources, and device sources)
- Swap Mode (enabled by default) which swaps the program scene with
the preview scene when a transition completes
Currently, only non-configurable transitions (transitions without
properties) are listed, and the only transitions available as of this
writing are fade and cut. In future versions more transitions will be
added, such as swipe, stingers, and many other various sort of
transitions, and the UI will support being able to add/configure/remove
those sort of configurable transitions.
2016-01-23 11:19:29 -08:00
|
|
|
|
2025-01-08 17:35:16 +01:00
|
|
|
if (obs_get_video_info(&ovi))
|
|
|
|
|
ResizeProgram(ovi.base_width, ovi.base_height);
|
|
|
|
|
};
|
UI: Implement transitions and preview/program mode
Implements transitions, and introduces "Studio Mode" which allows live
editing of the same or different scenes while preserving what's
currently being displayed.
Studio Mode offers a number of new features:
- The ability to edit different scenes or the same scene without
modifying what's currently being displayed (of course)
- The ability to set up "quick transitions" with a desired transition
and duration that can be assigned hotkeys
- The option to create full copies of all sources in the program scene
to allow editing of source properties of the same scene live without
modifying the output, or (by default) just use references. (Note
however that certain sources cannot be duplicated, such as capture
sources, media sources, and device sources)
- Swap Mode (enabled by default) which swaps the program scene with
the preview scene when a transition completes
Currently, only non-configurable transitions (transitions without
properties) are listed, and the only transitions available as of this
writing are fade and cut. In future versions more transitions will be
added, such as swipe, stingers, and many other various sort of
transitions, and the UI will support being able to add/configure/remove
those sort of configurable transitions.
2016-01-23 11:19:29 -08:00
|
|
|
|
2025-01-08 17:35:16 +01:00
|
|
|
connect(program.data(), &OBSQTDisplay::DisplayResized, displayResize);
|
UI: Implement transitions and preview/program mode
Implements transitions, and introduces "Studio Mode" which allows live
editing of the same or different scenes while preserving what's
currently being displayed.
Studio Mode offers a number of new features:
- The ability to edit different scenes or the same scene without
modifying what's currently being displayed (of course)
- The ability to set up "quick transitions" with a desired transition
and duration that can be assigned hotkeys
- The option to create full copies of all sources in the program scene
to allow editing of source properties of the same scene live without
modifying the output, or (by default) just use references. (Note
however that certain sources cannot be duplicated, such as capture
sources, media sources, and device sources)
- Swap Mode (enabled by default) which swaps the program scene with
the preview scene when a transition completes
Currently, only non-configurable transitions (transitions without
properties) are listed, and the only transitions available as of this
writing are fade and cut. In future versions more transitions will be
added, such as swipe, stingers, and many other various sort of
transitions, and the UI will support being able to add/configure/remove
those sort of configurable transitions.
2016-01-23 11:19:29 -08:00
|
|
|
|
2025-01-08 17:35:16 +01:00
|
|
|
auto addDisplay = [this](OBSQTDisplay *window) {
|
|
|
|
|
obs_display_add_draw_callback(window->GetDisplay(), OBSBasic::RenderProgram, this);
|
UI: Implement transitions and preview/program mode
Implements transitions, and introduces "Studio Mode" which allows live
editing of the same or different scenes while preserving what's
currently being displayed.
Studio Mode offers a number of new features:
- The ability to edit different scenes or the same scene without
modifying what's currently being displayed (of course)
- The ability to set up "quick transitions" with a desired transition
and duration that can be assigned hotkeys
- The option to create full copies of all sources in the program scene
to allow editing of source properties of the same scene live without
modifying the output, or (by default) just use references. (Note
however that certain sources cannot be duplicated, such as capture
sources, media sources, and device sources)
- Swap Mode (enabled by default) which swaps the program scene with
the preview scene when a transition completes
Currently, only non-configurable transitions (transitions without
properties) are listed, and the only transitions available as of this
writing are fade and cut. In future versions more transitions will be
added, such as swipe, stingers, and many other various sort of
transitions, and the UI will support being able to add/configure/remove
those sort of configurable transitions.
2016-01-23 11:19:29 -08:00
|
|
|
|
2025-01-08 17:35:16 +01:00
|
|
|
struct obs_video_info ovi;
|
|
|
|
|
if (obs_get_video_info(&ovi))
|
|
|
|
|
ResizeProgram(ovi.base_width, ovi.base_height);
|
UI: Implement transitions and preview/program mode
Implements transitions, and introduces "Studio Mode" which allows live
editing of the same or different scenes while preserving what's
currently being displayed.
Studio Mode offers a number of new features:
- The ability to edit different scenes or the same scene without
modifying what's currently being displayed (of course)
- The ability to set up "quick transitions" with a desired transition
and duration that can be assigned hotkeys
- The option to create full copies of all sources in the program scene
to allow editing of source properties of the same scene live without
modifying the output, or (by default) just use references. (Note
however that certain sources cannot be duplicated, such as capture
sources, media sources, and device sources)
- Swap Mode (enabled by default) which swaps the program scene with
the preview scene when a transition completes
Currently, only non-configurable transitions (transitions without
properties) are listed, and the only transitions available as of this
writing are fade and cut. In future versions more transitions will be
added, such as swipe, stingers, and many other various sort of
transitions, and the UI will support being able to add/configure/remove
those sort of configurable transitions.
2016-01-23 11:19:29 -08:00
|
|
|
};
|
|
|
|
|
|
2025-01-08 17:35:16 +01:00
|
|
|
connect(program.data(), &OBSQTDisplay::DisplayCreated, addDisplay);
|
2018-05-29 04:24:30 +03:00
|
|
|
|
2025-01-08 17:35:16 +01:00
|
|
|
program->setSizePolicy(QSizePolicy::Expanding, QSizePolicy::Expanding);
|
2018-05-29 04:24:30 +03:00
|
|
|
}
|
|
|
|
|
|
2025-01-08 17:35:16 +01:00
|
|
|
#define T_BAR_PRECISION 1024
|
|
|
|
|
#define T_BAR_PRECISION_F ((float)T_BAR_PRECISION)
|
|
|
|
|
#define T_BAR_CLAMP (T_BAR_PRECISION / 10)
|
UI: Implement transitions and preview/program mode
Implements transitions, and introduces "Studio Mode" which allows live
editing of the same or different scenes while preserving what's
currently being displayed.
Studio Mode offers a number of new features:
- The ability to edit different scenes or the same scene without
modifying what's currently being displayed (of course)
- The ability to set up "quick transitions" with a desired transition
and duration that can be assigned hotkeys
- The option to create full copies of all sources in the program scene
to allow editing of source properties of the same scene live without
modifying the output, or (by default) just use references. (Note
however that certain sources cannot be duplicated, such as capture
sources, media sources, and device sources)
- Swap Mode (enabled by default) which swaps the program scene with
the preview scene when a transition completes
Currently, only non-configurable transitions (transitions without
properties) are listed, and the only transitions available as of this
writing are fade and cut. In future versions more transitions will be
added, such as swipe, stingers, and many other various sort of
transitions, and the UI will support being able to add/configure/remove
those sort of configurable transitions.
2016-01-23 11:19:29 -08:00
|
|
|
|
2025-01-08 17:35:16 +01:00
|
|
|
void OBSBasic::CreateProgramOptions()
|
UI: Implement transitions and preview/program mode
Implements transitions, and introduces "Studio Mode" which allows live
editing of the same or different scenes while preserving what's
currently being displayed.
Studio Mode offers a number of new features:
- The ability to edit different scenes or the same scene without
modifying what's currently being displayed (of course)
- The ability to set up "quick transitions" with a desired transition
and duration that can be assigned hotkeys
- The option to create full copies of all sources in the program scene
to allow editing of source properties of the same scene live without
modifying the output, or (by default) just use references. (Note
however that certain sources cannot be duplicated, such as capture
sources, media sources, and device sources)
- Swap Mode (enabled by default) which swaps the program scene with
the preview scene when a transition completes
Currently, only non-configurable transitions (transitions without
properties) are listed, and the only transitions available as of this
writing are fade and cut. In future versions more transitions will be
added, such as swipe, stingers, and many other various sort of
transitions, and the UI will support being able to add/configure/remove
those sort of configurable transitions.
2016-01-23 11:19:29 -08:00
|
|
|
{
|
2025-01-08 17:35:16 +01:00
|
|
|
programOptions = new QWidget();
|
|
|
|
|
QVBoxLayout *layout = new QVBoxLayout();
|
|
|
|
|
layout->setSpacing(4);
|
UI: Implement transitions and preview/program mode
Implements transitions, and introduces "Studio Mode" which allows live
editing of the same or different scenes while preserving what's
currently being displayed.
Studio Mode offers a number of new features:
- The ability to edit different scenes or the same scene without
modifying what's currently being displayed (of course)
- The ability to set up "quick transitions" with a desired transition
and duration that can be assigned hotkeys
- The option to create full copies of all sources in the program scene
to allow editing of source properties of the same scene live without
modifying the output, or (by default) just use references. (Note
however that certain sources cannot be duplicated, such as capture
sources, media sources, and device sources)
- Swap Mode (enabled by default) which swaps the program scene with
the preview scene when a transition completes
Currently, only non-configurable transitions (transitions without
properties) are listed, and the only transitions available as of this
writing are fade and cut. In future versions more transitions will be
added, such as swipe, stingers, and many other various sort of
transitions, and the UI will support being able to add/configure/remove
those sort of configurable transitions.
2016-01-23 11:19:29 -08:00
|
|
|
|
2025-01-08 17:35:16 +01:00
|
|
|
QPushButton *configTransitions = new QPushButton();
|
|
|
|
|
configTransitions->setProperty("class", "icon-dots-vert");
|
UI: Implement transitions and preview/program mode
Implements transitions, and introduces "Studio Mode" which allows live
editing of the same or different scenes while preserving what's
currently being displayed.
Studio Mode offers a number of new features:
- The ability to edit different scenes or the same scene without
modifying what's currently being displayed (of course)
- The ability to set up "quick transitions" with a desired transition
and duration that can be assigned hotkeys
- The option to create full copies of all sources in the program scene
to allow editing of source properties of the same scene live without
modifying the output, or (by default) just use references. (Note
however that certain sources cannot be duplicated, such as capture
sources, media sources, and device sources)
- Swap Mode (enabled by default) which swaps the program scene with
the preview scene when a transition completes
Currently, only non-configurable transitions (transitions without
properties) are listed, and the only transitions available as of this
writing are fade and cut. In future versions more transitions will be
added, such as swipe, stingers, and many other various sort of
transitions, and the UI will support being able to add/configure/remove
those sort of configurable transitions.
2016-01-23 11:19:29 -08:00
|
|
|
|
2025-01-08 17:35:16 +01:00
|
|
|
QHBoxLayout *mainButtonLayout = new QHBoxLayout();
|
|
|
|
|
mainButtonLayout->setSpacing(2);
|
2017-11-30 05:05:50 -08:00
|
|
|
|
2025-01-08 17:35:16 +01:00
|
|
|
transitionButton = new QPushButton(QTStr("Transition"));
|
|
|
|
|
transitionButton->setSizePolicy(QSizePolicy::Expanding, QSizePolicy::Preferred);
|
UI: Implement transitions and preview/program mode
Implements transitions, and introduces "Studio Mode" which allows live
editing of the same or different scenes while preserving what's
currently being displayed.
Studio Mode offers a number of new features:
- The ability to edit different scenes or the same scene without
modifying what's currently being displayed (of course)
- The ability to set up "quick transitions" with a desired transition
and duration that can be assigned hotkeys
- The option to create full copies of all sources in the program scene
to allow editing of source properties of the same scene live without
modifying the output, or (by default) just use references. (Note
however that certain sources cannot be duplicated, such as capture
sources, media sources, and device sources)
- Swap Mode (enabled by default) which swaps the program scene with
the preview scene when a transition completes
Currently, only non-configurable transitions (transitions without
properties) are listed, and the only transitions available as of this
writing are fade and cut. In future versions more transitions will be
added, such as swipe, stingers, and many other various sort of
transitions, and the UI will support being able to add/configure/remove
those sort of configurable transitions.
2016-01-23 11:19:29 -08:00
|
|
|
|
2025-01-08 17:35:16 +01:00
|
|
|
QHBoxLayout *quickTransitions = new QHBoxLayout();
|
|
|
|
|
quickTransitions->setSpacing(2);
|
UI: Implement transitions and preview/program mode
Implements transitions, and introduces "Studio Mode" which allows live
editing of the same or different scenes while preserving what's
currently being displayed.
Studio Mode offers a number of new features:
- The ability to edit different scenes or the same scene without
modifying what's currently being displayed (of course)
- The ability to set up "quick transitions" with a desired transition
and duration that can be assigned hotkeys
- The option to create full copies of all sources in the program scene
to allow editing of source properties of the same scene live without
modifying the output, or (by default) just use references. (Note
however that certain sources cannot be duplicated, such as capture
sources, media sources, and device sources)
- Swap Mode (enabled by default) which swaps the program scene with
the preview scene when a transition completes
Currently, only non-configurable transitions (transitions without
properties) are listed, and the only transitions available as of this
writing are fade and cut. In future versions more transitions will be
added, such as swipe, stingers, and many other various sort of
transitions, and the UI will support being able to add/configure/remove
those sort of configurable transitions.
2016-01-23 11:19:29 -08:00
|
|
|
|
2025-01-08 17:35:16 +01:00
|
|
|
QPushButton *addQuickTransition = new QPushButton();
|
|
|
|
|
addQuickTransition->setProperty("class", "icon-plus");
|
UI: Implement transitions and preview/program mode
Implements transitions, and introduces "Studio Mode" which allows live
editing of the same or different scenes while preserving what's
currently being displayed.
Studio Mode offers a number of new features:
- The ability to edit different scenes or the same scene without
modifying what's currently being displayed (of course)
- The ability to set up "quick transitions" with a desired transition
and duration that can be assigned hotkeys
- The option to create full copies of all sources in the program scene
to allow editing of source properties of the same scene live without
modifying the output, or (by default) just use references. (Note
however that certain sources cannot be duplicated, such as capture
sources, media sources, and device sources)
- Swap Mode (enabled by default) which swaps the program scene with
the preview scene when a transition completes
Currently, only non-configurable transitions (transitions without
properties) are listed, and the only transitions available as of this
writing are fade and cut. In future versions more transitions will be
added, such as swipe, stingers, and many other various sort of
transitions, and the UI will support being able to add/configure/remove
those sort of configurable transitions.
2016-01-23 11:19:29 -08:00
|
|
|
|
2025-01-08 17:35:16 +01:00
|
|
|
QLabel *quickTransitionsLabel = new QLabel(QTStr("QuickTransitions"));
|
|
|
|
|
quickTransitionsLabel->setSizePolicy(QSizePolicy::Expanding, QSizePolicy::Preferred);
|
UI: Implement transitions and preview/program mode
Implements transitions, and introduces "Studio Mode" which allows live
editing of the same or different scenes while preserving what's
currently being displayed.
Studio Mode offers a number of new features:
- The ability to edit different scenes or the same scene without
modifying what's currently being displayed (of course)
- The ability to set up "quick transitions" with a desired transition
and duration that can be assigned hotkeys
- The option to create full copies of all sources in the program scene
to allow editing of source properties of the same scene live without
modifying the output, or (by default) just use references. (Note
however that certain sources cannot be duplicated, such as capture
sources, media sources, and device sources)
- Swap Mode (enabled by default) which swaps the program scene with
the preview scene when a transition completes
Currently, only non-configurable transitions (transitions without
properties) are listed, and the only transitions available as of this
writing are fade and cut. In future versions more transitions will be
added, such as swipe, stingers, and many other various sort of
transitions, and the UI will support being able to add/configure/remove
those sort of configurable transitions.
2016-01-23 11:19:29 -08:00
|
|
|
|
2025-01-08 17:35:16 +01:00
|
|
|
quickTransitions->addWidget(quickTransitionsLabel);
|
|
|
|
|
quickTransitions->addWidget(addQuickTransition);
|
UI: Implement transitions and preview/program mode
Implements transitions, and introduces "Studio Mode" which allows live
editing of the same or different scenes while preserving what's
currently being displayed.
Studio Mode offers a number of new features:
- The ability to edit different scenes or the same scene without
modifying what's currently being displayed (of course)
- The ability to set up "quick transitions" with a desired transition
and duration that can be assigned hotkeys
- The option to create full copies of all sources in the program scene
to allow editing of source properties of the same scene live without
modifying the output, or (by default) just use references. (Note
however that certain sources cannot be duplicated, such as capture
sources, media sources, and device sources)
- Swap Mode (enabled by default) which swaps the program scene with
the preview scene when a transition completes
Currently, only non-configurable transitions (transitions without
properties) are listed, and the only transitions available as of this
writing are fade and cut. In future versions more transitions will be
added, such as swipe, stingers, and many other various sort of
transitions, and the UI will support being able to add/configure/remove
those sort of configurable transitions.
2016-01-23 11:19:29 -08:00
|
|
|
|
2025-01-08 17:35:16 +01:00
|
|
|
mainButtonLayout->addWidget(transitionButton);
|
|
|
|
|
mainButtonLayout->addWidget(configTransitions);
|
UI: Implement transitions and preview/program mode
Implements transitions, and introduces "Studio Mode" which allows live
editing of the same or different scenes while preserving what's
currently being displayed.
Studio Mode offers a number of new features:
- The ability to edit different scenes or the same scene without
modifying what's currently being displayed (of course)
- The ability to set up "quick transitions" with a desired transition
and duration that can be assigned hotkeys
- The option to create full copies of all sources in the program scene
to allow editing of source properties of the same scene live without
modifying the output, or (by default) just use references. (Note
however that certain sources cannot be duplicated, such as capture
sources, media sources, and device sources)
- Swap Mode (enabled by default) which swaps the program scene with
the preview scene when a transition completes
Currently, only non-configurable transitions (transitions without
properties) are listed, and the only transitions available as of this
writing are fade and cut. In future versions more transitions will be
added, such as swipe, stingers, and many other various sort of
transitions, and the UI will support being able to add/configure/remove
those sort of configurable transitions.
2016-01-23 11:19:29 -08:00
|
|
|
|
2025-01-08 17:35:16 +01:00
|
|
|
tBar = new SliderIgnoreClick(Qt::Horizontal);
|
|
|
|
|
tBar->setMinimum(0);
|
|
|
|
|
tBar->setMaximum(T_BAR_PRECISION - 1);
|
2016-03-01 15:16:23 -08:00
|
|
|
|
2025-01-08 17:35:16 +01:00
|
|
|
tBar->setProperty("class", "slider-tbar");
|
2016-03-01 15:16:23 -08:00
|
|
|
|
2025-01-08 17:35:16 +01:00
|
|
|
connect(tBar, &QSlider::valueChanged, this, &OBSBasic::TBarChanged);
|
|
|
|
|
connect(tBar, &QSlider::sliderReleased, this, &OBSBasic::TBarReleased);
|
UI: Implement transitions and preview/program mode
Implements transitions, and introduces "Studio Mode" which allows live
editing of the same or different scenes while preserving what's
currently being displayed.
Studio Mode offers a number of new features:
- The ability to edit different scenes or the same scene without
modifying what's currently being displayed (of course)
- The ability to set up "quick transitions" with a desired transition
and duration that can be assigned hotkeys
- The option to create full copies of all sources in the program scene
to allow editing of source properties of the same scene live without
modifying the output, or (by default) just use references. (Note
however that certain sources cannot be duplicated, such as capture
sources, media sources, and device sources)
- Swap Mode (enabled by default) which swaps the program scene with
the preview scene when a transition completes
Currently, only non-configurable transitions (transitions without
properties) are listed, and the only transitions available as of this
writing are fade and cut. In future versions more transitions will be
added, such as swipe, stingers, and many other various sort of
transitions, and the UI will support being able to add/configure/remove
those sort of configurable transitions.
2016-01-23 11:19:29 -08:00
|
|
|
|
2025-01-08 17:35:16 +01:00
|
|
|
layout->addStretch(0);
|
|
|
|
|
layout->addLayout(mainButtonLayout);
|
|
|
|
|
layout->addLayout(quickTransitions);
|
|
|
|
|
layout->addWidget(tBar);
|
|
|
|
|
layout->addStretch(0);
|
UI: Implement transitions and preview/program mode
Implements transitions, and introduces "Studio Mode" which allows live
editing of the same or different scenes while preserving what's
currently being displayed.
Studio Mode offers a number of new features:
- The ability to edit different scenes or the same scene without
modifying what's currently being displayed (of course)
- The ability to set up "quick transitions" with a desired transition
and duration that can be assigned hotkeys
- The option to create full copies of all sources in the program scene
to allow editing of source properties of the same scene live without
modifying the output, or (by default) just use references. (Note
however that certain sources cannot be duplicated, such as capture
sources, media sources, and device sources)
- Swap Mode (enabled by default) which swaps the program scene with
the preview scene when a transition completes
Currently, only non-configurable transitions (transitions without
properties) are listed, and the only transitions available as of this
writing are fade and cut. In future versions more transitions will be
added, such as swipe, stingers, and many other various sort of
transitions, and the UI will support being able to add/configure/remove
those sort of configurable transitions.
2016-01-23 11:19:29 -08:00
|
|
|
|
2025-01-08 17:35:16 +01:00
|
|
|
programOptions->setLayout(layout);
|
UI: Implement transitions and preview/program mode
Implements transitions, and introduces "Studio Mode" which allows live
editing of the same or different scenes while preserving what's
currently being displayed.
Studio Mode offers a number of new features:
- The ability to edit different scenes or the same scene without
modifying what's currently being displayed (of course)
- The ability to set up "quick transitions" with a desired transition
and duration that can be assigned hotkeys
- The option to create full copies of all sources in the program scene
to allow editing of source properties of the same scene live without
modifying the output, or (by default) just use references. (Note
however that certain sources cannot be duplicated, such as capture
sources, media sources, and device sources)
- Swap Mode (enabled by default) which swaps the program scene with
the preview scene when a transition completes
Currently, only non-configurable transitions (transitions without
properties) are listed, and the only transitions available as of this
writing are fade and cut. In future versions more transitions will be
added, such as swipe, stingers, and many other various sort of
transitions, and the UI will support being able to add/configure/remove
those sort of configurable transitions.
2016-01-23 11:19:29 -08:00
|
|
|
|
2025-01-08 17:35:16 +01:00
|
|
|
auto onAdd = [this]() {
|
|
|
|
|
QScopedPointer<QMenu> menu(CreateTransitionMenu(this, nullptr));
|
|
|
|
|
menu->exec(QCursor::pos());
|
|
|
|
|
};
|
UI: Implement transitions and preview/program mode
Implements transitions, and introduces "Studio Mode" which allows live
editing of the same or different scenes while preserving what's
currently being displayed.
Studio Mode offers a number of new features:
- The ability to edit different scenes or the same scene without
modifying what's currently being displayed (of course)
- The ability to set up "quick transitions" with a desired transition
and duration that can be assigned hotkeys
- The option to create full copies of all sources in the program scene
to allow editing of source properties of the same scene live without
modifying the output, or (by default) just use references. (Note
however that certain sources cannot be duplicated, such as capture
sources, media sources, and device sources)
- Swap Mode (enabled by default) which swaps the program scene with
the preview scene when a transition completes
Currently, only non-configurable transitions (transitions without
properties) are listed, and the only transitions available as of this
writing are fade and cut. In future versions more transitions will be
added, such as swipe, stingers, and many other various sort of
transitions, and the UI will support being able to add/configure/remove
those sort of configurable transitions.
2016-01-23 11:19:29 -08:00
|
|
|
|
2025-01-08 17:35:16 +01:00
|
|
|
auto onConfig = [this]() {
|
|
|
|
|
QMenu menu(this);
|
|
|
|
|
QAction *action;
|
UI: Implement transitions and preview/program mode
Implements transitions, and introduces "Studio Mode" which allows live
editing of the same or different scenes while preserving what's
currently being displayed.
Studio Mode offers a number of new features:
- The ability to edit different scenes or the same scene without
modifying what's currently being displayed (of course)
- The ability to set up "quick transitions" with a desired transition
and duration that can be assigned hotkeys
- The option to create full copies of all sources in the program scene
to allow editing of source properties of the same scene live without
modifying the output, or (by default) just use references. (Note
however that certain sources cannot be duplicated, such as capture
sources, media sources, and device sources)
- Swap Mode (enabled by default) which swaps the program scene with
the preview scene when a transition completes
Currently, only non-configurable transitions (transitions without
properties) are listed, and the only transitions available as of this
writing are fade and cut. In future versions more transitions will be
added, such as swipe, stingers, and many other various sort of
transitions, and the UI will support being able to add/configure/remove
those sort of configurable transitions.
2016-01-23 11:19:29 -08:00
|
|
|
|
2025-01-08 17:35:16 +01:00
|
|
|
auto toggleEditProperties = [this]() {
|
|
|
|
|
editPropertiesMode = !editPropertiesMode;
|
UI: Implement transitions and preview/program mode
Implements transitions, and introduces "Studio Mode" which allows live
editing of the same or different scenes while preserving what's
currently being displayed.
Studio Mode offers a number of new features:
- The ability to edit different scenes or the same scene without
modifying what's currently being displayed (of course)
- The ability to set up "quick transitions" with a desired transition
and duration that can be assigned hotkeys
- The option to create full copies of all sources in the program scene
to allow editing of source properties of the same scene live without
modifying the output, or (by default) just use references. (Note
however that certain sources cannot be duplicated, such as capture
sources, media sources, and device sources)
- Swap Mode (enabled by default) which swaps the program scene with
the preview scene when a transition completes
Currently, only non-configurable transitions (transitions without
properties) are listed, and the only transitions available as of this
writing are fade and cut. In future versions more transitions will be
added, such as swipe, stingers, and many other various sort of
transitions, and the UI will support being able to add/configure/remove
those sort of configurable transitions.
2016-01-23 11:19:29 -08:00
|
|
|
|
2025-01-08 17:35:16 +01:00
|
|
|
OBSSource actualScene = OBSGetStrongRef(programScene);
|
|
|
|
|
if (actualScene)
|
|
|
|
|
TransitionToScene(actualScene, true);
|
|
|
|
|
};
|
UI: Implement transitions and preview/program mode
Implements transitions, and introduces "Studio Mode" which allows live
editing of the same or different scenes while preserving what's
currently being displayed.
Studio Mode offers a number of new features:
- The ability to edit different scenes or the same scene without
modifying what's currently being displayed (of course)
- The ability to set up "quick transitions" with a desired transition
and duration that can be assigned hotkeys
- The option to create full copies of all sources in the program scene
to allow editing of source properties of the same scene live without
modifying the output, or (by default) just use references. (Note
however that certain sources cannot be duplicated, such as capture
sources, media sources, and device sources)
- Swap Mode (enabled by default) which swaps the program scene with
the preview scene when a transition completes
Currently, only non-configurable transitions (transitions without
properties) are listed, and the only transitions available as of this
writing are fade and cut. In future versions more transitions will be
added, such as swipe, stingers, and many other various sort of
transitions, and the UI will support being able to add/configure/remove
those sort of configurable transitions.
2016-01-23 11:19:29 -08:00
|
|
|
|
2025-01-08 17:35:16 +01:00
|
|
|
auto toggleSwapScenesMode = [this]() {
|
|
|
|
|
swapScenesMode = !swapScenesMode;
|
|
|
|
|
};
|
UI: Implement transitions and preview/program mode
Implements transitions, and introduces "Studio Mode" which allows live
editing of the same or different scenes while preserving what's
currently being displayed.
Studio Mode offers a number of new features:
- The ability to edit different scenes or the same scene without
modifying what's currently being displayed (of course)
- The ability to set up "quick transitions" with a desired transition
and duration that can be assigned hotkeys
- The option to create full copies of all sources in the program scene
to allow editing of source properties of the same scene live without
modifying the output, or (by default) just use references. (Note
however that certain sources cannot be duplicated, such as capture
sources, media sources, and device sources)
- Swap Mode (enabled by default) which swaps the program scene with
the preview scene when a transition completes
Currently, only non-configurable transitions (transitions without
properties) are listed, and the only transitions available as of this
writing are fade and cut. In future versions more transitions will be
added, such as swipe, stingers, and many other various sort of
transitions, and the UI will support being able to add/configure/remove
those sort of configurable transitions.
2016-01-23 11:19:29 -08:00
|
|
|
|
2025-01-08 17:35:16 +01:00
|
|
|
auto toggleSceneDuplication = [this]() {
|
|
|
|
|
sceneDuplicationMode = !sceneDuplicationMode;
|
UI: Implement transitions and preview/program mode
Implements transitions, and introduces "Studio Mode" which allows live
editing of the same or different scenes while preserving what's
currently being displayed.
Studio Mode offers a number of new features:
- The ability to edit different scenes or the same scene without
modifying what's currently being displayed (of course)
- The ability to set up "quick transitions" with a desired transition
and duration that can be assigned hotkeys
- The option to create full copies of all sources in the program scene
to allow editing of source properties of the same scene live without
modifying the output, or (by default) just use references. (Note
however that certain sources cannot be duplicated, such as capture
sources, media sources, and device sources)
- Swap Mode (enabled by default) which swaps the program scene with
the preview scene when a transition completes
Currently, only non-configurable transitions (transitions without
properties) are listed, and the only transitions available as of this
writing are fade and cut. In future versions more transitions will be
added, such as swipe, stingers, and many other various sort of
transitions, and the UI will support being able to add/configure/remove
those sort of configurable transitions.
2016-01-23 11:19:29 -08:00
|
|
|
|
2025-01-08 17:35:16 +01:00
|
|
|
OBSSource actualScene = OBSGetStrongRef(programScene);
|
|
|
|
|
if (actualScene)
|
|
|
|
|
TransitionToScene(actualScene, true);
|
|
|
|
|
};
|
UI: Implement transitions and preview/program mode
Implements transitions, and introduces "Studio Mode" which allows live
editing of the same or different scenes while preserving what's
currently being displayed.
Studio Mode offers a number of new features:
- The ability to edit different scenes or the same scene without
modifying what's currently being displayed (of course)
- The ability to set up "quick transitions" with a desired transition
and duration that can be assigned hotkeys
- The option to create full copies of all sources in the program scene
to allow editing of source properties of the same scene live without
modifying the output, or (by default) just use references. (Note
however that certain sources cannot be duplicated, such as capture
sources, media sources, and device sources)
- Swap Mode (enabled by default) which swaps the program scene with
the preview scene when a transition completes
Currently, only non-configurable transitions (transitions without
properties) are listed, and the only transitions available as of this
writing are fade and cut. In future versions more transitions will be
added, such as swipe, stingers, and many other various sort of
transitions, and the UI will support being able to add/configure/remove
those sort of configurable transitions.
2016-01-23 11:19:29 -08:00
|
|
|
|
2025-01-08 17:35:16 +01:00
|
|
|
auto showToolTip = [&]() {
|
|
|
|
|
QAction *act = menu.activeAction();
|
|
|
|
|
QToolTip::showText(QCursor::pos(), act->toolTip(), &menu, menu.actionGeometry(act));
|
|
|
|
|
};
|
UI: Implement transitions and preview/program mode
Implements transitions, and introduces "Studio Mode" which allows live
editing of the same or different scenes while preserving what's
currently being displayed.
Studio Mode offers a number of new features:
- The ability to edit different scenes or the same scene without
modifying what's currently being displayed (of course)
- The ability to set up "quick transitions" with a desired transition
and duration that can be assigned hotkeys
- The option to create full copies of all sources in the program scene
to allow editing of source properties of the same scene live without
modifying the output, or (by default) just use references. (Note
however that certain sources cannot be duplicated, such as capture
sources, media sources, and device sources)
- Swap Mode (enabled by default) which swaps the program scene with
the preview scene when a transition completes
Currently, only non-configurable transitions (transitions without
properties) are listed, and the only transitions available as of this
writing are fade and cut. In future versions more transitions will be
added, such as swipe, stingers, and many other various sort of
transitions, and the UI will support being able to add/configure/remove
those sort of configurable transitions.
2016-01-23 11:19:29 -08:00
|
|
|
|
2025-01-08 17:35:16 +01:00
|
|
|
action = menu.addAction(QTStr("QuickTransitions.DuplicateScene"));
|
|
|
|
|
action->setToolTip(QTStr("QuickTransitions.DuplicateSceneTT"));
|
|
|
|
|
action->setCheckable(true);
|
|
|
|
|
action->setChecked(sceneDuplicationMode);
|
|
|
|
|
connect(action, &QAction::triggered, toggleSceneDuplication);
|
|
|
|
|
connect(action, &QAction::hovered, showToolTip);
|
2020-02-04 06:06:45 -06:00
|
|
|
|
2025-01-08 17:35:16 +01:00
|
|
|
action = menu.addAction(QTStr("QuickTransitions.EditProperties"));
|
|
|
|
|
action->setToolTip(QTStr("QuickTransitions.EditPropertiesTT"));
|
|
|
|
|
action->setCheckable(true);
|
|
|
|
|
action->setChecked(editPropertiesMode);
|
|
|
|
|
action->setEnabled(sceneDuplicationMode);
|
|
|
|
|
connect(action, &QAction::triggered, toggleEditProperties);
|
|
|
|
|
connect(action, &QAction::hovered, showToolTip);
|
2016-08-28 14:24:14 -07:00
|
|
|
|
2025-01-08 17:35:16 +01:00
|
|
|
action = menu.addAction(QTStr("QuickTransitions.SwapScenes"));
|
|
|
|
|
action->setToolTip(QTStr("QuickTransitions.SwapScenesTT"));
|
|
|
|
|
action->setCheckable(true);
|
|
|
|
|
action->setChecked(swapScenesMode);
|
|
|
|
|
connect(action, &QAction::triggered, toggleSwapScenesMode);
|
|
|
|
|
connect(action, &QAction::hovered, showToolTip);
|
UI: Implement transitions and preview/program mode
Implements transitions, and introduces "Studio Mode" which allows live
editing of the same or different scenes while preserving what's
currently being displayed.
Studio Mode offers a number of new features:
- The ability to edit different scenes or the same scene without
modifying what's currently being displayed (of course)
- The ability to set up "quick transitions" with a desired transition
and duration that can be assigned hotkeys
- The option to create full copies of all sources in the program scene
to allow editing of source properties of the same scene live without
modifying the output, or (by default) just use references. (Note
however that certain sources cannot be duplicated, such as capture
sources, media sources, and device sources)
- Swap Mode (enabled by default) which swaps the program scene with
the preview scene when a transition completes
Currently, only non-configurable transitions (transitions without
properties) are listed, and the only transitions available as of this
writing are fade and cut. In future versions more transitions will be
added, such as swipe, stingers, and many other various sort of
transitions, and the UI will support being able to add/configure/remove
those sort of configurable transitions.
2016-01-23 11:19:29 -08:00
|
|
|
|
2025-01-08 17:35:16 +01:00
|
|
|
menu.exec(QCursor::pos());
|
|
|
|
|
};
|
2017-11-30 05:05:50 -08:00
|
|
|
|
2025-01-08 17:35:16 +01:00
|
|
|
connect(transitionButton.data(), &QAbstractButton::clicked, this, &OBSBasic::TransitionClicked);
|
|
|
|
|
connect(addQuickTransition, &QAbstractButton::clicked, onAdd);
|
|
|
|
|
connect(configTransitions, &QAbstractButton::clicked, onConfig);
|
2017-11-30 05:05:50 -08:00
|
|
|
}
|
|
|
|
|
|
2025-01-08 17:35:16 +01:00
|
|
|
void OBSBasic::TogglePreviewProgramMode()
|
2017-11-30 05:05:50 -08:00
|
|
|
{
|
2025-01-08 17:35:16 +01:00
|
|
|
SetPreviewProgramMode(!IsPreviewProgramMode());
|
2017-11-30 05:05:50 -08:00
|
|
|
}
|
|
|
|
|
|
2025-01-08 17:35:16 +01:00
|
|
|
void OBSBasic::SetPreviewProgramMode(bool enabled)
|
UI: Implement transitions and preview/program mode
Implements transitions, and introduces "Studio Mode" which allows live
editing of the same or different scenes while preserving what's
currently being displayed.
Studio Mode offers a number of new features:
- The ability to edit different scenes or the same scene without
modifying what's currently being displayed (of course)
- The ability to set up "quick transitions" with a desired transition
and duration that can be assigned hotkeys
- The option to create full copies of all sources in the program scene
to allow editing of source properties of the same scene live without
modifying the output, or (by default) just use references. (Note
however that certain sources cannot be duplicated, such as capture
sources, media sources, and device sources)
- Swap Mode (enabled by default) which swaps the program scene with
the preview scene when a transition completes
Currently, only non-configurable transitions (transitions without
properties) are listed, and the only transitions available as of this
writing are fade and cut. In future versions more transitions will be
added, such as swipe, stingers, and many other various sort of
transitions, and the UI will support being able to add/configure/remove
those sort of configurable transitions.
2016-01-23 11:19:29 -08:00
|
|
|
{
|
2025-01-08 17:35:16 +01:00
|
|
|
if (IsPreviewProgramMode() == enabled)
|
UI: Implement transitions and preview/program mode
Implements transitions, and introduces "Studio Mode" which allows live
editing of the same or different scenes while preserving what's
currently being displayed.
Studio Mode offers a number of new features:
- The ability to edit different scenes or the same scene without
modifying what's currently being displayed (of course)
- The ability to set up "quick transitions" with a desired transition
and duration that can be assigned hotkeys
- The option to create full copies of all sources in the program scene
to allow editing of source properties of the same scene live without
modifying the output, or (by default) just use references. (Note
however that certain sources cannot be duplicated, such as capture
sources, media sources, and device sources)
- Swap Mode (enabled by default) which swaps the program scene with
the preview scene when a transition completes
Currently, only non-configurable transitions (transitions without
properties) are listed, and the only transitions available as of this
writing are fade and cut. In future versions more transitions will be
added, such as swipe, stingers, and many other various sort of
transitions, and the UI will support being able to add/configure/remove
those sort of configurable transitions.
2016-01-23 11:19:29 -08:00
|
|
|
return;
|
|
|
|
|
|
2025-01-08 17:35:16 +01:00
|
|
|
os_atomic_set_bool(&previewProgramMode, enabled);
|
|
|
|
|
emit PreviewProgramModeChanged(enabled);
|
|
|
|
|
|
|
|
|
|
if (IsPreviewProgramMode()) {
|
|
|
|
|
if (!previewEnabled)
|
|
|
|
|
EnablePreviewDisplay(true);
|
UI: Implement transitions and preview/program mode
Implements transitions, and introduces "Studio Mode" which allows live
editing of the same or different scenes while preserving what's
currently being displayed.
Studio Mode offers a number of new features:
- The ability to edit different scenes or the same scene without
modifying what's currently being displayed (of course)
- The ability to set up "quick transitions" with a desired transition
and duration that can be assigned hotkeys
- The option to create full copies of all sources in the program scene
to allow editing of source properties of the same scene live without
modifying the output, or (by default) just use references. (Note
however that certain sources cannot be duplicated, such as capture
sources, media sources, and device sources)
- Swap Mode (enabled by default) which swaps the program scene with
the preview scene when a transition completes
Currently, only non-configurable transitions (transitions without
properties) are listed, and the only transitions available as of this
writing are fade and cut. In future versions more transitions will be
added, such as swipe, stingers, and many other various sort of
transitions, and the UI will support being able to add/configure/remove
those sort of configurable transitions.
2016-01-23 11:19:29 -08:00
|
|
|
|
2025-01-08 17:35:16 +01:00
|
|
|
CreateProgramDisplay();
|
|
|
|
|
CreateProgramOptions();
|
UI: Implement transitions and preview/program mode
Implements transitions, and introduces "Studio Mode" which allows live
editing of the same or different scenes while preserving what's
currently being displayed.
Studio Mode offers a number of new features:
- The ability to edit different scenes or the same scene without
modifying what's currently being displayed (of course)
- The ability to set up "quick transitions" with a desired transition
and duration that can be assigned hotkeys
- The option to create full copies of all sources in the program scene
to allow editing of source properties of the same scene live without
modifying the output, or (by default) just use references. (Note
however that certain sources cannot be duplicated, such as capture
sources, media sources, and device sources)
- Swap Mode (enabled by default) which swaps the program scene with
the preview scene when a transition completes
Currently, only non-configurable transitions (transitions without
properties) are listed, and the only transitions available as of this
writing are fade and cut. In future versions more transitions will be
added, such as swipe, stingers, and many other various sort of
transitions, and the UI will support being able to add/configure/remove
those sort of configurable transitions.
2016-01-23 11:19:29 -08:00
|
|
|
|
2025-01-08 17:35:16 +01:00
|
|
|
OBSScene curScene = GetCurrentScene();
|
UI: Implement transitions and preview/program mode
Implements transitions, and introduces "Studio Mode" which allows live
editing of the same or different scenes while preserving what's
currently being displayed.
Studio Mode offers a number of new features:
- The ability to edit different scenes or the same scene without
modifying what's currently being displayed (of course)
- The ability to set up "quick transitions" with a desired transition
and duration that can be assigned hotkeys
- The option to create full copies of all sources in the program scene
to allow editing of source properties of the same scene live without
modifying the output, or (by default) just use references. (Note
however that certain sources cannot be duplicated, such as capture
sources, media sources, and device sources)
- Swap Mode (enabled by default) which swaps the program scene with
the preview scene when a transition completes
Currently, only non-configurable transitions (transitions without
properties) are listed, and the only transitions available as of this
writing are fade and cut. In future versions more transitions will be
added, such as swipe, stingers, and many other various sort of
transitions, and the UI will support being able to add/configure/remove
those sort of configurable transitions.
2016-01-23 11:19:29 -08:00
|
|
|
|
2025-01-08 17:35:16 +01:00
|
|
|
OBSSceneAutoRelease dup;
|
|
|
|
|
if (sceneDuplicationMode) {
|
|
|
|
|
dup = obs_scene_duplicate(curScene, obs_source_get_name(obs_scene_get_source(curScene)),
|
|
|
|
|
editPropertiesMode ? OBS_SCENE_DUP_PRIVATE_COPY
|
|
|
|
|
: OBS_SCENE_DUP_PRIVATE_REFS);
|
|
|
|
|
} else {
|
|
|
|
|
dup = std::move(OBSScene(curScene));
|
UI: Implement transitions and preview/program mode
Implements transitions, and introduces "Studio Mode" which allows live
editing of the same or different scenes while preserving what's
currently being displayed.
Studio Mode offers a number of new features:
- The ability to edit different scenes or the same scene without
modifying what's currently being displayed (of course)
- The ability to set up "quick transitions" with a desired transition
and duration that can be assigned hotkeys
- The option to create full copies of all sources in the program scene
to allow editing of source properties of the same scene live without
modifying the output, or (by default) just use references. (Note
however that certain sources cannot be duplicated, such as capture
sources, media sources, and device sources)
- Swap Mode (enabled by default) which swaps the program scene with
the preview scene when a transition completes
Currently, only non-configurable transitions (transitions without
properties) are listed, and the only transitions available as of this
writing are fade and cut. In future versions more transitions will be
added, such as swipe, stingers, and many other various sort of
transitions, and the UI will support being able to add/configure/remove
those sort of configurable transitions.
2016-01-23 11:19:29 -08:00
|
|
|
}
|
|
|
|
|
|
2025-01-08 17:35:16 +01:00
|
|
|
OBSSourceAutoRelease transition = obs_get_output_source(0);
|
|
|
|
|
obs_source_t *dup_source = obs_scene_get_source(dup);
|
|
|
|
|
obs_transition_set(transition, dup_source);
|
UI: Implement transitions and preview/program mode
Implements transitions, and introduces "Studio Mode" which allows live
editing of the same or different scenes while preserving what's
currently being displayed.
Studio Mode offers a number of new features:
- The ability to edit different scenes or the same scene without
modifying what's currently being displayed (of course)
- The ability to set up "quick transitions" with a desired transition
and duration that can be assigned hotkeys
- The option to create full copies of all sources in the program scene
to allow editing of source properties of the same scene live without
modifying the output, or (by default) just use references. (Note
however that certain sources cannot be duplicated, such as capture
sources, media sources, and device sources)
- Swap Mode (enabled by default) which swaps the program scene with
the preview scene when a transition completes
Currently, only non-configurable transitions (transitions without
properties) are listed, and the only transitions available as of this
writing are fade and cut. In future versions more transitions will be
added, such as swipe, stingers, and many other various sort of
transitions, and the UI will support being able to add/configure/remove
those sort of configurable transitions.
2016-01-23 11:19:29 -08:00
|
|
|
|
2025-01-08 17:35:16 +01:00
|
|
|
if (curScene) {
|
|
|
|
|
obs_source_t *source = obs_scene_get_source(curScene);
|
|
|
|
|
obs_source_inc_showing(source);
|
|
|
|
|
lastScene = OBSGetWeakRef(source);
|
|
|
|
|
programScene = OBSGetWeakRef(source);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
RefreshQuickTransitions();
|
UI: Implement transitions and preview/program mode
Implements transitions, and introduces "Studio Mode" which allows live
editing of the same or different scenes while preserving what's
currently being displayed.
Studio Mode offers a number of new features:
- The ability to edit different scenes or the same scene without
modifying what's currently being displayed (of course)
- The ability to set up "quick transitions" with a desired transition
and duration that can be assigned hotkeys
- The option to create full copies of all sources in the program scene
to allow editing of source properties of the same scene live without
modifying the output, or (by default) just use references. (Note
however that certain sources cannot be duplicated, such as capture
sources, media sources, and device sources)
- Swap Mode (enabled by default) which swaps the program scene with
the preview scene when a transition completes
Currently, only non-configurable transitions (transitions without
properties) are listed, and the only transitions available as of this
writing are fade and cut. In future versions more transitions will be
added, such as swipe, stingers, and many other various sort of
transitions, and the UI will support being able to add/configure/remove
those sort of configurable transitions.
2016-01-23 11:19:29 -08:00
|
|
|
|
2025-01-08 17:35:16 +01:00
|
|
|
programLabel = new QLabel(QTStr("StudioMode.ProgramSceneLabel"), this);
|
|
|
|
|
programLabel->setSizePolicy(QSizePolicy::Ignored, QSizePolicy::Preferred);
|
|
|
|
|
programLabel->setProperty("class", "label-preview-title");
|
2018-05-25 10:16:40 +02:00
|
|
|
|
2025-01-08 17:35:16 +01:00
|
|
|
programWidget = new QWidget();
|
|
|
|
|
programLayout = new QVBoxLayout();
|
2018-05-25 10:16:40 +02:00
|
|
|
|
2025-01-08 17:35:16 +01:00
|
|
|
programLayout->setContentsMargins(0, 0, 0, 0);
|
|
|
|
|
programLayout->setSpacing(0);
|
2023-06-14 02:14:51 +02:00
|
|
|
|
2025-01-08 17:35:16 +01:00
|
|
|
programLayout->addWidget(programLabel);
|
|
|
|
|
programLayout->addWidget(program);
|
2023-06-14 02:14:51 +02:00
|
|
|
|
2025-01-08 17:35:16 +01:00
|
|
|
programWidget->setLayout(programLayout);
|
2023-06-14 02:14:51 +02:00
|
|
|
|
2025-01-08 17:35:16 +01:00
|
|
|
ui->previewLayout->addWidget(programOptions);
|
|
|
|
|
ui->previewLayout->addWidget(programWidget);
|
|
|
|
|
ui->previewLayout->setAlignment(programOptions, Qt::AlignCenter);
|
|
|
|
|
|
|
|
|
|
OnEvent(OBS_FRONTEND_EVENT_STUDIO_MODE_ENABLED);
|
2023-06-14 02:14:51 +02:00
|
|
|
|
2025-01-08 17:35:16 +01:00
|
|
|
blog(LOG_INFO, "Switched to Preview/Program mode");
|
|
|
|
|
blog(LOG_INFO, "-----------------------------"
|
|
|
|
|
"-------------------");
|
2017-02-22 03:08:37 -08:00
|
|
|
} else {
|
2025-01-08 17:35:16 +01:00
|
|
|
OBSSource actualProgramScene = OBSGetStrongRef(programScene);
|
|
|
|
|
if (!actualProgramScene)
|
|
|
|
|
actualProgramScene = GetCurrentSceneSource();
|
|
|
|
|
else
|
|
|
|
|
SetCurrentScene(actualProgramScene, true);
|
|
|
|
|
TransitionToScene(actualProgramScene, true);
|
2017-11-30 05:05:50 -08:00
|
|
|
|
2025-01-08 17:35:16 +01:00
|
|
|
delete programOptions;
|
|
|
|
|
delete program;
|
|
|
|
|
delete programLabel;
|
|
|
|
|
delete programWidget;
|
2017-11-30 05:05:50 -08:00
|
|
|
|
2025-01-08 17:35:16 +01:00
|
|
|
if (lastScene) {
|
|
|
|
|
OBSSource actualLastScene = OBSGetStrongRef(lastScene);
|
|
|
|
|
if (actualLastScene)
|
|
|
|
|
obs_source_dec_showing(actualLastScene);
|
|
|
|
|
lastScene = nullptr;
|
2017-11-30 05:05:50 -08:00
|
|
|
}
|
|
|
|
|
|
2025-01-08 17:35:16 +01:00
|
|
|
programScene = nullptr;
|
|
|
|
|
swapScene = nullptr;
|
|
|
|
|
prevFTBSource = nullptr;
|
2019-10-23 16:11:14 -05:00
|
|
|
|
2025-01-08 17:35:16 +01:00
|
|
|
for (QuickTransition &qt : quickTransitions)
|
|
|
|
|
qt.button = nullptr;
|
2019-10-24 19:52:26 -05:00
|
|
|
|
2025-01-08 17:35:16 +01:00
|
|
|
if (!previewEnabled)
|
|
|
|
|
EnablePreviewDisplay(false);
|
2019-12-27 16:41:10 -08:00
|
|
|
|
2025-01-08 17:35:16 +01:00
|
|
|
ui->transitions->setEnabled(true);
|
|
|
|
|
tBarActive = false;
|
2020-01-13 22:40:03 -06:00
|
|
|
|
2025-01-08 17:35:16 +01:00
|
|
|
OnEvent(OBS_FRONTEND_EVENT_STUDIO_MODE_DISABLED);
|
2019-12-27 16:41:10 -08:00
|
|
|
|
2025-01-08 17:35:16 +01:00
|
|
|
blog(LOG_INFO, "Switched to regular Preview mode");
|
|
|
|
|
blog(LOG_INFO, "-----------------------------"
|
|
|
|
|
"-------------------");
|
2017-02-22 03:08:37 -08:00
|
|
|
}
|
UI: Implement transitions and preview/program mode
Implements transitions, and introduces "Studio Mode" which allows live
editing of the same or different scenes while preserving what's
currently being displayed.
Studio Mode offers a number of new features:
- The ability to edit different scenes or the same scene without
modifying what's currently being displayed (of course)
- The ability to set up "quick transitions" with a desired transition
and duration that can be assigned hotkeys
- The option to create full copies of all sources in the program scene
to allow editing of source properties of the same scene live without
modifying the output, or (by default) just use references. (Note
however that certain sources cannot be duplicated, such as capture
sources, media sources, and device sources)
- Swap Mode (enabled by default) which swaps the program scene with
the preview scene when a transition completes
Currently, only non-configurable transitions (transitions without
properties) are listed, and the only transitions available as of this
writing are fade and cut. In future versions more transitions will be
added, such as swipe, stingers, and many other various sort of
transitions, and the UI will support being able to add/configure/remove
those sort of configurable transitions.
2016-01-23 11:19:29 -08:00
|
|
|
|
2025-01-08 17:35:16 +01:00
|
|
|
ResetUI();
|
|
|
|
|
UpdateTitleBar();
|
UI: Implement transitions and preview/program mode
Implements transitions, and introduces "Studio Mode" which allows live
editing of the same or different scenes while preserving what's
currently being displayed.
Studio Mode offers a number of new features:
- The ability to edit different scenes or the same scene without
modifying what's currently being displayed (of course)
- The ability to set up "quick transitions" with a desired transition
and duration that can be assigned hotkeys
- The option to create full copies of all sources in the program scene
to allow editing of source properties of the same scene live without
modifying the output, or (by default) just use references. (Note
however that certain sources cannot be duplicated, such as capture
sources, media sources, and device sources)
- Swap Mode (enabled by default) which swaps the program scene with
the preview scene when a transition completes
Currently, only non-configurable transitions (transitions without
properties) are listed, and the only transitions available as of this
writing are fade and cut. In future versions more transitions will be
added, such as swipe, stingers, and many other various sort of
transitions, and the UI will support being able to add/configure/remove
those sort of configurable transitions.
2016-01-23 11:19:29 -08:00
|
|
|
}
|
|
|
|
|
|
2025-01-08 17:35:16 +01:00
|
|
|
void OBSBasic::RenderProgram(void *data, uint32_t, uint32_t)
|
UI: Implement transitions and preview/program mode
Implements transitions, and introduces "Studio Mode" which allows live
editing of the same or different scenes while preserving what's
currently being displayed.
Studio Mode offers a number of new features:
- The ability to edit different scenes or the same scene without
modifying what's currently being displayed (of course)
- The ability to set up "quick transitions" with a desired transition
and duration that can be assigned hotkeys
- The option to create full copies of all sources in the program scene
to allow editing of source properties of the same scene live without
modifying the output, or (by default) just use references. (Note
however that certain sources cannot be duplicated, such as capture
sources, media sources, and device sources)
- Swap Mode (enabled by default) which swaps the program scene with
the preview scene when a transition completes
Currently, only non-configurable transitions (transitions without
properties) are listed, and the only transitions available as of this
writing are fade and cut. In future versions more transitions will be
added, such as swipe, stingers, and many other various sort of
transitions, and the UI will support being able to add/configure/remove
those sort of configurable transitions.
2016-01-23 11:19:29 -08:00
|
|
|
{
|
2025-01-08 17:35:16 +01:00
|
|
|
GS_DEBUG_MARKER_BEGIN(GS_DEBUG_COLOR_DEFAULT, "RenderProgram");
|
UI: Implement transitions and preview/program mode
Implements transitions, and introduces "Studio Mode" which allows live
editing of the same or different scenes while preserving what's
currently being displayed.
Studio Mode offers a number of new features:
- The ability to edit different scenes or the same scene without
modifying what's currently being displayed (of course)
- The ability to set up "quick transitions" with a desired transition
and duration that can be assigned hotkeys
- The option to create full copies of all sources in the program scene
to allow editing of source properties of the same scene live without
modifying the output, or (by default) just use references. (Note
however that certain sources cannot be duplicated, such as capture
sources, media sources, and device sources)
- Swap Mode (enabled by default) which swaps the program scene with
the preview scene when a transition completes
Currently, only non-configurable transitions (transitions without
properties) are listed, and the only transitions available as of this
writing are fade and cut. In future versions more transitions will be
added, such as swipe, stingers, and many other various sort of
transitions, and the UI will support being able to add/configure/remove
those sort of configurable transitions.
2016-01-23 11:19:29 -08:00
|
|
|
|
2025-01-08 17:35:16 +01:00
|
|
|
OBSBasic *window = static_cast<OBSBasic *>(data);
|
|
|
|
|
obs_video_info ovi;
|
2020-05-20 15:49:14 -05:00
|
|
|
|
2025-01-08 17:35:16 +01:00
|
|
|
obs_get_video_info(&ovi);
|
UI: Implement transitions and preview/program mode
Implements transitions, and introduces "Studio Mode" which allows live
editing of the same or different scenes while preserving what's
currently being displayed.
Studio Mode offers a number of new features:
- The ability to edit different scenes or the same scene without
modifying what's currently being displayed (of course)
- The ability to set up "quick transitions" with a desired transition
and duration that can be assigned hotkeys
- The option to create full copies of all sources in the program scene
to allow editing of source properties of the same scene live without
modifying the output, or (by default) just use references. (Note
however that certain sources cannot be duplicated, such as capture
sources, media sources, and device sources)
- Swap Mode (enabled by default) which swaps the program scene with
the preview scene when a transition completes
Currently, only non-configurable transitions (transitions without
properties) are listed, and the only transitions available as of this
writing are fade and cut. In future versions more transitions will be
added, such as swipe, stingers, and many other various sort of
transitions, and the UI will support being able to add/configure/remove
those sort of configurable transitions.
2016-01-23 11:19:29 -08:00
|
|
|
|
2025-01-08 17:35:16 +01:00
|
|
|
window->programCX = int(window->programScale * float(ovi.base_width));
|
|
|
|
|
window->programCY = int(window->programScale * float(ovi.base_height));
|
2020-06-13 21:00:55 -05:00
|
|
|
|
2025-01-08 17:35:16 +01:00
|
|
|
gs_viewport_push();
|
|
|
|
|
gs_projection_push();
|
2020-06-13 21:00:55 -05:00
|
|
|
|
2025-01-08 17:35:16 +01:00
|
|
|
/* --------------------------------------- */
|
2018-08-23 20:43:44 -05:00
|
|
|
|
2025-01-08 17:35:16 +01:00
|
|
|
gs_ortho(0.0f, float(ovi.base_width), 0.0f, float(ovi.base_height), -100.0f, 100.0f);
|
|
|
|
|
gs_set_viewport(window->programX, window->programY, window->programCX, window->programCY);
|
2020-08-23 05:12:46 -05:00
|
|
|
|
2025-01-08 17:35:16 +01:00
|
|
|
obs_render_main_texture_src_color_only();
|
|
|
|
|
gs_load_vertexbuffer(nullptr);
|
2018-08-23 20:43:44 -05:00
|
|
|
|
2025-01-08 17:35:16 +01:00
|
|
|
/* --------------------------------------- */
|
2021-01-11 23:26:02 -06:00
|
|
|
|
2025-01-08 17:35:16 +01:00
|
|
|
gs_projection_pop();
|
|
|
|
|
gs_viewport_pop();
|
2022-09-09 07:20:48 -05:00
|
|
|
|
2025-01-08 17:35:16 +01:00
|
|
|
GS_DEBUG_MARKER_END();
|
2022-09-09 07:20:48 -05:00
|
|
|
}
|
|
|
|
|
|
2025-01-08 17:35:16 +01:00
|
|
|
void OBSBasic::ResizeProgram(uint32_t cx, uint32_t cy)
|
2021-01-11 23:26:02 -06:00
|
|
|
{
|
2025-01-08 17:35:16 +01:00
|
|
|
QSize targetSize;
|
2021-02-04 06:01:35 -06:00
|
|
|
|
2025-01-08 17:35:16 +01:00
|
|
|
/* resize program panel to fix to the top section of the window */
|
|
|
|
|
targetSize = GetPixelSize(program);
|
|
|
|
|
GetScaleAndCenterPos(int(cx), int(cy), targetSize.width() - PREVIEW_EDGE_SIZE * 2,
|
|
|
|
|
targetSize.height() - PREVIEW_EDGE_SIZE * 2, programX, programY, programScale);
|
2021-08-19 23:56:49 -05:00
|
|
|
|
2025-01-08 17:35:16 +01:00
|
|
|
programX += float(PREVIEW_EDGE_SIZE);
|
|
|
|
|
programY += float(PREVIEW_EDGE_SIZE);
|
2021-08-19 23:56:49 -05:00
|
|
|
}
|
2020-06-27 02:31:08 +02:00
|
|
|
|
2025-01-08 17:35:16 +01:00
|
|
|
void OBSBasic::UpdatePreviewProgramIndicators()
|
2023-02-10 13:27:08 +01:00
|
|
|
{
|
2025-01-08 17:35:16 +01:00
|
|
|
bool labels = previewProgramMode ? config_get_bool(App()->GetUserConfig(), "BasicWindow", "StudioModeLabels")
|
|
|
|
|
: false;
|
2023-02-10 13:27:08 +01:00
|
|
|
|
2025-01-08 17:35:16 +01:00
|
|
|
ui->previewLabel->setVisible(labels);
|
2020-06-27 02:31:08 +02:00
|
|
|
|
2025-01-08 17:35:16 +01:00
|
|
|
if (programLabel)
|
|
|
|
|
programLabel->setVisible(labels);
|
2020-06-27 02:31:08 +02:00
|
|
|
|
2025-01-08 17:35:16 +01:00
|
|
|
if (!labels)
|
2020-06-27 02:31:08 +02:00
|
|
|
return;
|
|
|
|
|
|
2025-01-08 17:35:16 +01:00
|
|
|
QString preview =
|
|
|
|
|
QTStr("StudioMode.PreviewSceneName").arg(QT_UTF8(obs_source_get_name(GetCurrentSceneSource())));
|
2021-07-03 17:55:47 +12:00
|
|
|
|
2025-01-08 17:35:16 +01:00
|
|
|
QString program = QTStr("StudioMode.ProgramSceneName").arg(QT_UTF8(obs_source_get_name(GetProgramSource())));
|
2021-07-03 17:55:47 +12:00
|
|
|
|
2025-01-08 17:35:16 +01:00
|
|
|
if (ui->previewLabel->text() != preview)
|
|
|
|
|
ui->previewLabel->setText(preview);
|
2021-07-03 17:55:47 +12:00
|
|
|
|
2025-01-08 17:35:16 +01:00
|
|
|
if (programLabel && programLabel->text() != program)
|
|
|
|
|
programLabel->setText(program);
|
2021-07-03 17:55:47 +12:00
|
|
|
}
|
|
|
|
|
|
2025-01-08 17:35:16 +01:00
|
|
|
OBSSource OBSBasic::GetProgramSource()
|
2021-07-03 17:55:47 +12:00
|
|
|
{
|
2025-01-08 17:35:16 +01:00
|
|
|
return OBSGetStrongRef(programScene);
|
2021-07-03 17:55:47 +12:00
|
|
|
}
|
2021-11-01 02:16:56 -05:00
|
|
|
|
2025-01-08 17:35:16 +01:00
|
|
|
void OBSBasic::ProgramViewContextMenuRequested()
|
2021-11-01 02:16:56 -05:00
|
|
|
{
|
2025-01-08 17:35:16 +01:00
|
|
|
QMenu popup(this);
|
|
|
|
|
QPointer<QMenu> studioProgramProjector;
|
2022-07-29 20:31:13 +02:00
|
|
|
|
2024-11-04 12:33:14 -05:00
|
|
|
studioProgramProjector = new QMenu(QTStr("Projector.Open.Program"));
|
2025-01-08 17:35:16 +01:00
|
|
|
AddProjectorMenuMonitors(studioProgramProjector, this, &OBSBasic::OpenStudioProgramProjector);
|
2024-11-04 12:33:14 -05:00
|
|
|
studioProgramProjector->addSeparator();
|
|
|
|
|
studioProgramProjector->addAction(QTStr("Projector.Window"), this, &OBSBasic::OpenStudioProgramWindow);
|
2024-06-18 14:18:22 -05:00
|
|
|
|
2025-01-08 17:35:16 +01:00
|
|
|
popup.addMenu(studioProgramProjector);
|
2024-11-04 12:33:14 -05:00
|
|
|
|
|
|
|
|
popup.addSeparator();
|
2025-01-08 17:35:16 +01:00
|
|
|
popup.addAction(QTStr("Screenshot.StudioProgram"), this, &OBSBasic::ScreenshotProgram);
|
2024-07-31 10:53:59 -04:00
|
|
|
|
2025-01-08 17:35:16 +01:00
|
|
|
popup.exec(QCursor::pos());
|
2024-07-31 10:53:59 -04:00
|
|
|
}
|
|
|
|
|
|
2025-01-08 17:35:16 +01:00
|
|
|
void OBSBasic::EnablePreviewProgram()
|
2024-07-31 10:53:59 -04:00
|
|
|
{
|
2025-01-08 17:35:16 +01:00
|
|
|
SetPreviewProgramMode(true);
|
2024-07-31 10:53:59 -04:00
|
|
|
}
|
|
|
|
|
|
2025-01-08 17:35:16 +01:00
|
|
|
void OBSBasic::DisablePreviewProgram()
|
2024-07-31 10:53:59 -04:00
|
|
|
{
|
2025-01-08 17:35:16 +01:00
|
|
|
SetPreviewProgramMode(false);
|
2024-07-31 10:53:59 -04:00
|
|
|
}
|
|
|
|
|
|
2025-01-08 17:35:16 +01:00
|
|
|
void OBSBasic::OpenStudioProgramProjector()
|
2024-07-31 10:53:59 -04:00
|
|
|
{
|
2025-01-08 17:35:16 +01:00
|
|
|
int monitor = sender()->property("monitor").toInt();
|
|
|
|
|
OpenProjector(nullptr, monitor, ProjectorType::StudioProgram);
|
2024-07-31 10:53:59 -04:00
|
|
|
}
|
2024-09-03 16:29:30 +02:00
|
|
|
|
2025-01-08 17:35:16 +01:00
|
|
|
void OBSBasic::OpenStudioProgramWindow()
|
2024-09-03 16:29:30 +02:00
|
|
|
{
|
2025-01-08 17:35:16 +01:00
|
|
|
OpenProjector(nullptr, -1, ProjectorType::StudioProgram);
|
2024-09-03 16:29:30 +02:00
|
|
|
}
|